Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 3 additions & 1 deletion loopx/cli_commands/support_control_upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,9 @@ def _restart_app(
capture_output=True,
timeout=min(timeout_seconds, 30),
)
launch = ["/usr/bin/open", "-a", str(app)]
# A running QA/copy can share the bundle id. LaunchServices must start
# this installation after quit, rather than activate that other process.
launch = ["/usr/bin/open", "-n", "-a", str(app)]
if os.environ.get("LOOPX_BIN"):
launch += ["--env", f"LOOPX_BIN={os.environ['LOOPX_BIN']}"]
subprocess.run(
Expand Down
1 change: 1 addition & 0 deletions tests/test_self_upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ def test_app_restart_keeps_an_explicit_terminal_runtime_pin(monkeypatch):
_restart_app(Path("/synthetic/LoopX.app"), "a" * 32, "main", 60)
quit_command = run.call_args_list[0].args[0]
launch_command = run.call_args_list[1].args[0]
assert launch_command[:4] == ["/usr/bin/open", "-n", "-a", "/synthetic/LoopX.app"]
assert quit_command[-1] == "/synthetic/LoopX.app"
assert "/synthetic/LoopX.app" not in quit_command[2]
assert (
Expand Down
Loading