From 7e7064385270dda09dc2aa396d290369a667a03f Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Sat, 10 Oct 2020 16:39:38 -0700 Subject: [PATCH] Removed --debug option, which didn't do anything - closes #814 --- README.md | 1 - datasette/cli.py | 6 +----- docs/changelog.rst | 1 - docs/datasette-serve-help.txt | 1 - tests/test_cli.py | 1 - 5 files changed, 1 insertion(+), 9 deletions(-) diff --git a/README.md b/README.md index 66ddf803..8670936c 100644 --- a/README.md +++ b/README.md @@ -130,7 +130,6 @@ Now visiting http://localhost:8001/History/downloads will show you a web interfa allowed. Use 0.0.0.0 to listen to all IPs and allow access from other machines. -p, --port INTEGER Port for server, defaults to 8001 - --debug Enable debug mode - useful for development --reload Automatically reload if database or code change detected - useful for development --cors Enable CORS by serving Access-Control-Allow- diff --git a/datasette/cli.py b/datasette/cli.py index 43e03f0a..55576013 100644 --- a/datasette/cli.py +++ b/datasette/cli.py @@ -286,9 +286,6 @@ def uninstall(packages, yes): default=8001, help="Port for server, defaults to 8001. Use -p 0 to automatically assign an available port.", ) -@click.option( - "--debug", is_flag=True, help="Enable debug mode - useful for development" -) @click.option( "--reload", is_flag=True, @@ -366,7 +363,6 @@ def serve( immutable, host, port, - debug, reload, cors, sqlite_extensions, @@ -417,7 +413,7 @@ def serve( kwargs = dict( immutables=immutable, - cache_headers=not debug and not reload, + cache_headers=not reload, cors=cors, inspect_data=inspect_data, metadata=metadata_data, diff --git a/docs/changelog.rst b/docs/changelog.rst index 1d654485..3c56328c 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -11,7 +11,6 @@ Changelog - Fixed another bug introduced in 0.50 where column header links on the table page were broken. (`#1011 `__) - .. _v0_50_1: 0.50.1 (2020-10-09) diff --git a/docs/datasette-serve-help.txt b/docs/datasette-serve-help.txt index ac3ca49f..0457a321 100644 --- a/docs/datasette-serve-help.txt +++ b/docs/datasette-serve-help.txt @@ -14,7 +14,6 @@ Options: -p, --port INTEGER Port for server, defaults to 8001. Use -p 0 to automatically assign an available port. - --debug Enable debug mode - useful for development --reload Automatically reload if database or code change detected - useful for development diff --git a/tests/test_cli.py b/tests/test_cli.py index 09864602..0e1745c2 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -89,7 +89,6 @@ def test_metadata_yaml(): immutable=[], host="127.0.0.1", port=8001, - debug=False, reload=False, cors=False, sqlite_extensions=[],