Conversation
Code Review Agent Run #8459ceActionable Suggestions - 0Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
✅ Deploy Preview for superset-docs-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #44546 +/- ##
=======================================
Coverage 81.06% 81.06%
=======================================
Files 2955 2955
Lines 178300 178300
Branches 41307 41307
=======================================
Hits 144533 144533
Misses 31056 31056
Partials 2711 2711
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
3e5f158 to
fe7821f
Compare
|
The flagged issue is correct. In the current implementation, if a DAO lookup or lazy datasource loading (such as To resolve this, you should wrap the annotation-related lookups and cache-key generation in a I have checked the PR comments, and there are no other comments to address. Would you like me to implement this fix for you? superset/common/query_context_processor.py |
There was a problem hiding this comment.
Code Review Agent Run #b23663
Actionable Suggestions - 6
-
tests/unit_tests/common/test_query_context_processor.py - 4
- Missing test type hints · Line 118-118
- Fixture missing return type · Line 183-193
- Fail-closed log unasserted · Line 236-252
- Inline function-body import · Line 2340-2340
-
tests/testcontainers/db_engine_specs/test_bigquery.py - 2
- Missing test docstring · Line 127-127
- Missing fixture param type hint · Line 131-131
Additional Suggestions - 1
-
tests/unit_tests/common/test_query_context_processor.py - 1
-
Unverified mock-behavior claim · Line 123-129The comment claims bare `patch()` autodetects `security_manager` as an async spec because the real object trips `unittest.mock`'s coroutine inference. CPython 3.11's `mock.py` does apply `_is_async_obj(original)` when spec is None (line 1460), but whether the real `SupersetSecurityManager` actually trips it could not be executed here (no flask installed). If the premise is wrong, the comment misleads future maintainers — verify or soften it.
-
Review Details
-
Files reviewed - 3 · Commit Range:
19954fd..fe7821f- superset/common/query_context_processor.py
- tests/testcontainers/db_engine_specs/test_bigquery.py
- tests/unit_tests/common/test_query_context_processor.py
-
Files skipped - 0
-
Tools
- MyPy (Static Code Analysis) - ✔︎ Successful
- Astral Ruff (Static Code Analysis) - ✔︎ Successful
- Whispers (Secret Scanner) - ✔︎ Successful
- Detect-secrets (Secret Scanner) - ✔︎ Successful
Bito Usage Guide
Commands
Type the following command in the pull request comment and save the comment.
-
/review- Manually triggers an incremental AI Review. -
/review full- Manually triggers a full AI Review. -
/pause- Pauses automatic reviews on this pull request. -
/resume- Resumes automatic reviews. -
/resolve- Marks all Bito-posted review comments as resolved. -
/abort- Cancels all in-progress reviews.
Refer to the documentation for additional commands.
Configuration
This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.
Documentation & Help
Code Review Agent Run #873076Actionable Suggestions - 0Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
…QL engine Adds testcontainers coverage for superset/db_engine_specs/bigquery.py's _monkeypatch_bigquery_string_literal, using the new BigQueryContainer (testcontainers/testcontainers-python#1121) to run apostrophe, percent-sign, and combined-value queries against a real GoogleSQL emulator rather than reasoning about the sqlalchemy-bigquery dialect and BigQuery DBAPI paramstyle handling from source alone. Also pins down, with a direct reproduction, why the doubled-single-quote escape #38835 replaced doesn't work on BigQuery. Co-Authored-By: Evan Rusackas <evan@preset.io> Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Adds a one-line docstring to the combined percent/apostrophe round-trip test and a `bigquery.Client` annotation on the `bq_client` fixture parameter so the new tests match their siblings. Co-Authored-By: Evan Rusackas <evan@preset.io> Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
7f2a133 to
d7bf852
Compare
Code Review Agent Run #a3bbe1Actionable Suggestions - 0Filtered by Review RulesBito filtered these suggestions based on rules created automatically for your feedback. Manage rules.
Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
SUMMARY
Adds testcontainers coverage that runs Superset's actual BigQuery string-literal escaping (
_monkeypatch_bigquery_string_literalinsuperset/db_engine_specs/bigquery.py) against a real GoogleSQL engine (thegoccy/bigquery-emulator, via the newBigQueryContainerin testcontainers/testcontainers-python#1121), instead of only reasoning about it from thesqlalchemy-bigquerydialect source and the BigQuery DBAPI'spyformathandling.This grew out of chasing down whether #35857/#38835 (apostrophes breaking BigQuery filter values) is still correctly fixed, and whether the DBAPI's
%-doubling behavior for percent signs is safe given Superset's actual execution path (cursor.execute(query), no separate bind parameters). Both turned out fine, this locks it in with a real engine rather than leaving it as a one-time manual check.Covers: apostrophe values, percent-sign values, apostrophe+percent combined, and a documentation test that reproduces the exact syntax error BigQuery gives for the doubled-single-quote escape convention the old code used to emit (
'Armando''s'), so it's clear why the fix in #38835 was needed if anyone's tempted to revert it.TESTING INSTRUCTIONS
Gated behind
pytest.mark.testcontainers(excluded from the default test run viapytest.ini) andrequire_driver("testcontainers.community.google"), matching the existingtests/testcontainers/db_engine_specs/convention. Needs Docker running locally, or runs via.github/workflows/testcontainers.yml:All 4 tests pass locally against
superset/db_engine_specs/bigquery.pyunmodified.ADDITIONAL INFORMATION
🤖 Generated with Claude Code