Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
2575950
ENH: Pass Acceleration Data to Parachute Trigger Functions (RocketPy-…
ViniciusCMB Dec 4, 2025
7ec7ac9
ENH: Add acceleration-based parachute triggers with IMU sensor simula…
ViniciusCMB Dec 7, 2025
18aab57
ENH: Enable sensors+acceleration triggers in parachutes
ViniciusCMB Dec 8, 2025
0932277
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
ViniciusCMB Dec 8, 2025
916b0fc
STY: Apply ruff format to flight.py
ViniciusCMB Dec 8, 2025
8e88fa8
STY: Fix pylint for parachute triggers
ViniciusCMB Dec 9, 2025
e84df40
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
ViniciusCMB Dec 9, 2025
a7f5c3a
TST: Add comprehensive unit tests for acceleration-based parachute tr…
ViniciusCMB Dec 9, 2025
ad7e6d0
DOC: Add comprehensive documentation for acceleration-based parachute…
ViniciusCMB Dec 9, 2025
8f65022
STY: Apply ruff format to test_parachute_trigger_acceleration.py
ViniciusCMB Dec 9, 2025
d45b3a5
STY: Fix pylint warnings in test_parachute_triggers.py
ViniciusCMB Dec 9, 2025
6d79d62
FIX: Add missing u_dot parameter to direct triggerfunc calls
ViniciusCMB Dec 9, 2025
5619b3a
STY: Apply ruff format to flight.py
ViniciusCMB Dec 9, 2025
c66cffc
MNT: align acceleration trigger API with review feedback
ViniciusCMB Mar 22, 2026
56c1e51
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
ViniciusCMB Mar 22, 2026
02d344d
STY: apply ruff format fixes
ViniciusCMB Mar 22, 2026
00e94b9
STY: apply ruff format fixes to flight.py
ViniciusCMB Mar 22, 2026
a0cb73d
STY: Apply ruff check after pip update
ViniciusCMB Mar 25, 2026
aba648b
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
ViniciusCMB Mar 25, 2026
6beab3c
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
MateusStano Mar 27, 2026
aa89d50
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
MateusStano Mar 27, 2026
6a9795d
Merge branch 'develop' into enh/acceleration-data-to-trigger-parachutes
MateusStano Apr 4, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
STY: apply ruff format fixes
  • Loading branch information
ViniciusCMB committed Mar 22, 2026
commit 02d344d3c0b0635fde3fca50b127c285bfbeadcb
4 changes: 1 addition & 3 deletions rocketpy/rocket/parachute.py
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you really need try/except blocks here?

Original file line number Diff line number Diff line change
Expand Up @@ -300,9 +300,7 @@ def __init_noise(self, noise):
+ beta * np.random.normal(noise[0], noise[1])
)

def __evaluate_trigger_function(
self, trigger
): # pylint: disable=too-many-statements
def __evaluate_trigger_function(self, trigger): # pylint: disable=too-many-statements
"""This is used to set the triggerfunc attribute that will be used to
interact with the Flight class.

Expand Down
15 changes: 7 additions & 8 deletions rocketpy/simulation/flight.py
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,8 @@ def __simulate(self, verbose):
lambda self, parachute_porosity=parachute.porosity: setattr(
self, "parachute_porosity", parachute_porosity
),
lambda self, added_mass_coefficient=parachute.added_mass_coefficient: (
lambda self,
added_mass_coefficient=parachute.added_mass_coefficient: (
setattr(
self,
"parachute_added_mass_coefficient",
Expand Down Expand Up @@ -1886,9 +1887,7 @@ def udot_rail2(self, t, u, post_processing=False): # pragma: no cover
# Hey! We will finish this function later, now we just can use u_dot
return self.u_dot_generalized(t, u, post_processing=post_processing)

def u_dot(
self, t, u, post_processing=False
): # pylint: disable=too-many-locals,too-many-statements
def u_dot(self, t, u, post_processing=False): # pylint: disable=too-many-locals,too-many-statements
"""Calculates derivative of u state vector with respect to time
when rocket is flying in 6 DOF motion during ascent out of rail
and descent without parachute.
Expand Down Expand Up @@ -2454,9 +2453,7 @@ def u_dot_generalized_3dof(self, t, u, post_processing=False):

return u_dot

def u_dot_generalized(
self, t, u, post_processing=False
): # pylint: disable=too-many-locals,too-many-statements
def u_dot_generalized(self, t, u, post_processing=False): # pylint: disable=too-many-locals,too-many-statements
"""Calculates derivative of u state vector with respect to time when the
rocket is flying in 6 DOF motion in space and significant mass variation
effects exist. Typical flight phases include powered ascent after launch
Expand Down Expand Up @@ -4441,7 +4438,9 @@ def add(self, flight_phase, index=None): # TODO: quite complex method
new_index = (
index - 1
if flight_phase.t < previous_phase.t
else index + 1 if flight_phase.t > next_phase.t else index
else index + 1
if flight_phase.t > next_phase.t
else index
)
flight_phase.t += adjust
self.add(flight_phase, new_index)
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/simulation/test_monte_carlo_plots_background.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,8 +386,8 @@ def mock_import_optional_dependency(name):

error_message = str(exc_info.value)
for expected_msg in expected_messages:
assert (
expected_msg in error_message
), f"Expected message '{expected_msg}' not found in error: {error_message}"
assert expected_msg in error_message, (
f"Expected message '{expected_msg}' not found in error: {error_message}"
)

assert "Esri.WorldImagery" in error_message
Loading