fix: correct JSON field name typo "ValidationIssuses" → "ValidationIssues"#269
fix: correct JSON field name typo "ValidationIssuses" → "ValidationIssues"#269Yanhu007 wants to merge 2 commits intoopenshift:mainfrom
Conversation
…ssues" The Summary struct JSON tag contained a typo: "ValidationIssuses" (extra "s") instead of "ValidationIssues". This affects the JSON output format and makes it harder for consumers to parse correctly. Updated the struct tag, documentation, and all test fixtures. Note: This is a breaking change for any existing JSON parsers that use the misspelled field name. Fixes openshift#268
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: openshift/coderabbit/.coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
WalkthroughThis pull request corrects a typo in the JSON field name Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes 🚥 Pre-merge checks | ✅ 12✅ Passed checks (12 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @Yanhu007. Thanks for your PR. I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
docs/user-guide.md (1)
178-178: Add a brief migration note for the renamed JSON key.The example is fixed, but a one-line warning nearby would make the breaking change explicit for downstream parsers expecting
ValidationIssuses.Suggested doc addition
## JSON Adding `-o json` to the command line produces json output that can be more easily parsed by other software. +Note: `Summary.ValidationIssuses` was renamed to `Summary.ValidationIssues`. +Consumers parsing the old key must update.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/user-guide.md` at line 178, Add a one-line migration note near the example explaining the renamed JSON key: mention that the old key "ValidationIssuses" was corrected to "ValidationIssues" and that downstream parsers should update any references or mappings accordingly; place this short warning adjacent to the example showing "ValidationIssues" and ensure it clearly calls out the previous misspelling so consumers can handle the breaking change.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@docs/user-guide.md`:
- Line 178: Add a one-line migration note near the example explaining the
renamed JSON key: mention that the old key "ValidationIssuses" was corrected to
"ValidationIssues" and that downstream parsers should update any references or
mappings accordingly; place this short warning adjacent to the example showing
"ValidationIssues" and ensure it clearly calls out the previous misspelling so
consumers can handle the breaking change.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 4be627e4-8d5d-4d6b-8a97-2fa27588efd7
📒 Files selected for processing (7)
addon-tools/report-creator/report/testdata/CreationOfMissingCRsAndUnmatchedCRsAndDiffTestsSuitesWhenNoDiffsaddon-tools/report-creator/report/testdata/DiffTestSuiteCreationWhenThereAreDiffsaddon-tools/report-creator/report/testdata/MissingCRstestsuitecreationwhenCRSareMissingdocs/user-guide.mdpkg/compare/output.gopkg/compare/testdata/JSONOutput/localout.goldenpkg/compare/testdata/YAMLOutput/localout.golden
Address CodeRabbit review suggestion: add a note near the JSON example explaining the renamed key for downstream parsers.
|
Great catch! We'll have to do some consideration about the output format change so we don't immediately break existing clients, though. |
|
/ok-to-test |
|
@Yanhu007: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Fixes #268
Problem
The
Summarystruct has a JSON tag typo:"ValidationIssuses"(extra "s") instead of"ValidationIssues". This affects all JSON and YAML output, making it harder for downstream consumers to parse the field correctly.Changes
pkg/compare/output.godocs/user-guide.mdSummary by CodeRabbit