Skip to content

[ty] Add tests for implicit submodule references#21793

Merged
Gankra merged 3 commits intomainfrom
gankra/from-ide
Dec 4, 2025
Merged

[ty] Add tests for implicit submodule references#21793
Gankra merged 3 commits intomainfrom
gankra/from-ide

Conversation

@Gankra
Copy link
Contributor

@Gankra Gankra commented Dec 4, 2025

Summary

I realized we don't really test DefinitionKind::ImportFromSubmodule in the IDE at all, so here's a bunch of them, just recording our current behaviour.

Test Plan

stares at the camera

@Gankra Gankra added the internal An internal refactor or improvement label Dec 4, 2025
@Gankra Gankra requested a review from dcreager as a code owner December 4, 2025 14:55
@Gankra Gankra added the ty Multi-file analysis & type inference label Dec 4, 2025
@astral-sh-bot
Copy link

astral-sh-bot bot commented Dec 4, 2025

Diagnostic diff on typing conformance tests

No changes detected when running ty on typing conformance tests ✅

@astral-sh-bot
Copy link

astral-sh-bot bot commented Dec 4, 2025

mypy_primer results

Changes were detected when running on open source projects
scikit-build-core (https://github.com/scikit-build/scikit-build-core)
- src/scikit_build_core/_logging.py:153:13: warning[unsupported-base] Unsupported class base with type `<class 'Mapping[str, Style]'> | <class 'Mapping[str, Divergent]'>`
- Found 39 diagnostics
+ Found 38 diagnostics

pandas-stubs (https://github.com/pandas-dev/pandas-stubs)
+ pandas-stubs/_typing.pyi:1209:16: warning[unused-ignore-comment] Unused blanket `type: ignore` directive
- Found 5513 diagnostics
+ Found 5514 diagnostics

No memory usage changes detected ✅

@Gankra
Copy link
Contributor Author

Gankra commented Dec 4, 2025

Added comments to every test result explaining if I think it's correct or incorrect (all the wrong ones have TODO(submodule-imports))

@Gankra
Copy link
Contributor Author

Gankra commented Dec 4, 2025

CC @MichaReiser I don't think your import work necessarily needs to fix any of these but this might merge-conflict/snapshot-conflict you.

@Gankra Gankra enabled auto-merge (squash) December 4, 2025 15:42
@Gankra Gankra merged commit cccb0bb into main Dec 4, 2025
40 checks passed
@Gankra Gankra deleted the gankra/from-ide branch December 4, 2025 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal An internal refactor or improvement ty Multi-file analysis & type inference

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant