Skip to content

Conversation

@alexfikl
Copy link
Collaborator

This fixes some genuine looking RUF052 errors where the function arguments just have a _name because they were meant not to shadow the outer scope.

Comment on lines 105 to 106
def sub(name: str) -> Variable | Subscript:
return Variable(name)[subscript] if subscript else Variable(name)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is meant to silence the deprecation in pymbolic about an empty subscript. I went with keeping the same behavior here, i.e. returning the expression itself if the subscript is empty. Let me know if it looks ok!

@alexfikl
Copy link
Collaborator Author

Hm, looks like the pylint bug is still not fixed :(

@inducer
Copy link
Owner

inducer commented Dec 13, 2024

Hm, looks like the pylint bug is still not fixed :(

The corresponding issue is not an encouraging read: pylint-dev/pylint#10112.

I think I may just disable pylint in ci-support if the Python version is 3.13.

@inducer
Copy link
Owner

inducer commented Dec 13, 2024

@alexfikl
Copy link
Collaborator Author

alexfikl commented Dec 13, 2024

The corresponding issue is not an encouraging read: pylint-dev/pylint#10112.

I think I may just disable pylint in ci-support if the Python version is 3.13.

Not great, but that sounds fine by me. They'll probably get around to fixing it soon-ish.

@inducer
Copy link
Owner

inducer commented Dec 13, 2024

Found a way that's a bit less of a blunt hammer: inducer/ci-support@8cf069c

@inducer inducer merged commit c4f00b8 into inducer:main Dec 13, 2024
12 checks passed
@inducer
Copy link
Owner

inducer commented Dec 13, 2024

Thx!

@alexfikl alexfikl deleted the fix-deprecations branch December 14, 2024 08:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants