fix: add logic to check for IAM RPC methods within the service before adding mixin to avoid generating duplicate methods#7929
Open
shivanee-p wants to merge 6 commits intomainfrom
Open
Conversation
… adding mixin to avoid generating duplicate methods
…e before adding mixin to avoid generating duplicate methods" This reverts commit 5759a4f.
e5d9ada to
b3ee7c3
Compare
sofisl
reviewed
Apr 1, 2026
Contributor
sofisl
left a comment
There was a problem hiding this comment.
Ok this is awesome! A few questions/comments generally:
- We also support an LRO mixin. Could you make sure that's not duplicated as well? https://docs.google.com/document/d/1YAeaLHghuvEJJtcjWFv1OaMZJgkRQG-FSVqlJJN5YgI/edit?resourcekey=0-KMHBem3k-xSFVxqUQ1QV1g&tab=t.0#heading=h.ad847mq3hi3j
- Do we want to drill down by the actual rpc name? Like, say an API declares a mixin AND directly declares a method. Should we assume that if one rpc exists, we just give precedence to that and exclude the mixin entirely? or we do we do it function by function? Or, maybe we just say more generally, don't produce duplicative function names (and don't do it function by function). I'm not really sure what path we'd want to take, my opinion is that maybe we just say we have no duplicative functions for any mixin if it's declared, without looking specifically function by function name (like in your comparison, I'm wondering what if there's a capitalization issue or a just some slight discrpancy in the hard-coding of the function name). we should just get a list of all functions in the mixin and make sure none of these are also declared in the proto.
- The actual function of how you are excluding functions in the templates makes sense and looks good! I just think we want to clean up how we're deciding what to add (specifically in proto.ts file)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds unit tests and creates baselines for testing code generation
Fixes #7659 🦕