fix(mypy): resolve boto3 S3 typing issues in files.py

Add boto3-stubs[s3] dev dependency and use TYPE_CHECKING with cast() to
provide proper S3Client type hints while avoiding boto3-stubs' overly
strict overload definitions.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Ashwin Bharambe 2025-10-27 23:35:31 -07:00
parent 3c81b23fbe
commit 9c877730ca
3 changed files with 30 additions and 13 deletions

View file

@ -67,8 +67,8 @@ dev = [
"pytest-cov",
"pytest-html",
"pytest-json-report",
"pytest-socket", # For blocking network access in unit tests
"nbval", # For notebook testing
"pytest-socket", # For blocking network access in unit tests
"nbval", # For notebook testing
"black",
"ruff",
"mypy",
@ -78,9 +78,9 @@ dev = [
"pandas-stubs",
"types-psutil",
"types-tqdm",
"boto3-stubs",
"boto3-stubs[s3]",
"pre-commit",
"ruamel.yaml", # needed for openapi generator
"ruamel.yaml", # needed for openapi generator
]
# These are the dependencies required for running unit tests.
unit = [