codeant-ai-for-open-source[bot] commented on code in PR #43757:
URL: https://github.com/apache/superset/pull/43757#discussion_r4054143299
##########
superset/datasets/schemas.py:
##########
@@ -178,6 +189,8 @@ class DatasetPostSchema(Schema):
normalize_columns = fields.Boolean(load_default=False)
always_filter_main_dttm = fields.Boolean(load_default=False)
currency_code_column = fields.String(allow_none=True, validate=Length(0,
250))
+ partition_column = fields.String(allow_none=True, validate=Length(0, 250))
+ partition_mapped_column = fields.String(allow_none=True,
validate=Length(0, 250))
Review Comment:
**Suggestion:** These fields are accepted by the POST schema, but the API
create allowlist excludes them, so partition mappings supplied during dataset
creation are silently discarded.
**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=5be23a41530a4fceafbed07c2a0d1496&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=5be23a41530a4fceafbed07c2a0d1496&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/datasets/schemas.py
**Line:** 192:193
**Comment:**
*Api Mismatch: These fields are accepted by the POST schema, but the
API create allowlist excludes them, so partition mappings supplied during
dataset creation are silently discarded.
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%2F43757&comment_hash=10555d09403286a464e385b303052e84c422fa6e17cad74c3782e29781b6ee58&reaction=like'>๐</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F43757&comment_hash=10555d09403286a464e385b303052e84c422fa6e17cad74c3782e29781b6ee58&reaction=dislike'>๐</a>
##########
superset/datasets/schemas.py:
##########
@@ -100,6 +100,17 @@ class DatasetColumnsPutSchema(Schema):
datetime_format = fields.String(
allow_none=True, validate=[Length(1, 100), validate_python_date_format]
)
+ partition_value_transform = fields.String(
+ allow_none=True,
+ metadata={
+ "description": (
+ "SQL expression containing a :value placeholder. Filters on "
+ "this column are mirrored onto the dataset's partition column "
+ "with the value passed through this transform."
+ )
+ },
+ )
+ partition_transform_is_monotonic = fields.Boolean(load_default=False)
Review Comment:
**Suggestion:** An omitted field deserializes as `False`; partial or legacy
column updates therefore overwrite a stored `True` monotonic setting and
disable range mirroring.
**Assessment:** ๐ `Major` ยท ๐ `Occurrence: Sometimes` ยท ๐ท๏ธ `Logic error`
[](https://docs.codeant.ai/cli/resolve-pr-comments-skill)
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=a49e1b5c042a4e0297bed4c50e049524&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=a49e1b5c042a4e0297bed4c50e049524&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/datasets/schemas.py
**Line:** 113:113
**Comment:**
*Logic Error: An omitted field deserializes as `False`; partial or
legacy column updates therefore overwrite a stored `True` monotonic setting and
disable range mirroring.
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%2F43757&comment_hash=a4ab1ac1a80c2e3afd15eeb36a615bb56ff378ac780782869fa2ee43b4a527c3&reaction=like'>๐</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F43757&comment_hash=a4ab1ac1a80c2e3afd15eeb36a615bb56ff378ac780782869fa2ee43b4a527c3&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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]