Skip to content

[chore] Sync upstream main (apache/datafusion-sqlparser-rs)#46

Closed
ayman-sigma wants to merge 121 commits intomainfrom
ayman/sync-upstream-20260406
Closed

[chore] Sync upstream main (apache/datafusion-sqlparser-rs)#46
ayman-sigma wants to merge 121 commits intomainfrom
ayman/sync-upstream-20260406

Conversation

@ayman-sigma
Copy link
Copy Markdown

Summary

Merges all upstream commits from apache/datafusion-sqlparser-rs since the v0.60.0 divergence point (211 upstream commits). All merge conflicts are resolved in a single merge commit, preserving the full upstream commit history.

Conflict resolutions

  • src/lib.rs: Kept sigma's #![expect(clippy::unnecessary_unwrap)] + upstream's #![forbid(clippy::unreachable)]; dropped #![forbid(missing_docs)] (sigma has custom undocumented public items)
  • src/ast/mod.rs JsonPathElem: Kept all three variants — sigma's AllElements (for [*]), upstream's ColonBracket (for :[key]), and Bracket
  • src/ast/mod.rs JsonPath: Kept sigma's has_colon: bool + added upstream's doc on path
  • src/ast/mod.rs Expr::InExpr: Kept sigma's InExpr variant + added upstream's doc on negated in InSubquery
  • src/ast/spans.rs: Added both AllElements and ColonBracket match arms
  • src/parser/mod.rs colon infix: Used upstream's all-dialect colon JSON access (superset of sigma's Databricks extension)
  • src/parser/mod.rs bracket parsing: Kept sigma's parse_json_path_bracket_element() to preserve AllElements AST node
  • tests/sqlparser_snowflake.rs: Kept sigma's tests (they validate the has_colon field)

Additional auto-merge fixes

  • src/ast/query.rs: Auto-merge put sample output in PassThroughQuery arm (no sample field); moved it to Derived arm
  • src/tokenizer.rs: Auto-merge missed pos: 0 in a new State initializer in the hint tokenizer
  • src/dialect/databricks.rs: Removed sigma's get_next_precedence override that gave : Precedence::Period=50 unconditionally — this broke array slice parsing arr[1:2]. The default handler correctly returns prec_unknown() for : followed by a number, so Databricks JSON path (a:b) still works
  • tests/sqlparser_databricks.rs: Updated a:['b'].c test to use ColonBracket (upstream's new semantic representation)
  • tests/sqlparser_common.rs: Added has_colon: true to 6 new upstream test cases using colon-based JSON path

Test plan

  • cargo build — clean
  • cargo test — all tests pass

🤖 Generated with Claude Code

romanoff and others added 30 commits December 3, 2025 05:14
Co-authored-by: Claude Opus 4.5 <[email protected]>
Co-authored-by: Ifeanyi Ubah <[email protected]>
yoabot-droid and others added 28 commits February 27, 2026 10:44
…2228)

Signed-off-by: Guan-Ming Chiu <[email protected]>
Signed-off-by: Guan-Ming (Wesley) Chiu <[email protected]>
Co-authored-by: Ifeanyi Ubah <[email protected]>
@ayman-sigma
Copy link
Copy Markdown
Author

I'm trying to teach claude how to update the upstream to create a skill off it.

@ayman-sigma ayman-sigma closed this Apr 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.