-
Notifications
You must be signed in to change notification settings - Fork 5
Upgrade Peggy to v5 #16
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
Merged
Merged
Conversation
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
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
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.
Pull Request Overview
Upgraded Peggy parser to v5, restructured grammar compilation, and improved build configuration and project structure.
- Switched imports from the old JSONPath module to the new grammar AST module.
- Added Peggy configuration and removed the custom builder and legacy footer.
- Updated build scripts, package exports, and CI workflow to support Peggy v5.
Reviewed Changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
tsup.config.ts | Added explicit entry for bundler |
src/parsers/root.ts | Updated AST import and adjusted segment type |
src/parsers/function_extentions.ts | Updated AST import path |
src/parsers/filter_selector.ts | Updated AST import path |
src/parsers/array_slice_selector.ts | Updated AST import path |
src/parser.ts | Updated AST import path |
src/jsonpath_js.ts | Switched parsing import to generated grammar output |
src/grammer/jsonpath.pegjs | Revised grammar to remove TS type assertions |
src/grammer/config.js | Added Peggy configuration |
package.json | Adjusted exports, scripts, and dependencies |
grammer/jsonpath.footer.ts | Removed legacy type definitions |
grammer/builder.ts | Removed custom build script |
biome.json | Updated formatter and ignore rules |
.node-version | Specified Node.js version |
.github/workflows/lint.yml | Updated parser sync check paths |
Comments suppressed due to low confidence (1)
src/parsers/root.ts:64
- The variable
segementResult
is undefined (typo) and should likely beselectorResults
or a properly namedsegmentResult
. Fix the return variable to match the computed value.
return segementResult;
- Move all parser-related files from src/grammer/ to src/grammar/ - Update build configuration to use correct grammar directory - Update documentation and workflow files to reference correct path - Clean up old misspelled directory 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Test plan
🤖 Generated with Claude Code