Skip to content
Snippets Groups Projects
Commit 51efed8c authored by Charlotte Hausman's avatar Charlotte Hausman
Browse files

Merge branch 'fix_carta_launching' into 'main'

make sure CARTA opens only after setup finishes

See merge request !1344
parents ea25ff88 11f39e84
No related branches found
No related tags found
2 merge requests!1390Catch up with Main,!1344make sure CARTA opens only after setup finishes
Pipeline #9831 passed
Pipeline: workspaces

#9833

    ......@@ -22,6 +22,7 @@ import os
    import signal
    import subprocess
    import sys
    import time
    from http.server import HTTPServer, SimpleHTTPRequestHandler
    from pathlib import Path
    from threading import Thread
    ......@@ -185,6 +186,15 @@ class CartaLauncher:
    f"{file_browser_path!s}",
    ]
    try:
    # finish setup for CARTA and ensure completion before launch
    CartaWrapperLauncher.deploy_wrapper_html(file_browser_path, carta_url, session_timeout_date)
    # BIG NASTY COMMENT OF DOOM!!!!!
    # DO NOT REMOVE!!
    # This is required to ensure that proxy url setup is complete *before* CARTA launches.
    # Without this, users are presented with a 404 page on launch as of CARTA3
    time.sleep(2)
    # start CARTA
    CARTA_PROCESS = subprocess.Popen(
    carta_command,
    preexec_fn=os.setpgrp(),
    ......@@ -196,8 +206,6 @@ class CartaLauncher:
    self.teardown()
    sys.exit(f"ERROR: Failed to launch CARTA: {err}")
    else:
    CartaWrapperLauncher.deploy_wrapper_html(file_browser_path, carta_url, session_timeout_date)
    # CARTA is running and accessible, so send CARTA URL to AAT system or notify user
    self.notify_ready(wrapper_url)
    ......
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Finish editing this message first!
    Please register or to comment