BUG: Restore UTC fallback without timezonefinder - #1143
Merged
Gui-FernandesBR merged 1 commit intoAug 13, 2026
Merged
Conversation
ting-hong-shieh
marked this pull request as ready for review
August 13, 2026 05:03
Gui-FernandesBR
approved these changes
Aug 13, 2026
Member
|
If it passes on CI, we can merge it! |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #1143 +/- ##
===========================================
+ Coverage 82.18% 83.16% +0.97%
===========================================
Files 122 129 +7
Lines 16355 16901 +546
===========================================
+ Hits 13441 14055 +614
+ Misses 2914 2846 -68 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
Pull request type
Checklist
CHANGELOG.md— no action needed; an LLM workflow auto-updates it after mergeCurrent behavior
When
EnvironmentAnalysisreceives no explicit timezone, it uses the optionaltimezonefinderdependency to select one from the launch coordinates. If thatdependency is unavailable, the fallback handler calls
warnings.warning, whichdoes not exist. Construction stops with
AttributeErrorbefore UTC can beselected.
New behavior
The fallback now calls
warnings.warn, emits the existing message, selects UTC,and localizes naive input dates. The regression test exercises the public
constructor while forcing the optional import to fail.
Breaking change
Verification
pytest tests/unit/environment/test_environment_analysis.py::test_missing_timezonefinder_defaults_to_utc -q— 1 passedpytest tests/unit/environment -m "not slow" -q— 159 passed, 6 deselectedruff check rocketpy/environment/environment_analysis.py tests/unit/environment/test_environment_analysis.pyruff format --check rocketpy/environment/environment_analysis.py tests/unit/environment/test_environment_analysis.pypylint rocketpy/environment/environment_analysis.py tests/unit/environment/test_environment_analysis.py— 10.00/10