-
Notifications
You must be signed in to change notification settings - Fork 2
GOATS-966 GOATS-967 GOATS-968: Implement serializers for brightness, elevation range, and exposure mode. #456
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
…elevation range, and exposure mode. - Add GPPBrightnessesSerializer to handle brightnesses form data for GPP. - Add GPPElevationRangeSerializer to handle elevation range form data for GPP. - Add GPPExposureModeSerializer to handle exposure mode form data for GPP. - Update GPPTooViewSet to format and validate new input types from serializers. - Extend test coverage for new serializers and viewset methods. - Add utility functions for normalization of input data.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #456 +/- ##
==========================================
+ Coverage 76.62% 77.45% +0.83%
==========================================
Files 237 244 +7
Lines 7547 7834 +287
Branches 464 477 +13
==========================================
+ Hits 5783 6068 +285
- Misses 1676 1677 +1
- Partials 88 89 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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 implements serializers and viewset methods to handle brightness, elevation range, and exposure mode form data for GPP ToO observations. It adds validation and formatting capabilities to transform flat form data into structured input types required by the GPP client.
- Adds three new serializers: GPPBrightnessesSerializer, GPPElevationRangeSerializer, and GPPExposureModeSerializer
- Updates GPPTooViewSet with formatting methods for the new input types
- Adds comprehensive test coverage for all serializers and viewset methods
- Includes utility functions for data normalization
Reviewed Changes
Copilot reviewed 14 out of 15 changed files in this pull request and generated 4 comments.
Show a summary per file
File | Description |
---|---|
tests/goats_tom/serializers/gpp/test_exposure_mode.py | Test coverage for exposure mode serializer validation |
tests/goats_tom/serializers/gpp/test_elevation_range.py | Test coverage for elevation range serializer validation |
tests/goats_tom/serializers/gpp/test_brightnesses.py | Test coverage for brightness serializers |
tests/goats_tom/api_views/gpp/test_toos.py | Test coverage for GPPTooViewSet formatting methods |
src/goats_tom/static/js/gpp/gpp.js | Updates API call to pass form data without stringifying |
src/goats_tom/static/js/api.js | Adds debug logging for POST requests |
src/goats_tom/serializers/gpp/utils.py | Utility function for normalizing string inputs |
src/goats_tom/serializers/gpp/exposure_mode.py | Serializer for exposure mode form data |
src/goats_tom/serializers/gpp/elevation_range.py | Serializer for elevation range form data |
src/goats_tom/serializers/gpp/brightnesses.py | Serializer for brightness form data |
src/goats_tom/serializers/gpp/init.py | Module initialization for GPP serializers |
src/goats_tom/serializers/init.py | Exports new GPP serializers |
src/goats_tom/api_views/gpp/toos.py | Adds formatting methods to GPPTooViewSet |
docs/changes/456.new.rst | Release note for the changes |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Checklist
doc/changes
using the PR number.