diff --git a/crawler/management/commands/crawl.py b/crawler/management/commands/crawl.py index b473ba4..78705fb 100644 --- a/crawler/management/commands/crawl.py +++ b/crawler/management/commands/crawl.py @@ -79,4 +79,6 @@ def command(start_url, db_filename, max_pages, depth, recreate, resume): # https://docs.djangoproject.com/en/3.2/topics/async/#async-safety os.environ["DJANGO_ALLOW_ASYNC_UNSAFE"] = "true" - return app.run_sync() + exit_status = app.run_sync() + click.echo(f"done, exiting with status {exit_status}") + return exit_status