ENH: Restore power_off/on_drag as Function objects; add _input attributes for raw user input and update changelog#941
Open
Copilot wants to merge 3 commits intorel/v1.12.0from
Open
ENH: Restore power_off/on_drag as Function objects; add _input attributes for raw user input and update changelog#941Copilot wants to merge 3 commits intorel/v1.12.0from
Copilot wants to merge 3 commits intorel/v1.12.0from
Conversation
Open
… raw user input Co-authored-by: MateusStano <69485049+MateusStano@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] [WIP] Address feedback from review on PR #935 for rel/v1.12.0 adjustments
ENH: Restore power_off/on_drag as Function objects; add _input attributes for raw user input
Mar 18, 2026
Member
|
@copilot add pr to changelog |
Co-authored-by: MateusStano <69485049+MateusStano@users.noreply.github.com>
Author
Copilot
AI
changed the title
ENH: Restore power_off/on_drag as Function objects; add _input attributes for raw user input
ENH: Restore power_off/on_drag as Function objects; add _input attributes for raw user input and update changelog
Mar 18, 2026
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## rel/v1.12.0 #941 +/- ##
============================================
Coverage 81.05% 81.06%
============================================
Files 107 107
Lines 13891 13893 +2
============================================
+ Hits 11260 11262 +2
Misses 2631 2631 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Comment on lines
+385
to
+386
| self.power_off_drag_input = power_off_drag | ||
| self.power_on_drag_input = power_on_drag |
Member
There was a problem hiding this comment.
maybe?
Suggested change
| self.power_off_drag_input = power_off_drag | |
| self.power_on_drag_input = power_on_drag | |
| self._power_off_drag_input = power_off_drag | |
| self._power_on_drag_input = power_on_drag |
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
black rocketpy/ tests/) has passed locallypytest tests -m slow --runslow) have passed locallyCHANGELOG.mdhas been updated (if relevant)Current behavior
Rocket.power_off_dragandRocket.power_on_draghad been changed to store raw user input, which broke backward compatibility because these public attributes were historicallyFunctionobjects. This also created type inconsistency depending on construction path (for example,from_dictcould still pass aFunction).New behavior
Rocket.power_off_dragandRocket.power_on_dragas Mach-onlyFunctionobjects (aliasingpower_off_drag_by_machandpower_on_drag_by_mach) to preserve the public API.power_off_drag_inputpower_on_drag_inputrocketpy/rocket/rocket.pyrocketpy/rocket/point_mass_rocket.pyCHANGELOG.mdfor this PR.Breaking change
Additional information
This stacked PR targets
rel/v1.12.0and includes the follow-up changelog update requested in review feedback.📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.