Skip to content

fix(bigframes): Fix IsInOp literal bug with sqlglot#17356

Merged
tswast merged 2 commits into
mainfrom
tbergeron_sqlglot_isin_literals
Jun 3, 2026
Merged

fix(bigframes): Fix IsInOp literal bug with sqlglot#17356
tswast merged 2 commits into
mainfrom
tbergeron_sqlglot_isin_literals

Conversation

@TrevorBergeron

Copy link
Copy Markdown
Contributor

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes #<issue_number_goes_here> 🦕

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request replaces sge.convert with sql.literal when compiling comparison operations, and adds unit tests and snapshots to verify the handling of various float literals (such as infinity, NaN, and scientific notation). The review feedback correctly points out that using sql.literal will likely raise a NameError because the sql module is not imported, and suggests using sge.literal instead for consistency and safety.

@TrevorBergeron TrevorBergeron marked this pull request as ready for review June 3, 2026 01:15
@TrevorBergeron TrevorBergeron requested review from a team as code owners June 3, 2026 01:15
@TrevorBergeron TrevorBergeron requested review from GarrettWu and removed request for a team June 3, 2026 01:15

@tswast tswast left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch!

@tswast tswast merged commit a3d93af into main Jun 3, 2026
32 checks passed
@tswast tswast deleted the tbergeron_sqlglot_isin_literals branch June 3, 2026 15:12
sycai pushed a commit that referenced this pull request Jun 9, 2026
PR created by the Librarian CLI to initialize a release. Merging this PR
will auto trigger a release.

Librarian Version: v0.16.0
Language Image:
us-central1-docker.pkg.dev/cloud-sdk-librarian-prod/images-prod/python-librarian-generator@sha256:234b9d1f2ddb057ed7ac6a38db0bf8163d839c65c6cf88ade52530cddebce59e
<details><summary>bigframes: v2.42.0</summary>

##
[v2.42.0](bigframes-v2.41.0...bigframes-v2.42.0)
(2026-06-08)

### Features

* Add ai_generate functions to the dataframe bq accessor (#17302)
([6b62cb6](6b62cb6f))

* support automatic per-cell execution history filtering and isolated
callbacks (#17144)
([7d44011](7d440111))

* create `Series.bigquery.function_name` accessors for array and AEAD
functions (#17279)
([d01a4ba](d01a4ba3))

### Bug Fixes

* include pyopenssl as a dependency (#17362)
([1f6205e](1f6205ee))

* Fix IsInOp literal bug with sqlglot (#17356)
([a3d93af](a3d93afe))

* nameless column to_frame bug for pandas 3.0 (#17371)
([b23bfa4](b23bfa4c))

</details>
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.

2 participants