Skip to content

Commit

Permalink
issue openwallet-foundation#3182: introduce DAP_HOST and DAP_PORT
Browse files Browse the repository at this point in the history
Signed-off-by: Ricky Ng-Adam <[email protected]>
  • Loading branch information
rngadam committed Aug 28, 2024
1 parent af5938c commit 8eafaea
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions aries_cloudagent/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ def init_debug(args):

# --debug to use microsoft's visual studio remote debugger
if ENABLE_PTVSD or "--debug" in args:
PTVSD_HOST = os.getenv("PTVSD_HOST", "localhost")
PTVSD_PORT = os.getenv("PTVSD_PORT", 5678)
DAP_HOST = os.getenv("PTVSD_HOST", None) or os.getenv("DAP_HOST", "localhost")
DAP_PORT = os.getenv("PTVSD_PORT", None) or os.getenv("DAP_PORT", 5678)
try:
import debugpy

debugpy.listen((PTVSD_HOST, PTVSD_PORT))
print(f"=== Waiting for debugger to attach to {PTVSD_HOST}:{PTVSD_PORT} ===")
debugpy.listen((DAP_HOST, DAP_PORT))
print(f"=== Waiting for debugger to attach to {DAP_HOST}:{DAP_PORT} ===")
debugpy.wait_for_client()
except ImportError:
print("debugpy library was not found")
Expand Down

0 comments on commit 8eafaea

Please sign in to comment.