(impact)`, `\u00f8 = not affected`, `? = missing data`\n> Powered by [Codecov](https://codecov.io/gh/simonw/datasette/pull/1400?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison). Last update [c73af5d...e95c685](https://codecov.io/gh/simonw/datasette/pull/1400?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison).\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 947640902, "label": "Bump black from 21.6b0 to 21.7b0"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1401#issuecomment-884910320", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1401", "id": 884910320, "node_id": "IC_kwDOBm6k_c40vqjw", "user": {"value": 536941, "label": "fgregg"}, "created_at": "2021-07-22T13:26:01Z", "updated_at": "2021-07-22T13:26:01Z", "author_association": "CONTRIBUTOR", "body": "ordered lists didn't work either, btw", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 950664971, "label": "unordered list is not rendering bullet points in description_html on database page"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1445#issuecomment-904024939", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1445", "id": 904024939, "node_id": "IC_kwDOBm6k_c414lNr", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-23T18:52:35Z", "updated_at": "2021-08-23T18:52:35Z", "author_association": "OWNER", "body": "The downside of the current implementation of this trick is that it only works for exact LIKE partial matches in a specific table - if you search for `dog cat` and `dog` appears in `title` but `cat` appears in `description` you won't get back that result.\r\n\r\nI think that's fine though. If you want more advanced search there are other mechanisms you can use. This is meant to be a very quick and dirty starting point for exploring a brand new table.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 977323133, "label": "Ability to search for text across all columns in a table"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1445#issuecomment-904026253", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1445", "id": 904026253, "node_id": "IC_kwDOBm6k_c414liN", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-23T18:54:49Z", "updated_at": "2021-08-23T18:54:49Z", "author_association": "OWNER", "body": "The bigger problem here is UI design. This feels like a pretty niche requirement to me, so adding a prominent search box to the table page (which already has the filters interface, plus the full-text search box for tables that have FTS configured) feels untidy.\r\n\r\nI could tuck it away in the table cog menu, but that's a weird place for something like this to live.\r\n\r\nMaybe add it as a new type of filter? Filters apply to specific columns though, so this would be the first filter that applied to _all_ columns - which doesn't really fit the existing filter interface very well.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 977323133, "label": "Ability to search for text across all columns in a table"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1445#issuecomment-904027166", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1445", "id": 904027166, "node_id": "IC_kwDOBm6k_c414lwe", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-23T18:56:20Z", "updated_at": "2021-08-23T18:56:20Z", "author_association": "OWNER", "body": "A related but potentially even more useful ability would be running a search across every column of every table in a whole database. For anything less than a few 100MB this could be incredibly useful.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 977323133, "label": "Ability to search for text across all columns in a table"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1445#issuecomment-904036200", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1445", "id": 904036200, "node_id": "IC_kwDOBm6k_c414n9o", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-23T19:08:54Z", "updated_at": "2021-08-23T19:08:54Z", "author_association": "OWNER", "body": "Figured out a query for searching across every column in every table! https://til.simonwillison.net/datasette/search-all-columns-trick#user-content-same-trick-for-the-entire-database\r\n\r\n```sql\r\nwith tables as (\r\n select\r\n name as table_name\r\n from\r\n sqlite_master\r\n where\r\n type = 'table'\r\n),\r\nqueries as (\r\n select\r\n 'select ''' || tables.table_name || ''' as _table, rowid from \"' || tables.table_name || '\" where ' || group_concat(\r\n '\"' || name || '\" like ''%'' || :search || ''%''',\r\n ' or '\r\n ) as query\r\n from\r\n pragma_table_info(tables.table_name),\r\n tables\r\n group by\r\n tables.table_name\r\n)\r\nselect\r\n group_concat(query, ' union all ')\r\nfrom\r\n queries\r\n```\r\nThe SQL query this generates for larger databases is _extremely_ long - but it does seem to work for smaller databases.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 977323133, "label": "Ability to search for text across all columns in a table"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1445#issuecomment-904037087", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1445", "id": 904037087, "node_id": "IC_kwDOBm6k_c414oLf", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-23T19:10:17Z", "updated_at": "2021-08-23T19:10:17Z", "author_association": "OWNER", "body": "Rather than trying to run that monstrosity in a single `union all` query, a better approach may be to use `fetch()` requests as seen in https://datasette.io/plugins/datasette-search-all", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 977323133, "label": "Ability to search for text across all columns in a table"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1446#issuecomment-904866495", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1446", "id": 904866495, "node_id": "IC_kwDOBm6k_c417yq_", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-24T18:13:49Z", "updated_at": "2021-08-24T18:13:49Z", "author_association": "OWNER", "body": "OK, now the following optional CSS gives us a sticky footer:\r\n```css\r\nhtml, body {\r\n height: 100%;\r\n}\r\nbody {\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n.not-footer {\r\n flex: 1 0 auto;\r\n}\r\nfooter {\r\n flex-shrink: 0;\r\n}\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 978357984, "label": "Modify base.html template to support optional sticky footer"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1446#issuecomment-904954530", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1446", "id": 904954530, "node_id": "IC_kwDOBm6k_c418IKi", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-24T20:32:47Z", "updated_at": "2021-08-24T20:32:47Z", "author_association": "OWNER", "body": "Pasting that CSS into the styles editor in the developer tools on https://latest.datasette.io/ has the desired effect: footer at the bottom of the window unless the page is too long, in which case the footer is at the bottom of the scroll.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 978357984, "label": "Modify base.html template to support optional sticky footer"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/859#issuecomment-904982056", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/859", "id": 904982056, "node_id": "IC_kwDOBm6k_c418O4o", "user": {"value": 2670795, "label": "brandonrobertz"}, "created_at": "2021-08-24T21:15:04Z", "updated_at": "2021-08-24T21:15:30Z", "author_association": "CONTRIBUTOR", "body": "I'm running into issues with this as well. All other pages seem to work with lots of DBs except the home page, which absolutely tanks. Would be willing to put some work into this, if there's been any kind of progress on concepts on how this ought to work.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 642572841, "label": "Database page loads too slowly with many large tables (due to table counts)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/pull/1447#issuecomment-905097468", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1447", "id": 905097468, "node_id": "IC_kwDOBm6k_c418rD8", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-25T01:28:53Z", "updated_at": "2021-08-25T01:28:53Z", "author_association": "OWNER", "body": "Good catch, thanks!", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 978614898, "label": "Remove underscore from search mode parameter name"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1405#issuecomment-889525741", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1405", "id": 889525741, "node_id": "IC_kwDOBm6k_c41BRXt", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-29T23:33:30Z", "updated_at": "2021-07-29T23:33:30Z", "author_association": "OWNER", "body": "New documentation section for `datasette.utils` is here: https://docs.datasette.io/en/latest/internals.html#the-datasette-utils-module", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 955316250, "label": "utils.parse_metadata() should be a documented internal function"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1241#issuecomment-889539227", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1241", "id": 889539227, "node_id": "IC_kwDOBm6k_c41BUqb", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T00:15:26Z", "updated_at": "2021-07-30T00:15:26Z", "author_association": "OWNER", "body": "One possible treatment:\r\n\r\n\r\n\r\n```html\r\n\r\n\r\n {% if query.sql and allow_execute_sql %}\r\n \r\n View and edit SQL\r\n \r\n {% endif %}\r\n Copy and share link\r\n
\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 814595021, "label": "Share button for copying current URL"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-889548536", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 889548536, "node_id": "IC_kwDOBm6k_c41BW74", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T00:43:47Z", "updated_at": "2021-07-30T00:43:47Z", "author_association": "OWNER", "body": "Still couldn't replicate on my laptop. On a hunch, I'm going to add `@pytest.mark.serial` to every test that uses `runner.isolated_filesystem()`.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-889547142", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 889547142, "node_id": "IC_kwDOBm6k_c41BWmG", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T00:39:49Z", "updated_at": "2021-07-30T00:39:49Z", "author_association": "OWNER", "body": "It happens in CI but not on my laptop. I think I need to run the tests on my laptop like this: https://github.com/simonw/datasette/blob/121e10c29c5b412fddf0326939f1fe46c3ad9d4a/.github/workflows/test.yml#L27-L30", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-889550391", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 889550391, "node_id": "IC_kwDOBm6k_c41BXY3", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T00:49:31Z", "updated_at": "2021-07-30T00:49:31Z", "author_association": "OWNER", "body": "That fixed it. My hunch is that Click's `runner.isolated_filesystem()` mechanism doesn't play well with `pytest-xdist`.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-889553052", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 889553052, "node_id": "IC_kwDOBm6k_c41BYCc", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T00:58:43Z", "updated_at": "2021-07-30T00:58:43Z", "author_association": "OWNER", "body": "Tests are still failing in the job that calculates coverage.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-889555977", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 889555977, "node_id": "IC_kwDOBm6k_c41BYwJ", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-30T01:06:57Z", "updated_at": "2021-07-30T01:06:57Z", "author_association": "OWNER", "body": "Looking at the source code in Click for `isolated_filesystem()`: https://github.com/pallets/click/blob/9da166957f5848b641231d485467f6140bca2bc0/src/click/testing.py#L450-L468\r\n\r\n```python\r\n @contextlib.contextmanager\r\n def isolated_filesystem(\r\n self, temp_dir: t.Optional[t.Union[str, os.PathLike]] = None\r\n ) -> t.Iterator[str]:\r\n \"\"\"A context manager that creates a temporary directory and\r\n changes the current working directory to it. This isolates tests\r\n that affect the contents of the CWD to prevent them from\r\n interfering with each other.\r\n :param temp_dir: Create the temporary directory under this\r\n directory. If given, the created directory is not removed\r\n when exiting.\r\n .. versionchanged:: 8.0\r\n Added the ``temp_dir`` parameter.\r\n \"\"\"\r\n cwd = os.getcwd()\r\n t = tempfile.mkdtemp(dir=temp_dir)\r\n os.chdir(t)\r\n```\r\nHow about if I pass in that optional `temp_dir` as a temp directory created using the `pytest-xdist` aware pytest mechanisms: https://docs.pytest.org/en/6.2.x/tmpdir.html", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1398#issuecomment-889599513", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1398", "id": 889599513, "node_id": "IC_kwDOBm6k_c41BjYZ", "user": {"value": 192984, "label": "aitoehigie"}, "created_at": "2021-07-30T03:21:49Z", "updated_at": "2021-07-30T03:21:49Z", "author_association": "NONE", "body": "Does the library support this now?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 947044667, "label": "Documentation on using Datasette as a library"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-890259755", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 890259755, "node_id": "IC_kwDOBm6k_c41EEkr", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T00:04:54Z", "updated_at": "2021-07-31T00:04:54Z", "author_association": "OWNER", "body": "STILL failing. I'm going to try removing all instances of `isolated_filesystem()` in favour of a different pattern using pytest temporary files, then see if I can get that to work without the serial hack. ", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1407#issuecomment-890388200", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1407", "id": 890388200, "node_id": "IC_kwDOBm6k_c41Ej7o", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T18:38:41Z", "updated_at": "2021-07-31T18:38:41Z", "author_association": "OWNER", "body": "The `path` variable there looked like this:\r\n\r\n`/private/var/folders/wr/hn3206rs1yzgq3r49bz8nvnh0000gn/T/pytest-of-simon/pytest-696/popen-gw0/uds0/datasette.sock`\r\n\r\nI think what's happening here is that `pytest-xdist` causes `tmp_path_factory.mktemp(\"uds\")` to create significantly longer paths, which in this case is breaking some limit.\r\n\r\nSo for this code to work with `pytest-xdist` I need to make sure the random path to `datasette.sock` is shorter.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957298475, "label": "OSError: AF_UNIX path too long in ds_unix_domain_socket_server"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1407#issuecomment-890388656", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1407", "id": 890388656, "node_id": "IC_kwDOBm6k_c41EkCw", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T18:42:41Z", "updated_at": "2021-07-31T18:42:41Z", "author_association": "OWNER", "body": "I'll try `tempfile.gettempdir()` - on macOS it returns something like `'/var/folders/wr/hn3206rs1yzgq3r49bz8nvnh0000gn/T'` which is still long but hopefully not too long.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957298475, "label": "OSError: AF_UNIX path too long in ds_unix_domain_socket_server"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-890390198", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 890390198, "node_id": "IC_kwDOBm6k_c41Eka2", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T18:55:33Z", "updated_at": "2021-07-31T18:55:33Z", "author_association": "OWNER", "body": "To clarify: the core problem here is that an error is thrown any time you call `os.getcwd()` but the directory you are currently in has been deleted.\r\n\r\n`runner.isolated_filesystem()` assumes that the current directory in has not been deleted. But the various temporary directory utilities in `pytest` work by creating directories and then deleting them.\r\n\r\nMaybe there's a larger problem here that I play a bit fast and loose with `os.chdir()` in both the test suite and in various lines of code in Datasette itself (in particular in the publish commands)?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1406#issuecomment-890390342", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1406", "id": 890390342, "node_id": "IC_kwDOBm6k_c41EkdG", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T18:56:35Z", "updated_at": "2021-07-31T18:56:35Z", "author_association": "OWNER", "body": "But... I've lost enough time to this already, and removing `runner.isolated_filesystem()` has the tests passing again. So I'm not going to work on this any more.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 956303470, "label": "Tests failing with FileNotFoundError in runner.isolated_filesystem"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1408#issuecomment-890390495", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1408", "id": 890390495, "node_id": "IC_kwDOBm6k_c41Ekff", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T18:57:39Z", "updated_at": "2021-07-31T18:57:39Z", "author_association": "OWNER", "body": "Opening this issue as an optional follow-up to the work I did in #1406.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957302085, "label": "Review places in codebase that use os.chdir(), in particularly relating to tests"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1408#issuecomment-890390845", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1408", "id": 890390845, "node_id": "IC_kwDOBm6k_c41Ekk9", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:00:32Z", "updated_at": "2021-07-31T19:00:32Z", "author_association": "OWNER", "body": "When I revisit this I can also look at dropping the `@pytest.mark.serial` hack, and maybe the `restore_working_directory()` fixture hack too:\r\n\r\nhttps://github.com/simonw/datasette/blob/ff253f5242e4b0b5d85d29d38b8461feb5ea997a/pytest.ini#L9-L10\r\n\r\nhttps://github.com/simonw/datasette/blob/ff253f5242e4b0b5d85d29d38b8461feb5ea997a/tests/conftest.py#L62-L75", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957302085, "label": "Review places in codebase that use os.chdir(), in particularly relating to tests"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890400059", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890400059, "node_id": "IC_kwDOBm6k_c41Em07", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T20:21:51Z", "updated_at": "2021-07-31T20:21:51Z", "author_association": "OWNER", "body": "One of these two options:\r\n\r\n- `--setting default_allow_sql off`\r\n- `--setting allow_sql_default off`\r\n\r\nExisting settings from https://docs.datasette.io/en/0.58.1/settings.html with similar names that I need to be consistent with:\r\n\r\n- `default_page_size`\r\n- `allow_facet`\r\n- `default_facet_size`\r\n- `allow_download`\r\n- `default_cache_ttl`\r\n- `default_cache_ttl_hashed`\r\n- `allow_csv_stream`\r\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890400121", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890400121, "node_id": "IC_kwDOBm6k_c41Em15", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T20:22:21Z", "updated_at": "2021-07-31T20:23:34Z", "author_association": "OWNER", "body": "I think `default_allow_sql` is more consistent with the current naming conventions, because both `allow` and `default` are used as prefixes at the moment but neither of them are ever used as a suffix.\r\n\r\nPlus `default_allow_sql off` makes sense to me but `allow_default_sql off` does not - what is \"default SQL\"?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890400425", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890400425, "node_id": "IC_kwDOBm6k_c41Em6p", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T20:25:16Z", "updated_at": "2021-07-31T20:26:25Z", "author_association": "OWNER", "body": "If I was prone to over-thinking (which I am) I'd note that `allow_facet` and `allow_download` and `allow_csv_stream` are all settings that do NOT have an equivalent in the newer permissions system, which is itself a little weird and inconsistent.\r\n\r\nSo maybe there's a future task where I introduce those as both permissions and metadata `\"allow_x\"` blocks, then rename the settings themselves to be called `default_allow_facet` and `default_allow_download` and `default_allow_csv_stream`.\r\n\r\nIf I was going to do that I should get it in before Datasette 1.0.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890397124", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890397124, "node_id": "IC_kwDOBm6k_c41EmHE", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:51:10Z", "updated_at": "2021-07-31T19:51:10Z", "author_association": "OWNER", "body": "I think I may like `disable_sql` better. Some options:\r\n\r\n- `--setting allow_sql off` (consistent with `allow_facet` and `allow_download` and `allow_csv_stream` - all which default to `on` already)\r\n- `--setting disable_sql on`\r\n- `--setting disable_custom_sql on`\r\n\r\nThe existence of three `allow_*` settings does make a strong argument for staying consistent with that.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890397169", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890397169, "node_id": "IC_kwDOBm6k_c41EmHx", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:51:35Z", "updated_at": "2021-07-31T19:51:35Z", "author_association": "OWNER", "body": "I'm going to stick with `--setting allow_sql off`.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890397261", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890397261, "node_id": "IC_kwDOBm6k_c41EmJN", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:52:25Z", "updated_at": "2021-07-31T19:52:25Z", "author_association": "OWNER", "body": "I think I can make this modification by teaching the default permissions code here to take the `allow_sql` setting into account: https://github.com/simonw/datasette/blob/ff253f5242e4b0b5d85d29d38b8461feb5ea997a/datasette/default_permissions.py#L38-L45", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890397652", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890397652, "node_id": "IC_kwDOBm6k_c41EmPU", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:56:48Z", "updated_at": "2021-07-31T19:56:48Z", "author_association": "OWNER", "body": "The other option would be to use the setting to pick the `default=` argument when calling `self.ds.permission_allowed( request.actor, \"execute-sql\", resource=database, default=True)`.\r\n\r\nThe problem with that is that there are actually a few different places which perform that check, so changing all of them raises the risk of missing one in the future:\r\n\r\nhttps://github.com/simonw/datasette/blob/a6c8e7fa4cffdeff84e9e755dcff4788fd6154b8/datasette/views/table.py#L436-L444\r\n\r\nhttps://github.com/simonw/datasette/blob/a6c8e7fa4cffdeff84e9e755dcff4788fd6154b8/datasette/views/table.py#L964-L966\r\n\r\nhttps://github.com/simonw/datasette/blob/d23a2671386187f61872b9f6b58e0f80ac61f8fe/datasette/views/database.py#L220-L221\r\n\r\nhttps://github.com/simonw/datasette/blob/d23a2671386187f61872b9f6b58e0f80ac61f8fe/datasette/views/database.py#L343-L345\r\n\r\nhttps://github.com/simonw/datasette/blob/d23a2671386187f61872b9f6b58e0f80ac61f8fe/datasette/views/database.py#L134-L136\r\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890397753", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890397753, "node_id": "IC_kwDOBm6k_c41EmQ5", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T19:57:56Z", "updated_at": "2021-07-31T19:57:56Z", "author_association": "OWNER", "body": "I think the correct solution is for the default permissions logic to take the `allow_sql` setting into account, and to return `False` if that setting is set to `off` AND the current actor fails the `actor_matches_allow` checks.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1409#issuecomment-890399806", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1409", "id": 890399806, "node_id": "IC_kwDOBm6k_c41Emw-", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-07-31T20:18:46Z", "updated_at": "2021-07-31T20:18:46Z", "author_association": "OWNER", "body": "My rationale for removing it: https://github.com/simonw/datasette/issues/813#issuecomment-640916290\r\n\r\n> Naming problem: Datasette already has a config option with this name:\r\n>\r\n> $ datasette serve data.db --config allow_sql:1\r\n>\r\n> https://datasette.readthedocs.io/en/stable/config.html#allow-sql\r\n>\r\n> It's confusing to have two things called `allow_sql` that do slightly different things.\r\n>\r\n> I could retire the `--config allow_sql:0` option entirely, since the new `metadata.json` mechanism can be used to achieve the exact same thing.\r\n> \r\n> I'm going to do that.\r\n\r\nThis is true. The `\"allow_sql\"` permissions block in `metadata.json` does indeed have a name that is easily confused with `--setting allow_sql off`.\r\n\r\nSo I definitely need to pick a different name from the setting. `--setting default_allow_sql off` is a good option here.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957310278, "label": "`default_allow_sql` setting (a re-imagining of the old `allow_sql` setting)"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1411#issuecomment-890441844", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1411", "id": 890441844, "node_id": "IC_kwDOBm6k_c41ExB0", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-01T03:27:30Z", "updated_at": "2021-08-01T03:27:30Z", "author_association": "OWNER", "body": "Confirmed: https://latest.datasette.io/fixtures/neighborhood_search?text=cork&_hide_sql=1 no longer exhibits the bug.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 957345476, "label": "Canned query ?sql= is pointlessly echoed in query string starting from hidden mode"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1227#issuecomment-891352132", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1227", "id": 891352132, "node_id": "IC_kwDOBm6k_c41IPRE", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-02T21:38:39Z", "updated_at": "2021-08-02T21:38:39Z", "author_association": "OWNER", "body": "Relevant TIL: https://til.simonwillison.net/vscode/vs-code-regular-expressions", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 810394616, "label": "Configure sphinx.ext.extlinks for issues"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1417#issuecomment-891979858", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1417", "id": 891979858, "node_id": "IC_kwDOBm6k_c41KohS", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-03T16:15:30Z", "updated_at": "2021-08-03T16:15:30Z", "author_association": "OWNER", "body": "Docs: https://pypi.org/project/codespell/\r\n\r\nThere's a `codespell --ignore-words=FILE` option for ignoring words. I don't have any that need ignoring yet but I'm going to add that file anyway, that way I can have codespell be a failing test but still provide a way to work around it if it incorrectly flags a correct word.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959278472, "label": "Use codespell in CI to spot spelling errors"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/pull/1418#issuecomment-891984359", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1418", "id": 891984359, "node_id": "IC_kwDOBm6k_c41Kpnn", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-03T16:21:56Z", "updated_at": "2021-08-03T16:21:56Z", "author_association": "OWNER", "body": "Failed with:\r\n```\r\ndocs/authentication.rst:63: perfom ==> perform\r\ndocs/authentication.rst:76: perfom ==> perform\r\ndocs/changelog.rst:429: repsonse ==> response\r\ndocs/changelog.rst:503: permissons ==> permissions\r\ndocs/changelog.rst:717: compatibilty ==> compatibility\r\ndocs/changelog.rst:1172: browseable ==> browsable\r\ndocs/deploying.rst:191: similiar ==> similar\r\ndocs/internals.rst:434: Respons ==> Response, respond\r\ndocs/internals.rst:440: Respons ==> Response, respond\r\ndocs/internals.rst:717: tha ==> than, that, the\r\ndocs/performance.rst:42: databse ==> database\r\ndocs/plugin_hooks.rst:667: utilites ==> utilities\r\ndocs/publish.rst:168: countainer ==> container\r\ndocs/settings.rst:352: inalid ==> invalid\r\ndocs/sql_queries.rst:406: preceeded ==> preceded, proceeded\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959284434, "label": "Spelling corrections plus CI job for codespell"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/pull/1418#issuecomment-891987129", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1418", "id": 891987129, "node_id": "IC_kwDOBm6k_c41KqS5", "user": {"value": 22429695, "label": "codecov[bot]"}, "created_at": "2021-08-03T16:26:01Z", "updated_at": "2021-08-03T16:32:20Z", "author_association": "NONE", "body": "# [Codecov](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison) Report\n> Merging [#1418](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison) (532170f) into [main](https://codecov.io/gh/simonw/datasette/commit/54b6e96ee8aa553b6671e341a1944f93f3fb89c3?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison) (54b6e96) will **not change** coverage.\n> The diff coverage is `n/a`.\n\n[![Impacted file tree graph](https://codecov.io/gh/simonw/datasette/pull/1418/graphs/tree.svg?width=650&height=150&src=pr&token=eSahVY7kw1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison)](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison)\n\n```diff\n@@ Coverage Diff @@\n## main #1418 +/- ##\n=======================================\n Coverage 91.64% 91.64% \n=======================================\n Files 34 34 \n Lines 4382 4382 \n=======================================\n Hits 4016 4016 \n Misses 366 366 \n```\n\n\n\n------\n\n[Continue to review full report at Codecov](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison).\n> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison)\n> `\u0394 = absolute (impact)`, `\u00f8 = not affected`, `? = missing data`\n> Powered by [Codecov](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison). Last update [54b6e96...532170f](https://codecov.io/gh/simonw/datasette/pull/1418?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Simon+Willison).\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959284434, "label": "Spelling corrections plus CI job for codespell"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1419#issuecomment-892276385", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1419", "id": 892276385, "node_id": "IC_kwDOBm6k_c41Lw6h", "user": {"value": 536941, "label": "fgregg"}, "created_at": "2021-08-04T00:58:49Z", "updated_at": "2021-08-04T00:58:49Z", "author_association": "CONTRIBUTOR", "body": "yes, [filter clause on aggregate queries were added to sqlite3 in 3.30](https://www.sqlite.org/releaselog/3_30_1.html)", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959710008, "label": "`publish cloudrun` should deploy a more recent SQLite version"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1420#issuecomment-892365639", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1420", "id": 892365639, "node_id": "IC_kwDOBm6k_c41MGtH", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-04T05:05:07Z", "updated_at": "2021-08-04T05:05:07Z", "author_association": "OWNER", "body": "https://github.com/simonw/datasette/blob/cd8b7bee8fb5c1cdce7c8dbfeb0166011abc72c6/datasette/publish/cloudrun.py#L153-L158", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959898166, "label": "`datasette publish cloudrun --cpu X` option"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1420#issuecomment-892372509", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1420", "id": 892372509, "node_id": "IC_kwDOBm6k_c41MIYd", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-04T05:22:29Z", "updated_at": "2021-08-04T05:22:29Z", "author_association": "OWNER", "body": "Testing this manually with:\r\n\r\n datasette publish cloudrun fixtures.db --memory 8G --cpu 4 \\\r\n --service fixtures-over-provisioned-issue-1420 --install datasette-psutil\r\n\r\nAnd for comparison:\r\n\r\n datasette publish cloudrun fixtures.db --service fixtures-default-issue-1420 \\\r\n --install datasette-psutil\r\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959898166, "label": "`datasette publish cloudrun --cpu X` option"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1420#issuecomment-892374253", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1420", "id": 892374253, "node_id": "IC_kwDOBm6k_c41MIzt", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-04T05:27:21Z", "updated_at": "2021-08-04T05:29:59Z", "author_association": "OWNER", "body": "I'll delete these services shortly afterwards. Right now:\r\n\r\nhttps://fixtures-over-provisioned-issue-1420-j7hipcg4aq-uc.a.run.app/-/psutil (deployed with `--memory 8G --cpu 4`) returns:\r\n```\r\nprocess.memory_info()\r\n pmem(rss=60456960, vms=518930432, shared=0, text=0, lib=0, data=0, dirty=0)\r\n\r\n...\r\n\r\npsutil.cpu_times(True)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n\r\npsutil.virtual_memory()\r\n svmem(total=2147483648, available=2092531712, percent=2.6, used=33103872, free=2092531712, active=44130304, inactive=10792960, buffers=0, cached=21848064, shared=262144, slab=0)\r\n```\r\nhttps://fixtures-default-issue-1420-j7hipcg4aq-uc.a.run.app/-/psutil returns:\r\n```\r\nprocess.memory_info()\r\n pmem(rss=49324032, vms=140595200, shared=0, text=0, lib=0, data=0, dirty=0)\r\n\r\n...\r\n\r\npsutil.cpu_times(True)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0, iowait=0.0, irq=0.0, softirq=0.0, steal=0.0, guest=0.0, guest_nice=0.0)\r\n\r\npsutil.virtual_memory()\r\n svmem(total=2147483648, available=2091188224, percent=2.6, used=40071168, free=2091188224, active=41586688, inactive=7983104, buffers=0, cached=16224256, shared=262144, slab=0)\r\n```\r\nThese numbers are different enough that I assume this works as advertised. ", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959898166, "label": "`datasette publish cloudrun --cpu X` option"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1420#issuecomment-892376353", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1420", "id": 892376353, "node_id": "IC_kwDOBm6k_c41MJUh", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-04T05:33:12Z", "updated_at": "2021-08-04T05:33:12Z", "author_association": "OWNER", "body": "In the Cloud Run console (before I deleted these services) when I click \"Edit and deploy new revision\" I see this for the default one:\r\n\r\n\r\n\r\nAnd this for the big one:\r\n\r\n\r\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959898166, "label": "`datasette publish cloudrun --cpu X` option"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1420#issuecomment-893079520", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1420", "id": 893079520, "node_id": "IC_kwDOBm6k_c41O0_g", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-05T00:54:59Z", "updated_at": "2021-08-05T00:54:59Z", "author_association": "OWNER", "body": "Just saw this error:\r\n\r\n`ERROR: (gcloud.run.deploy) The `--cpu` flag is not supported on the fully managed version of Cloud Run. Specify `--platform gke` or run `gcloud config set run/platform gke` to work with Cloud Run for Anthos deployed on Google Cloud.`\r\n\r\nWhich is weird because I managed to run this successfully the other day. Maybe a region difference thing?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959898166, "label": "`datasette publish cloudrun --cpu X` option"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1419#issuecomment-893114612", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1419", "id": 893114612, "node_id": "IC_kwDOBm6k_c41O9j0", "user": {"value": 536941, "label": "fgregg"}, "created_at": "2021-08-05T02:29:06Z", "updated_at": "2021-08-05T02:29:06Z", "author_association": "CONTRIBUTOR", "body": "there's a lot of complexity here, that's probably not worth addressing. i got what i needed by patching the dockerfile that cloudrun uses to install a newer version of sqlite.\r\n\r\n", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959710008, "label": "`publish cloudrun` should deploy a more recent SQLite version"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1422#issuecomment-893122356", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1422", "id": 893122356, "node_id": "IC_kwDOBm6k_c41O_c0", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-05T02:52:31Z", "updated_at": "2021-08-05T02:52:44Z", "author_association": "OWNER", "body": "If you do this it should still be possible to view the SQL - which means we need a new parameter. I propose `?_show_sql=1` to over-ride the hidden default.\r\n\r\nI think the configuration should use `hide_sql: true` - looking like this:\r\n```yaml\r\ndatabases:\r\n fixtures:\r\n queries:\r\n neighborhood_search:\r\n hide_sql: true\r\n sql: |-\r\n select neighborhood, facet_cities.name, state\r\n from facetable\r\n join facet_cities on facetable.city_id = facet_cities.id\r\n where neighborhood like '%' || :text || '%'\r\n order by neighborhood\r\n title: Search neighborhoods\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 961367843, "label": "Ability to default to hiding the SQL for a canned query"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1422#issuecomment-893131703", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1422", "id": 893131703, "node_id": "IC_kwDOBm6k_c41PBu3", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-05T03:16:46Z", "updated_at": "2021-08-05T03:16:46Z", "author_association": "OWNER", "body": "The logic for this is a little bit fiddly, due to the need to switch to using `?_show_sql=1` on the link depending on the context.\r\n\r\n- If metadata says hide and there's no query string, hide and link to `?_show_sql=1`\r\n- If metadata says hide but query string says `?_show_sql=1`, show and have hide link linking to URL without `?_show_sql=1`\r\n- Otherwise, show and link to `?_hide_sql=1`\r\n- ... or if that query string is there then hide and link to URL without `?_hide_sql=1`", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 961367843, "label": "Ability to default to hiding the SQL for a canned query"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1419#issuecomment-893133496", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1419", "id": 893133496, "node_id": "IC_kwDOBm6k_c41PCK4", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-05T03:22:44Z", "updated_at": "2021-08-05T03:22:44Z", "author_association": "OWNER", "body": "I ran into this exact same problem today! I only just learned how to use filter on aggregates: https://til.simonwillison.net/sqlite/sqlite-aggregate-filter-clauses\r\n\r\nA workaround I used is to add this to the deploy command:\r\n\r\n datasette publish cloudrun ... --install=pysqlite3-binary\r\n\r\nThis will install the https://pypi.org/project/pysqlite3-binary for package which bundles a more recent SQLite version.", "reactions": "{\"total_count\": 2, \"+1\": 2, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 959710008, "label": "`publish cloudrun` should deploy a more recent SQLite version"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1423#issuecomment-893996604", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1423", "id": 893996604, "node_id": "IC_kwDOBm6k_c41SU48", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-06T04:43:07Z", "updated_at": "2021-08-06T04:43:37Z", "author_association": "OWNER", "body": "Problem: on a page which doesn't have quite enough facet values to trigger the display of the \"...\" link that links to `?_facet_size=max` the user would still have to manually count the values - up to 30 by default.\r\n\r\nSo maybe the count should always be shown, perhaps as a non-bold light colored number?\r\n\r\nI could even hide it in a non-discoverable tooltip.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 962391325, "label": "Show count of facet values if ?_facet_size=max"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1423#issuecomment-894452990", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1423", "id": 894452990, "node_id": "IC_kwDOBm6k_c41UET-", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-06T18:49:37Z", "updated_at": "2021-08-06T18:49:37Z", "author_association": "OWNER", "body": "Could display them always, like this:\r\n\r\n\r\n\r\nThat's with `23`", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 962391325, "label": "Show count of facet values if ?_facet_size=max"}, "performed_via_github_app": null}
{"html_url": "https://github.com/simonw/datasette/issues/1423#issuecomment-894453520", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1423", "id": 894453520, "node_id": "IC_kwDOBm6k_c41UEcQ", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-08-06T18:50:40Z", "updated_at": "2021-08-06T18:50:40Z", "author_association": "OWNER", "body": "Point of confusion: if only 30 options are shown, but there's a `...` at the end, what would the number be? It can't be the total number of facets because we haven't counted them all - but if it's just the number of displayed facets that's like to be confusing.\r\n\r\nSo the original idea of showing the counts only if `_facet_size=max` is a good one.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 962391325, "label": "Show count of facet values if ?_facet_size=max"}, "performed_via_github_app": null}