-
-
Notifications
You must be signed in to change notification settings - Fork 491
feat: add file path to origin location tracking #1128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
reuvenharrison
wants to merge
11
commits into
getkin:master
Choose a base branch
from
oasdiff:feat/origin-file-tracking
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+167
−28
Open
Changes from 6 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
ea052d6
feat: add file path to origin location tracking
reuvenharrison 0de143e
feat: add Sequences field to Origin for scalar list item locations
reuvenharrison db9b0e8
feat: add Name field to Location for sequence item lookup
reuvenharrison 2f56307
fix: regenerate docs and document Origin/Location API changes
reuvenharrison 4189ebd
Add SKILL.md with build instructions
reuvenharrison b956c41
Move SKILL.md to .claude/skills/pre-commit/ per Claude Code conventions
reuvenharrison ed03da3
chore: update yaml/yaml3 to feat/origin-enhancements branches
reuvenharrison 9d893e7
fix: exclude .claude directory from docs.sh package scan
reuvenharrison 50de220
fix: gofmt alignment in Origin struct
reuvenharrison 1dfadd9
remove .claude skills directory from repository
reuvenharrison 78f66eb
chore: update yaml3 to include sequence keys in origin Fields
reuvenharrison File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| --- | ||
| name: pre-commit | ||
| description: Run pre-commit checks for kin-openapi before committing. Use when about to commit, after making code changes, or when the user asks to validate changes. | ||
| disable-model-invocation: true | ||
| allowed-tools: Bash | ||
| --- | ||
|
|
||
| # Pre-commit checks for kin-openapi | ||
|
|
||
| Before committing changes to kin-openapi, run these steps in order: | ||
|
|
||
| ## 1. Regenerate docs | ||
|
|
||
| ```bash | ||
| ./docs.sh | ||
| ``` | ||
|
|
||
| This regenerates `.github/docs/*.txt` from `go doc` output. CI checks that these files match and will fail if they are stale. | ||
|
|
||
| If `docs.sh` fails with missing mentions, it means a public API symbol was changed or removed. Add an entry to the `## CHANGELOG: Sub-v1 breaking API changes` section in `README.md` describing the change. The script uses `grep -F` to find the symbol name, so the mention must contain the exact symbol text. | ||
|
|
||
| Stage any updated `.github/docs/*.txt` and `README.md` files. | ||
|
|
||
| ## 2. Run tests | ||
|
|
||
| ```bash | ||
| go test ./... | ||
| ``` | ||
|
|
||
| ## 3. Vet and format | ||
|
|
||
| ```bash | ||
| go vet ./... | ||
| go fmt ./... | ||
| ``` | ||
|
|
||
| ## CI lint rule | ||
|
|
||
| Never use `require.Contains(t, err.Error(), ...)` in tests. Use `require.ErrorContains(t, err, ...)` instead. CI greps for `require[.].+err.Error` and fails. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes! This line needs to be fixed.
A lot of my works services are screaming "vendor/github.com/getkin/kin-openapi/openapi3/marsh.go:28:49: not enough arguments in call to yaml.UnmarshalWithOrigin"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please provide a spec that generates this error?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, just chipping-in, here's response of the maintainers on this issue (tldr; they're reverting it). I've also closed #1130 based on this.