Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR upgrades the S3MP package to Python 3.10 and modernizes its infrastructure by migrating from conda to uv, adding type hints, and integrating optional image metadata parsing capabilities.
Changes:
- Upgraded to Python 3.10 with modern type hints (using
|union syntax instead ofUnion,list/dictinstead ofList/Dict) - Replaced conda environment files with uv-based dependency management in
pyproject.toml - Added optional
imgparsesupport for parsing image metadata and computing GSD - Introduced pre-commit hooks with ruff and mypy for code quality
- Updated GitHub Actions workflows for CI/CD
Reviewed changes
Copilot reviewed 29 out of 37 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Updated version to 0.7.0, migrated to uv with hatchling build system, added image parsing optional dependencies |
| tests/test_s3_utils.py | Updated type hints, added strict=True to zip calls, fixed test to check expected folder contents |
| S3MP/utils/s3_utils.py | Modernized type hints, added assertions for None checks, improved None handling with explicit comparisons |
| S3MP/utils/local_file_utils.py | Updated type hints and simplified file opening |
| S3MP/utils/image_utils.py | New file adding image metadata parsing and GSD computation functionality |
| S3MP/types.py | Modernized type imports and added proper exports |
| S3MP/transfer_configs.py | Fixed integer type for io_queue_size parameter |
| S3MP/prefix_queries.py | Changed return types to generators and updated type hints |
| S3MP/multipart_uploads.py | Removed unused imports and updated formatting |
| S3MP/mirror_path.py | Added image metadata methods, improved None handling, updated type hints |
| S3MP/keys.py | Added None checks with assertions, improved type checking with isinstance |
| S3MP/global_config.py | Made default_bucket_key a property with setter method, improved error handling |
| S3MP/callbacks.py | Updated type hints and improved type handling |
| S3MP/async_utils.py | Fixed return types and updated type hints |
| S3MP/_version.py | Changed to use importlib.metadata.version for dynamic versioning |
| S3MP/init.py | Added explicit __all__ export |
| README.md | Added image metadata parsing documentation and uv installation instructions |
| .pre-commit-config.yaml | Added pre-commit configuration with ruff and mypy |
| .github/workflows/* | Updated workflows for uv-based CI/CD |
| environment.yml, dev-environment.yml | Removed conda environment files |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.
Description
imgparsersupport for Sentera developersPR Checklist
pyproject.toml.Breaking Changes
default_bucket_keydirectly, now useset_default_bucket_key