-
Notifications
You must be signed in to change notification settings - Fork 54
Add pyright configuration file
#225
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
Conversation
WalkthroughThe Pyright configuration in the Changes
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
pyrightconfig.json (1)
1-3: Consider expanding the minimal config for clarity & future-proofingA single
extraPathsentry works, but Pyright will default to analyzing every file under the repo unless told otherwise. Adding an explicitinclude(and optionally anexclude) list makes the intent clearer, speeds up analysis, and avoids editors mistakenly type-checking irrelevant folders (e.g.dist,.venv, or generated code).Example patch:
{ + // Folders to be type-checked + "include": ["./src"], + "extraPaths": ["./src"] + // "exclude": ["./dist", "./.venv", "**/__pycache__"] }Optional but recommended.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
pyrightconfig.json(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build-pr
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can use [tool.pyright] section in pyproject.toml
with this change, the new file take precedence, so the "older" settings is not used -> cause CI failure
`pyright` can be used as a language server for Python. Tell `pyright` where to find the source files, so it can resolve imports correctly.
|
Ah didn't see you have that. Updated |
tisnik
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you
Description
pyrightcan be used as a language server for Python.Tell
pyrightwhere to find the source files, so it can resolve imports correctlyType of change
Related Tickets & Documents
Checklist before requesting a review
Testing
Pyright works better
Summary by CodeRabbit