You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "mikebridge (via GitHub)" <gi...@apache.org> on 2026/10/02 17:07:34 UTC
[PR] fix(semantic): reject SQL clauses on semantic views [superset]
mikebridge opened a new pull request, #44899:
URL: https://github.com/apache/superset/pull/44899
### SUMMARY
A chart-data request against a semantic view that carried a SQL `extras.where` or `extras.having` crashed with `AttributeError: 'SemanticView' object has no attribute 'database'`. `QueryObject._sanitize_filters` reads `self.datasource.database` to sanitize the clause, which only SQL datasets have, so the request failed with a 500 before reaching the provider.
This rejects non-empty SQL WHERE/HAVING extras on a semantic view up front with a `QueryObjectValidationError`, which the chart-data API already maps to a 400 with an actionable message (remove the SQL clause or use a semantic dimension filter). SQL datasets keep their existing sanitizer path unchanged.
Also adds a short note to the semantic member selections doc and the new string to `messages.pot`.
### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A (backend validation).
### TESTING INSTRUCTIONS
- `pytest tests/unit_tests/queries/query_object_test.py`: two new cases (WHERE and HAVING) fail on master with the `AttributeError` and pass here; 43 tests pass in the file.
- The translation-template drift check passes with the new string.
- Not covered: no HTTP-level test was added; the 400 mapping is the existing handling of `QueryObjectValidationError` in the chart-data API.
### ADDITIONAL INFORMATION
- [ ] Has associated issue:
- [ ] Required feature flags: `SEMANTIC_LAYERS`
- [ ] Changes UI
- [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
- [ ] Introduces new feature or API
- [ ] Removes existing feature or API
Behaviour change: a semantic-view request with SQL WHERE/HAVING extras now gets a 400 with a message, where it previously got a 500.
๐ค Generated with [Claude Code](https://claude.com/claude-code)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "mikebridge (via GitHub)" <gi...@apache.org>.
mikebridge commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-6028212177
@aminghadersohi thanks, agreed on both bot threads. One follow-up since your pass: cf761e5611 moved the WHERE/HAVING rejection to the start of `QueryObject.validate()`, so it now runs before the semantic view's provider is resolved, not only before the mapper. The test pins that with a mock that fails if the provider is touched first. The PR description notes the one remaining ordering limit: the chart-data context builder can still read the view's column metadata before validation, though no query reaches the provider.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4170953719
##########
tests/unit_tests/queries/query_object_test.py:
##########
@@ -90,6 +91,19 @@ def test_default_query_object_to_dict():
}
+@pytest.mark.parametrize("clause", ["where", "having"])
+def test_semantic_view_rejects_custom_sql_extras(clause: str) -> None:
+ """Unsupported SQL clauses fail without SQLA database state."""
+ view: SemanticView = SemanticView(name="Orders")
+ view.__dict__["implementation"] = MagicMock()
Review Comment:
<div>
<div id="suggestion">
<div id="issue"><b>Untyped mock, fragile stub</b></div>
<div id="fix">
`view.__dict__["implementation"] = MagicMock()` stubs the `SemanticView.implementation` cached_property by writing the instance dict directly. It works, but the mock is untyped contrary to the repo's mock-typing rule, and the `__dict__` write silently depends on `cached_property` checking the instance dict first. Prefer a typed mock installed via a small documented helper.
</div>
</div>
<small><i>Code Review Run #8dca49</i></small>
</div>
---
Should Bito avoid suggestions like this for future reviews? (<a href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
- [ ] Yes, avoid them
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4169914739
##########
superset/common/query_object.py:
##########
@@ -494,6 +494,18 @@ def _is_valid_date_range(self, date_range: str) -> bool:
return False
def _sanitize_filters(self) -> None:
+ if (
+ self.datasource
+ and self.datasource.type == "semantic_view"
+ and (self.extras.get("where") or self.extras.get("having"))
Review Comment:
**Suggestion:** Semantic mapper code explicitly converts these extras into provider filters, so this validation rejects supported semantic queries before providers can process them.
**Assessment:** ๐ `Major` ยท ๐ `Occurrence: Sometimes` ยท ๐ท๏ธ `Api mismatch`
[](https://docs.codeant.ai/cli/resolve-pr-comments-skill) [](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=b7122044296a47538d03da86bf654e6e&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset) [](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt_id=b7122044296a47538d03da86bf654e6e&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
<details>
<summary><b>Prompt for AI Agent ๐ค </b></summary>
```mdx
This is a comment left during a code review.
**Path:** superset/common/query_object.py
**Line:** 498:500
**Comment:**
*Api Mismatch: Semantic mapper code explicitly converts these extras into provider filters, so this validation rejects supported semantic queries before providers can process them.
Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix
```
</details>
<a href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F44899&comment_hash=f386b6e2b4086452ce842f185b54fcc7704ffc9536a7997108f73de1b817f307&reaction=like'>๐</a> | <a href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F44899&comment_hash=f386b6e2b4086452ce842f185b54fcc7704ffc9536a7997108f73de1b817f307&reaction=dislike'>๐</a>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-5957415210
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-5957835198
## [Codecov](https://app.codecov.io/gh/apache/superset/pull/44899?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:white_check_mark: All modified and coverable lines are covered by tests.
:white_check_mark: Project coverage is 82.09%. Comparing base ([`e048389`](https://app.codecov.io/gh/apache/superset/commit/e0483898728a79e5cd517d9048676431163eafe6?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`cd15d74`](https://app.codecov.io/gh/apache/superset/commit/cd15d74bd69352023fcf7e5bdd7f3ea5a24d3c25?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 10 commits behind head on master.
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## master #44899 +/- ##
==========================================
- Coverage 82.14% 82.09% -0.06%
==========================================
Files 2995 2995
Lines 184988 184990 +2
Branches 42814 42815 +1
==========================================
- Hits 151960 151867 -93
- Misses 30269 30344 +75
- Partials 2759 2779 +20
```
| [Flag](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage ฮ | |
|---|---|---|
| [hive](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `36.30% <0.00%> (-0.01%)` | :arrow_down: |
| [mysql](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [postgres](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [presto](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `38.18% <0.00%> (-0.01%)` | :arrow_down: |
| [python](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `86.03% <100.00%> (-0.10%)` | :arrow_down: |
| [sqlite](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.07% <0.00%> (-0.01%)` | :arrow_down: |
| [unit](https://app.codecov.io/gh/apache/superset/pull/44899/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `79.09% <100.00%> (+<0.01%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
</details>
[:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/superset/pull/44899?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
- :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "mikebridge (via GitHub)" <gi...@apache.org>.
mikebridge commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4201824649
##########
tests/unit_tests/queries/query_object_test.py:
##########
@@ -90,6 +91,19 @@ def test_default_query_object_to_dict():
}
+@pytest.mark.parametrize("clause", ["where", "having"])
+def test_semantic_view_rejects_custom_sql_extras(clause: str) -> None:
+ """Unsupported SQL clauses fail without SQLA database state."""
+ view: SemanticView = SemanticView(name="Orders")
+ view.__dict__["implementation"] = MagicMock()
Review Comment:
The test this pointed at was rewritten in cf761e5611: it now installs a `PropertyMock` that raises if `SemanticView.implementation` is accessed, to prove the SQL-extras rejection runs before the provider is resolved. So the `__dict__` stub is gone from this test.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "gabotorresruiz (via GitHub)" <gi...@apache.org>.
gabotorresruiz commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4190345209
##########
superset/common/query_object.py:
##########
@@ -494,6 +494,18 @@ def _is_valid_date_range(self, date_range: str) -> bool:
return False
def _sanitize_filters(self) -> None:
+ if (
+ self.datasource
+ and self.datasource.type == "semantic_view"
+ and (self.extras.get("where") or self.extras.get("having"))
+ ):
+ raise QueryObjectValidationError(
+ _(
+ "SQL WHERE/HAVING expressions are not supported for semantic "
+ "views. Remove the SQL clause or use a semantic dimension filter."
+ )
+ )
Review Comment:
Not a blocker, more of a direction question. The mapper still carries `_get_filters_from_extras` (`superset/semantic_layers/mapper.py:500`), which deliberately turns these same extras into `Operator.ADHOC` filters and has its own cases in `mapper_test.py`, and `fetch_values_predicate` goes through the same operator. With this check every `QueryObject` path rejects before the mapper runs, so that conversion becomes unreachable. Is retiring it the intent, or would the better shape be to skip only the SQLA sanitizer here and let the provider accept or reject `ADHOC` filters, the way `ADHOC_EXPRESSIONS_IN_ORDERBY` is already a per-provider capability? I can see the argument for rejecting, since without `sanitize_clause` a pass-through would hand unsanitized caller SQL to the provider. If rejecting is the call, a follow-up that removes or annotates the now dead mapper branch would keep the two from drifting.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "rebenitez1802 (via GitHub)" <gi...@apache.org>.
rebenitez1802 merged PR #44899:
URL: https://github.com/apache/superset/pull/44899
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-6025451160
## CodeAnt PR Risk: Low Risk
- The PR appears safe to merge; custom SQL WHERE and HAVING clauses on semantic views are intentionally rejected before provider access.
- Tests verify both clauses fail validation before provider access, and the docs direct users to semantic dimension filters instead.
**Assessed commit:** `cf761e56110c`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-5961629239
<!-- Bito Reply -->
The flagged issue is correct. The current implementation in `superset/common/query_object.py` performs a hard validation that rejects `where` and `having` clauses for semantic views before the semantic mapper can process them. To resolve this, you should remove the explicit validation block in `_sanitize_filters` and allow the semantic mapper to handle these extras, as it is designed to convert them into provider filters.
Would you like me to implement this fix and check the rest of the PR comments for you?
**superset/common/query_object.py**
```
def _sanitize_filters(self) -> None:
- if (
- self.datasource
- and self.datasource.type == "semantic_view"
- and (self.extras.get("where") or self.extras.get("having"))
- ):
- raise QueryObjectValidationError(
- _(
- "SQL WHERE/HAVING expressions are not supported for semantic "
- "views. Remove the SQL clause or use a semantic dimension filter."
- )
- )
-
from superset.jinja_context import get_template_processor
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "mikebridge (via GitHub)" <gi...@apache.org>.
mikebridge commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4200434419
##########
superset/common/query_object.py:
##########
@@ -494,6 +494,18 @@ def _is_valid_date_range(self, date_range: str) -> bool:
return False
def _sanitize_filters(self) -> None:
+ if (
+ self.datasource
+ and self.datasource.type == "semantic_view"
+ and (self.extras.get("where") or self.extras.get("having"))
+ ):
+ raise QueryObjectValidationError(
+ _(
+ "SQL WHERE/HAVING expressions are not supported for semantic "
+ "views. Remove the SQL clause or use a semantic dimension filter."
+ )
+ )
Review Comment:
Good catch. The mapper still translates these extras for direct calls, but we've decided to keep custom SQL WHERE/HAVING unsupported on semantic views for this first release, so the 400 stays.
- f93900c18c documents that boundary on the mapper helper: it is not reachable from the chart-data path.
- cf761e5611 moves the rejection to the start of `QueryObject.validate()`, before the semantic view's provider is resolved, with a test that fails if the provider is touched first.
Per-provider support would need its own sanitization and capability design, along the lines you describe for `ADHOC_EXPRESSIONS_IN_ORDERBY`. One known limit: the chart-data context builder can still read the view's column metadata before validation runs; the PR description notes it.
##########
superset/common/query_object.py:
##########
@@ -494,6 +494,18 @@ def _is_valid_date_range(self, date_range: str) -> bool:
return False
def _sanitize_filters(self) -> None:
+ if (
+ self.datasource
+ and self.datasource.type == "semantic_view"
+ and (self.extras.get("where") or self.extras.get("having"))
Review Comment:
Custom SQL WHERE/HAVING on semantic views is intentionally unsupported for this first release, so rejecting it here is the intended behaviour. The mapper's conversion helper is kept for direct callers, and f93900c18c documents that it is not reachable from chart-data. Provider-specific support would need a separate capability and sanitization design.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on code in PR #44899:
URL: https://github.com/apache/superset/pull/44899#discussion_r4200438635
##########
superset/common/query_object.py:
##########
@@ -494,6 +494,18 @@ def _is_valid_date_range(self, date_range: str) -> bool:
return False
def _sanitize_filters(self) -> None:
+ if (
+ self.datasource
+ and self.datasource.type == "semantic_view"
+ and (self.extras.get("where") or self.extras.get("having"))
Review Comment:
โ
**Customized review instruction saved!**
**Instruction:**
> Do not flag rejection of custom SQL WHERE/HAVING on semantic views in query-object validation; this is intentionally unsupported for the first release.
**Applied to:**
- `superset/common/query_object.py`
---
๐ก *To manage or update this instruction, visit: [CodeAnt AI Settings](https://app.codeant.ai/org/settings/learnings)*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-5963518002
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
<details>
<summary>
Bito Usage Guide
</summary>
**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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
**Configuration**
This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
**Documentation & Help**
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(semantic): reject SQL clauses on semantic views [superset]
Posted by "netlify[bot] (via GitHub)" <gi...@apache.org>.
netlify[bot] commented on PR #44899:
URL: https://github.com/apache/superset/pull/44899#issuecomment-5957442036
### <span aria-hidden="true">โ
</span> Deploy Preview for *superset-docs-preview* ready!
| Name | Link |
|:-:|------------------------|
|<span aria-hidden="true">๐จ</span> Latest commit | cd15d74bd69352023fcf7e5bdd7f3ea5a24d3c25 |
|<span aria-hidden="true">๐</span> Latest deploy log | https://app.netlify.com/projects/superset-docs-preview/deploys/6abfe4d6053f340008bdd9f7 |
|<span aria-hidden="true">๐</span> Deploy Preview | [https://deploy-preview-44899--superset-docs-preview.netlify.app](https://deploy-preview-44899--superset-docs-preview.netlify.app) |
|<span aria-hidden="true">๐ฑ</span> Preview on mobile | <details><summary> Toggle QR Code... </summary><br /><br /><br /><br />_Use your smartphone camera to open QR code link._</details> |
|<span aria-hidden="true">๐ค</span> Make changes | [Run an agent on this branch](https://app.netlify.com/projects/superset-docs-preview/agent-runs#DcrJDYAgEADAXvYtCQji0YFlAAvRhEvgoTH2Lr95zAu5pJAbbAAD6KKiObqrIWzkgjNSbVCxnYbUyxN7t6Jqj2izT8-OvUqlnRUo6cQdF5TSRSOubobvBw) |
---
<!-- [superset-docs-preview Preview](https://deploy-preview-44899--superset-docs-preview.netlify.app) -->
_To edit notification comments on pull requests, go to your [Netlify project configuration](https://app.netlify.com/projects/superset-docs-preview/configuration/notifications#deploy-notifications)._
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org