fix(ibm-operationid-naming-convention): extend rule - #767
Conversation
Signed-off-by: Lídia Tarcza <100163235+diatrcz@users.noreply.github.com>
Signed-off-by: Lídia Tarcza <100163235+diatrcz@users.noreply.github.com>
| const convertedPath = | ||
| versionIndex >= 0 ? tempPath.slice(versionIndex + 1) : tempPath; |
There was a problem hiding this comment.
@diatrcz Quick question: what happens if the major version is a double digit, like v12? :) Probably nothing bad and I know this would probably never be the case, but we should try to make the code be prepared for such a scenario. Could you look into this?
There was a problem hiding this comment.
Btw, the changes are looking good, this is my only - somewhat theoretical - question.
There was a problem hiding this comment.
The regex pattern /^v\d+$/ matches to double, triple, quadruple, etc. digit versions as well 😄 so the logic stays the same. But I did test it locally as well, just to make sure!
There was a problem hiding this comment.
But I could change it to /^v\d*+$/, just to be safe.
## @ibm-cloud/openapi-ruleset [1.33.3](https://github.com/IBM/openapi-validator/compare/@ibm-cloud/openapi-ruleset@1.33.2...@ibm-cloud/openapi-ruleset@1.33.3) (2025-10-28) ### Bug Fixes * **ibm-operationid-naming-convention:** only validate after version segment([#767](#767)) ([67ae17c](67ae17c))
|
🎉 This PR is included in version 1.33.3 🎉 The release is available on npm package (@latest dist-tag) Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.37.3 🎉 The release is available on npm package (@latest dist-tag) Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.9.1 🎉 The release is available on npm package (@latest dist-tag) Your semantic-release bot 📦🚀 |
Modifies the operation ID checking logic so it only uses the segments of the path after the version number to create the ID name.
PR Checklist
General checklist
Please make sure that your PR fulfills the following requirements:
.secrets.baselinehas been updated as needednpm run update-utilitieshas been run if any files inpackages/utilities/srchave been updatedChecklist for adding a new validation rule: