Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[red-knot] Support assert_type #15194

Merged
merged 3 commits into from
Jan 10, 2025
Merged

Conversation

InSyncWithFoo
Copy link
Contributor

Summary

See #15103.

Test Plan

Markdown tests and unit tests.

Copy link
Contributor

github-actions bot commented Dec 30, 2024

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

@InSyncWithFoo
Copy link
Contributor Author

This is largely a proof-of-concept. is_equals_to() is not a thing in the specification, and I'm quite sure its name is not the best.

@MichaReiser MichaReiser added the red-knot Multi-file analysis & type inference label Dec 30, 2024
Copy link
Contributor

@sharkdp sharkdp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for working on this. I added a few initial review comments.

Copy link
Contributor

@carljm carljm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good, thank you for working on it! I think if we rebase on top of #15103 we can address some of the limitations and get it ready to land.

crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@carljm carljm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thank you! A few nits here and there, but basically this looks just right.

Copy link
Member

@AlexWaygood AlexWaygood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to merge/rebase and fix some compilation failures now that #15386 has landed :-)

crates/red_knot_python_semantic/src/types.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@carljm carljm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thank you for this, and for managing all the rebasing on top of other refactors that landed in the meantime!

@carljm carljm merged commit 6b98a26 into astral-sh:main Jan 10, 2025
21 checks passed
@InSyncWithFoo InSyncWithFoo deleted the rk-assert-type branch January 10, 2025 16:50
carljm pushed a commit that referenced this pull request Jan 10, 2025
## Summary

Follow-up to #15194.

## Test Plan

Markdown tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
red-knot Multi-file analysis & type inference
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants