Fix bugs to ensure unique parameter names#8762
Conversation
|
Quick review: as I understand, this deduplicates parameter names by adding a numerical suffix. While this is useful for stopping compilers from complaining, I think it may be confusing for the programmers using generated clients. Would you be interested in a PR that namespaces the parameteres to their request location ( |
|
@thiagoarrais thanks for the review. Also thanks for the PR to start the work on this. Much appreciated.
General speaking we totally welcome enhancements. For this particular case, the PR may need to target 6.0x branch as it's a breaking changes without fallback given that the duplicated parameter names will have a better naming using the request location. Please open a PR for 6.0.x and we'll review and get it merged accordingly. |
Related: #5963
Credit: @thiagoarrais for creating the test spec.
cc @OpenAPITools/generator-core-team
PR checklist
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*.For Windows users, please run the script in Git BASH.
master,5.1.x,6.0.x