codeant-ai-for-open-source[bot] commented on code in PR #43698:
URL: https://github.com/apache/superset/pull/43698#discussion_r3890480955
##########
tests/unit_tests/db_engine_specs/test_singlestore.py:
##########
@@ -218,3 +218,21 @@ def test_get_function_names_with_db() -> None:
assert "is_prime" in functions
mock_database.get_df.assert_called_once_with("SHOW FUNCTIONS IN `db``1`")
+
+
+def test_singlestore_properties() -> None:
+ from superset.db_engine_specs.mysql import MySQLEngineSpec
+
+ assert SingleStoreSpec.engine == "singlestoredb"
+ assert SingleStoreSpec.engine_name == "SingleStore"
+ assert issubclass(SingleStoreSpec, MySQLEngineSpec)
Review Comment:
**Suggestion:** `SingleStoreSpec` directly inherits `BaseEngineSpec`, not
`MySQLEngineSpec`, so this assertion always fails. [api mismatch]
**Assessment:** ๐ `Major` ยท ๐ `Occurrence: Often`
[](https://docs.codeant.ai/cli/resolve-pr-comments-skill)
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=9aa00acbf4a64f5096dba4eff44c2daa&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=9aa00acbf4a64f5096dba4eff44c2daa&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:** tests/unit_tests/db_engine_specs/test_singlestore.py
**Line:** 228:228
**Comment:**
*Api Mismatch: `SingleStoreSpec` directly inherits `BaseEngineSpec`,
not `MySQLEngineSpec`, so this assertion always fails.
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%2F43698&comment_hash=98932cba19df7b5009ac3afad2866e47f0d4c4b824e33ac6a12e64e8b8d3a094&reaction=like'>๐</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F43698&comment_hash=98932cba19df7b5009ac3afad2866e47f0d4c4b824e33ac6a12e64e8b8d3a094&reaction=dislike'>๐</a>
##########
tests/unit_tests/db_engine_specs/test_ydb.py:
##########
@@ -81,3 +81,22 @@ def test_specify_credentials() -> None:
YDBEngineSpec.update_params_from_encrypted_extra(database, params)
connect_args = params.setdefault("connect_args", {})
assert connect_args.get("credentials") == auth_params
+
+
+def test_ydb_properties() -> None:
+ from superset.db_engine_specs.ydb import YDBEngineSpec
+
+ assert YDBEngineSpec.engine == "yql"
+ assert YDBEngineSpec.engine_name == "YDB"
+ assert YDBEngineSpec.default_driver == "ydb"
+ assert YDBEngineSpec.allows_alias_in_orderby is True
+
+
+def test_ydb_metadata() -> None:
+ from superset.db_engine_specs.ydb import YDBEngineSpec
+
+ metadata = YDBEngineSpec.metadata
+ assert "YDB is a distributed SQL database" in metadata["description"]
+ assert metadata["logo"] == "ydb.svg"
+ assert "ydb" in metadata["pypi_packages"]
+
Review Comment:
**Suggestion:** YDB metadata contains `ydb-sqlalchemy` and
`ydb-sqlglot-plugin`, not `ydb`, so this assertion always fails. [api mismatch]
**Assessment:** ๐ `Major` ยท ๐ `Occurrence: Often`
[](https://docs.codeant.ai/cli/resolve-pr-comments-skill)
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=dbd605731fd148b89d462e0be6564699&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=dbd605731fd148b89d462e0be6564699&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:** tests/unit_tests/db_engine_specs/test_ydb.py
**Line:** 102:102
**Comment:**
*Api Mismatch: YDB metadata contains `ydb-sqlalchemy` and
`ydb-sqlglot-plugin`, not `ydb`, so this assertion always fails.
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%2F43698&comment_hash=aba6c519ee2e69b0823c2ac005d415f0aaeca6a5e134b59aae5c335823ae7e9a&reaction=like'>๐</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F43698&comment_hash=aba6c519ee2e69b0823c2ac005d415f0aaeca6a5e134b59aae5c335823ae7e9a&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]