-
Notifications
You must be signed in to change notification settings - Fork 59
Enforce strict type checking in the ITables documentation #400
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
|
Thank you for making this pull request. Did you know? You can try it on Binder: Also, the version of ITables developed in this PR can be installed with (this requires |
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.
Pull Request Overview
This PR enforces strict Pyright type checking in the ITables documentation by adding per-file ignore directives, updating code examples to match the latest API, and scoping Jupytext pre-commit hooks to docs.
- Added
# pyright: ...=falsedirectives across Markdown and Python docs to suppress expected type errors. - Updated sample DataFrame initializations and replaced
get_dict_of_test_dfs(polars=True)withget_dict_of_polars_test_dfs(). - Modified
.pre-commit-config.yamlto run Jupytext only ondocs/and streamlined its arguments.
Reviewed Changes
Copilot reviewed 34 out of 34 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| docs/troubleshooting.md | Added reportDuplicateImport=false directive |
| docs/py/troubleshooting.py | Added reportDuplicateImport=false directive |
| docs/py/polars_dataframes.py | Switched to get_dict_of_polars_test_dfs() |
| docs/polars_dataframes.md | Switched to get_dict_of_polars_test_dfs() |
| docs/py/pandas_style.py | Added reportUnknownMemberType=false directive |
| docs/pandas_style.md | Added reportUnknownMemberType=false directive |
| docs/py/options/row_group.py | Added code-cell tag and ignore for member type |
| docs/options/row_group.md | Wrapped example in code-cell and added member-type ignore |
| docs/py/options/order.py | Refactored .set_index() to constructor index= parameter |
| docs/options/order.md | Refactored .set_index() to constructor index= parameter |
| docs/py/options/allow_html.py | Added multiple reportUnknown* ignore directives |
| docs/options/allow_html.md | Wrapped example in code-cell and added ignore directives |
| docs/py/css.py | Added reportUnknownVariableType=false directive |
| docs/css.md | Added reportUnknownVariableType=false directive |
| docs/py/contributing.py | Added reportUnknownVariableType=false directive |
| docs/contributing.md | Wrapped example in code-cell and added ignore directive |
| docs/py/apps/html.py | Added reportUnknownVariableType=false directive |
| docs/apps/html.md | Wrapped example in code-cell and added ignore directive |
| docs/changelog.md | Updated changelog to reference issue link |
| .pre-commit-config.yaml | Scoped Jupytext hook to docs/ and removed --quiet arg |
Comments suppressed due to low confidence (1)
.pre-commit-config.yaml:37
- [nitpick] Removing the
--quietflag may increase noise during pre-commit runs; consider re-adding it or documenting the expected verbosity change.
args: ["--sync"]
| # pyright: reportUnknownVariableType=false | ||
|
|
Copilot
AI
May 31, 2025
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.
There are many repeated inline Pyright ignore directives across documentation files; consider centralizing these rules in a pyrightconfig.json to reduce boilerplate and improve maintainability.
| # pyright: reportUnknownVariableType=false |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #400 +/- ##
==========================================
+ Coverage 89.39% 89.63% +0.23%
==========================================
Files 44 44
Lines 1858 1852 -6
==========================================
- Hits 1661 1660 -1
+ Misses 197 192 -5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
f85d406 to
88e5957
Compare
This PR ensures that the type checks pass in strict mode when run on the ITables documentation.
Closes #395