Skip to content

Bump pyright to 1.1.414 and fix new type errors - #26272

Open
Austin Dickey (austin3dickey) wants to merge 2 commits into
microsoft:mainfrom
austin3dickey:bump-pyright
Open

Austin Dickey (austin3dickey) wants to merge 2 commits into
microsoft:mainfrom
austin3dickey:bump-pyright

Conversation

@austin3dickey

Copy link
Copy Markdown

Fixes #26238. This PR changes the pyright version from 1.1.308 to 1.1.414.

Pyright 1.1.308 is over 3 years old at this point, and doesn't work with django-stubs 6.1.1 on Python 3.12 and later, so if you're running Pyright with Python 3.12 on this repo it reports 4 false errors in the simple_django test fixture. Pyright 1.1.414 doesn't report these errors.

The new version reports 9 other errors, too, which I fixed.

Pyright 1.1.308 can't handle the ModelBase.__getattr__ fallback in django-stubs 6.1.1, which causes errors when type-checking on Python 3.12+. Bump to the latest release and fix the errors it reports.
@austin3dickey

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree company="Posit"

@austin3dickey

Copy link
Copy Markdown
Author

Would a maintainer please approve the workflows so I can fix anything else that's broken?

@edvilme Eduardo Villalpando Mello (edvilme) added debt Code quality issues skip package*.json package.json and package-lock.json don't both need updating labels Nov 16, 2026
@austin3dickey

Copy link
Copy Markdown
Author

Thanks Eduardo Villalpando Mello (@edvilme) ! I think the only failure was #26290 so I merged main in. Could you please approve again?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

debt Code quality issues skip package*.json package.json and package-lock.json don't both need updating

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bump version of pyright used in CI

2 participants