You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "sadpandajoe (via GitHub)" <gi...@apache.org> on 2026/10/15 02:14:29 UTC
[I] Nightly full-repo pre-commit fails: mypy errors in query_errors_test and helpers_test [superset]
sadpandajoe opened a new issue, #45314:
URL: https://github.com/apache/superset/issues/45314
## Problem
The nightly scheduled `pre-commit checks` run on master fails at the full-repo `mypy (main)` step with 7 errors in two test files: six `[arg-type]` errors in `tests/unit_tests/semantic_layers/query_errors_test.py` (lines 191, 269, 476: `set[Never]` passed where `list[Dimension]`/`list[Metric]` is expected) and one `[unused-ignore]` in `tests/unit_tests/models/helpers_test.py:3085`. First failing run: https://github.com/apache/superset/actions/runs/38521870062 (job 115713188528).
## Root cause
#45110 (1fced034d3) added `query_errors_test.py` calling `SemanticQuery(dimensions=set(), metrics=set())`, but `SemanticQuery.dimensions`/`.metrics` are lists (`superset-core/src/superset_core/semantic_layers/types.py`). The `superset_core.*` override uses `follow_imports="skip"`, so changed-file CI sees `Any`; the nightly passes `superset-core/**` and sees the real types. #45133 (f5404f7eae) widened `FilterValues` in `superset/superset_typing.py:161-163` to accept `None` list items, which makes the `# type: ignore[list-item]` at `helpers_test.py:3085` unused. It didn't touch that file, so changed-file CI never ran mypy on it.
## Steps to reproduce
On master 54d2421, with mypy 1.15.0 as pinned in `.pre-commit-config.yaml`:
`mypy --ignore-missing-imports --scripts-are-modules --check-untyped-defs tests/unit_tests/models/helpers_test.py tests/unit_tests/semantic_layers/query_errors_test.py $(git ls-files 'superset-core/*.py')`
(Found via automated investigation — [Agor](https://agor.live/).)
--
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.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: [I] Nightly full-repo pre-commit fails: mypy errors in query_errors_test and helpers_test [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas closed issue #45314: Nightly full-repo pre-commit fails: mypy errors in query_errors_test and helpers_test
URL: https://github.com/apache/superset/issues/45314
--
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