-
Notifications
You must be signed in to change notification settings - Fork 169
make path primary key #3748
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
make path primary key #3748
Conversation
|
|
View your CI Pipeline Execution ↗ for commit 072c6de
☁️ Nx Cloud last updated this comment at |
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.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| specifier: 4.0.6 | ||
| version: 4.0.6(@types/[email protected])(@types/[email protected])(@vitest/[email protected])([email protected])([email protected])([email protected])([email protected])([email protected](@types/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected]) | ||
|
|
||
| packages/lix/sdk/dist/engine/wasm/bundled: {} |
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.
| specifier: ^5.7.2 | ||
| version: 5.9.2 | ||
|
|
||
| packages/lix/sdk/src/engine/wasm/bundled: {} |
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.
| } finally { | ||
| await lix.close(); | ||
| } | ||
| }); |
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.
Bug: Unscoped Paths Violate Primary Key Constraint
The test expects the second insert to succeed when inserting the same path value from a different file, but the schema defines /path as the primary key without file-scoping. Both records have identical path values in their snapshot_content, which violates the primary key constraint as declared.
Note
Set JSON pointer
pathas the schema primary key and add e2e tests enforcing PK behavior (reject duplicates, allow per-file), with minor import updates.packages/lix/plugin-json/src/schemas/json-pointer-value.ts):"x-lix-primary-key": ["/path"]onJSONPointerValueSchema.json-pointer-value.test.ts: add assertion that primary key is["/path"]; usevalidateLixSchemafrom SDK dist.e2e.test.ts:openLixfrom SDK.file_ids.Written by Cursor Bugbot for commit 072c6de. This will update automatically on new commits. Configure here.