Fully working locally

This commit is contained in:
Cian Hughes
2023-10-24 15:31:36 +01:00
parent 4cf0e4267c
commit 2a8d3c21fe
10 changed files with 620 additions and 228 deletions

17
debug.py Normal file
View File

@@ -0,0 +1,17 @@
import typer # type: ignore
import inspect
def debug_mode(debug: bool = False):
if not debug:
return
try:
import snoop # type: ignore
except ImportError:
typer.echo("Debug mode requires the snoop package")
raise typer.Exit(1)
else:
snoop.install(
snoop="ss",
)
typer.echo(f"Debug mode enabled: {inspect.stack()[1].filename}")