From 7ba5a7d2ef1576b311e8b6452c2bda026ce86c48 Mon Sep 17 00:00:00 2001 From: Lucas de Oliveira Prates Date: Fri, 18 Apr 2025 17:18:51 +0200 Subject: [PATCH 1/2] BUG: fix parachute bug by setting time_overshoot to base flight when it is None --- rocketpy/stochastic/stochastic_flight.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rocketpy/stochastic/stochastic_flight.py b/rocketpy/stochastic/stochastic_flight.py index 729313736..0fde38c3a 100644 --- a/rocketpy/stochastic/stochastic_flight.py +++ b/rocketpy/stochastic/stochastic_flight.py @@ -87,7 +87,10 @@ def __init__( self.initial_solution = initial_solution self.terminate_on_apogee = terminate_on_apogee - self.time_overshoot = time_overshoot + if time_overshoot is None: + self.time_overshoot = flight.time_overshoot + else: + self.time_overshoot = time_overshoot def _validate_initial_solution(self, initial_solution): if initial_solution is not None: From 9a52185de9410c830e7c8e0fd2360aa7ced049c2 Mon Sep 17 00:00:00 2001 From: Lucas de Oliveira Prates Date: Sat, 19 Apr 2025 08:59:08 +0200 Subject: [PATCH 2/2] MNT: update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a4b7a9fd2..7a402afdb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -32,6 +32,7 @@ Attention: The newest changes should be on top --> ### Added +- BUG: Fix StochasticFlight time_overshoot None bug [#805] (https://github.com/RocketPy-Team/RocketPy/pull/805) - ENH: Implement Multivariate Rejection Sampling (MRS) [#738] (https://github.com/RocketPy-Team/RocketPy/pull/738) - ENH: Create a rocketpy file to store flight simulations [#800](https://github.com/RocketPy-Team/RocketPy/pull/800) - ENH: Support for the RSE file format has been added to the library [#798](https://github.com/RocketPy-Team/RocketPy/pull/798)