From 184189f0a535996edca01a68182ed07d32e26e9c Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sun, 27 Jan 2019 11:49:17 +0100 Subject: Support manhole debugging Add optional support for manhole to all cli tools. Activated by signal USR1. --- crocoite/cli.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'crocoite/cli.py') diff --git a/crocoite/cli.py b/crocoite/cli.py index be3538a..4ab2334 100644 --- a/crocoite/cli.py +++ b/crocoite/cli.py @@ -25,6 +25,11 @@ Command line interface import argparse, sys, signal, asyncio, os from enum import IntEnum from yarl import URL +try: + import manhole + manhole.install (patch_fork=False, oneshot_on='USR1') +except ModuleNotFoundError: + pass from . import behavior from .controller import SinglePageController, \ -- cgit v1.2.3