SY-3768: Oracle Prep 10: Fix Mypy Type Checking in Python Client#1991
Merged
SY-3768: Oracle Prep 10: Fix Mypy Type Checking in Python Client#1991
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## rc #1991 +/- ##
==========================================
- Coverage 53.51% 53.04% -0.47%
==========================================
Files 2406 2413 +7
Lines 138508 138433 -75
Branches 7106 7102 -4
==========================================
- Hits 74121 73437 -684
- Misses 62582 63246 +664
+ Partials 1805 1750 -55
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…5-oracle-prep-8-standardize-python-api-naming-conventions
…ventions' of https://github.com/synnaxlabs/synnax into sy-3768-oracle-prep-10-fix-mypy-type-checking-in-client
…ventions' of https://github.com/synnaxlabs/synnax into sy-3768-oracle-prep-10-fix-mypy-type-checking-in-client
…5-oracle-prep-8-standardize-python-api-naming-conventions
…ventions' of https://github.com/synnaxlabs/synnax into sy-3768-oracle-prep-10-fix-mypy-type-checking-in-client
pjdotson
requested changes
Feb 18, 2026
Base automatically changed from
sy-3765-oracle-prep-8-standardize-python-api-naming-conventions
to
rc
February 18, 2026 18:25
…8-oracle-prep-10-fix-mypy-type-checking-in-client
pjdotson
requested changes
Feb 19, 2026
Contributor
pjdotson
left a comment
There was a problem hiding this comment.
Approved after last comments are addressed
client/py/synnax/task/client.py
Outdated
|
|
||
| _TASK_STATE_CHANNEL = "sy_status_set" | ||
| _TASK_CMD_CHANNEL = "sy_task_cmd" | ||
| _list = list |
Contributor
There was a problem hiding this comment.
but we seem to use list (without an underscore) for most of the types in here?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue Pull Request
Linear Issue
SY-####
Description
Basic Readiness
Greptile Overview
Greptile Summary
This PR systematically addresses mypy type checking issues across the Python client codebase by adding proper type annotations, casts, and assertions throughout 70 files.
Key Changes
cast(), assertions, and proper type annotations across all modulesarc.Taskandtask.Taskby renaming toArcTaskAnytypeshas_params()helper function and improved parameter checking logicExceptiontoBaseExceptionwhere appropriateranger/client.pyParamsTypeAlias definition to after helper functions for proper orderingImpact
The changes are purely type-checking improvements without behavioral modifications. The PR enhances code maintainability and catches potential type errors at development time rather than runtime.
Confidence Score: 5/5
Important Files Changed
Sequence Diagram
sequenceDiagram participant Dev as Developer participant Code as Python Code participant Mypy as Type Checker participant Runtime as Runtime Dev->>Code: Write code with type hints Code->>Mypy: Run type checking Note over Mypy: Before PR: Type errors found Dev->>Code: Add explicit casts Dev->>Code: Add assertions Dev->>Code: Fix type annotations Dev->>Code: Add property guards Code->>Mypy: Re-run type checking Note over Mypy: After PR: All type checks pass Mypy->>Dev: ✓ Type checking successful Code->>Runtime: Deploy with confidenceLast reviewed commit: 6fb0f80