You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Client Server URLs: support handling an enum with default as a value clashing with the default value constant #2003
openapi: "3.0.0"info:
version: 1.0.0title: Server URLs can be optionally generatedservers:
- url: https://{username}.gigantic-server.com:{port}/{basePath}description: The production API servervariables:
# TODO this conflict will cause broken generated codeconflicting:
enum:
- 'default'
- '443'default: 'default'
Have you thought how you want to go about this? It seems there's no sensible fix without breaking backward compatibility. Something like this seems sensible, is this what you had in mind?
I haven't really thought about it at all, to be honest - but glad you have!
I think a slight breaking change (with a Compatibility Option) may be OK, but otherwise making it opt-in via an Output Option would also be reasonable.
If you're interested and up for raising a PR, would be happy to review!
I've created a proposal there ☝️ Please let me know what you think. I think it'd be a good idea to have flipping this behaviour to opt-out once the major is bumped though.
Activity
acm19 commentedon Jul 12, 2025
Have you thought how you want to go about this? It seems there's no sensible fix without breaking backward compatibility. Something like this seems sensible, is this what you had in mind?
jamietanna commentedon Jul 15, 2025
I haven't really thought about it at all, to be honest - but glad you have!
I think a slight breaking change (with a Compatibility Option) may be OK, but otherwise making it opt-in via an Output Option would also be reasonable.
If you're interested and up for raising a PR, would be happy to review!
Fix server variables conflict
acm19 commentedon Jul 25, 2025
I've created a proposal there ☝️ Please let me know what you think. I think it'd be a good idea to have flipping this behaviour to opt-out once the major is bumped though.
Fix server variables conflict
Fix server variables conflict
Fix server variables conflict
Address PR oapi-codegen#2358 review: minimize identifier churn