Fix race condition and stale references in stripOAIGen#162
Fix race condition and stale references in stripOAIGen#162fkollmann wants to merge 1 commit intogo-openapi:masterfrom
Conversation
- object has no key "XXXXOAIGen": JSON pointer error - object has no key "XXXXOAIGen1": JSON pointer error Signed-off-by: Felix Kollmann <mail@fkollmann.de>
|
Interesting. Could you elaborate on the issue this PR is supposed to fix? I've no doubt this is fixing a bug (there are likely many still out of this kind), I'd like to have an understanding of what is being fixed. For example, you could add a test case that demonstrates the failure and your fix. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #162 +/- ##
==========================================
- Coverage 91.67% 91.49% -0.18%
==========================================
Files 17 17
Lines 2017 2034 +17
==========================================
+ Hits 1849 1861 +12
- Misses 111 115 +4
- Partials 57 58 +1 ☔ View full report in Codecov by Sentry. |
fredbi
left a comment
There was a problem hiding this comment.
Please add a test case to showcase the bug this PR is fixing and demonstrate the fix.
chore: relint, tests, doc, ci Onboards #162 (credit https://github.com/fkollmann) with proper integration test that managed to reproduce the issue (on windows only, on go1.26 only) and demonstrate the fix. NOTE: CI timeout has been raised to 30m - integration tests now take 26m, since we don't have a minimal repro case available to cover the bug fixed thanks to #162.
|
@fkollmann I've managed (by luck!) to find a test that reproduces a behavior similar to the one that you describe. I agree that there was a bug or latent bug there and that it is super hard to reproduce. Besides, I've observed some interesting, yet mysterious patterns:
I've cherry-picked your commit (you are credited) to put it together with the added test. The issue I have now is that the CI needs almost 30m to create the conditions of the test. So, if you have a smaller repro case than what I've used (Azure spec is huge), you're more than welcome to push a CI-friendly test case. Thanks for the thorough bug sleuthing anyway |
Fixes non-deterministic behavior in flatten.go by:
Fixes the following errors when running
go-swagger flatten:Note: This PR was created using gemini-3-pro-preview.