From f6f859c9c5b1d3d5b6e7aac2b6c2f5fd341cbbb5 Mon Sep 17 00:00:00 2001 From: Kenneth-T-Moore Date: Tue, 7 Jan 2025 16:33:59 -0500 Subject: [PATCH] Workaround for problem with the reports subsystem's interaction with env vars when run in a nested subprocess call. --- aviary/interface/methods_for_level1.py | 3 +-- aviary/interface/test/test_cmd_entry_points.py | 6 ------ 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/aviary/interface/methods_for_level1.py b/aviary/interface/methods_for_level1.py index 3482953fd..ce3393f99 100644 --- a/aviary/interface/methods_for_level1.py +++ b/aviary/interface/methods_for_level1.py @@ -144,7 +144,7 @@ def run_level_1( prob = run_aviary(input_deck, phase_info, **kwargs) # update n2 diagram after run. - outdir = Path(prob.get_reports_dir()) + outdir = Path(prob.get_reports_dir(force=True)) outfile = os.path.join(outdir, "n2.html") om.n2( prob, @@ -156,7 +156,6 @@ def run_level_1( def _setup_level1_parser(parser): - def_outdir = os.path.join(os.getcwd(), "output") parser.add_argument( 'input_deck', metavar='indeck', diff --git a/aviary/interface/test/test_cmd_entry_points.py b/aviary/interface/test/test_cmd_entry_points.py index c255fe9a2..abcee83db 100644 --- a/aviary/interface/test/test_cmd_entry_points.py +++ b/aviary/interface/test/test_cmd_entry_points.py @@ -35,12 +35,6 @@ def bench_test_IPOPT_cmd(self): cmd = 'aviary run_mission models/test_aircraft/aircraft_for_bench_GwGm.csv --optimizer IPOPT --max_iter 1' self.run_and_test_cmd(cmd) - @require_pyoptsparse(optimizer="IPOPT") - def bench_test_IPOPT_cmd(self): - cmd = 'aviary run_mission models/test_aircraft/aircraft_for_bench_GwGm.csv' \ - ' --optimizer IPOPT --max_iter 1 --shooting' - self.run_and_test_cmd(cmd) - @require_pyoptsparse(optimizer="IPOPT") def bench_test_phase_info_cmd(self): cmd = 'aviary run_mission models/test_aircraft/aircraft_for_bench_GwGm.csv --optimizer IPOPT --max_iter 1' \