github
html_url | issue_url | id | node_id | user | created_at | updated_at | author_association | body | reactions | issue | performed_via_github_app |
---|---|---|---|---|---|---|---|---|---|---|---|
https://github.com/simonw/datasette/pull/1022#issuecomment-708718475 | https://api.github.com/repos/simonw/datasette/issues/1022 | 708718475 | MDEyOklzc3VlQ29tbWVudDcwODcxODQ3NQ== | 9599 | 2020-10-14T23:46:38Z | 2020-10-14T23:46:38Z | OWNER | Good catch, thanks! | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721830990 | |
https://github.com/simonw/sqlite-utils/issues/182#issuecomment-708695761 | https://api.github.com/repos/simonw/sqlite-utils/issues/182 | 708695761 | MDEyOklzc3VlQ29tbWVudDcwODY5NTc2MQ== | 9599 | 2020-10-14T22:33:55Z | 2020-10-14T22:35:17Z | OWNER | For the moment I'm going to add a `--encoding` option and some code that catches `UnicodeDecodeError` and shows an error message that suggests using `--encoding`. That error message could detect if the `file` command is available and, if it is, suggest running `file filename.txt` to detect the character encoding. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
711649325 | |
https://github.com/simonw/sqlite-utils/issues/163#issuecomment-708695369 | https://api.github.com/repos/simonw/sqlite-utils/issues/163 | 708695369 | MDEyOklzc3VlQ29tbWVudDcwODY5NTM2OQ== | 9599 | 2020-10-14T22:32:39Z | 2020-10-14T22:32:39Z | OWNER | `sqlite-utils convert my.db mytable mycolumn` could become the new `sqlite-transform`. The sub-command could take `--code` but could also take `--parsedate` and `--parsedatetime` options. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
706001517 | |
https://github.com/simonw/sqlite-utils/issues/163#issuecomment-708693290 | https://api.github.com/repos/simonw/sqlite-utils/issues/163 | 708693290 | MDEyOklzc3VlQ29tbWVudDcwODY5MzI5MA== | 9599 | 2020-10-14T22:26:50Z | 2020-10-14T22:27:48Z | OWNER | This could even be exposed as a feature of the CLI tool - similar to how `sqlite-transform` works: https://github.com/simonw/sqlite-transform $ sqlite-transform lambda my.db mytable mycolumn --code='str(value).upper()' Maybe `sqlite-utils` should absorb all of the functionality from `sqlite-transform` - having two separate tools doesn't necessarily make sense. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
706001517 | |
https://github.com/simonw/sqlite-utils/issues/182#issuecomment-708693133 | https://api.github.com/repos/simonw/sqlite-utils/issues/182 | 708693133 | MDEyOklzc3VlQ29tbWVudDcwODY5MzEzMw== | 9599 | 2020-10-14T22:26:26Z | 2020-10-14T22:26:26Z | OWNER | I could use https://github.com/chardet/chardet to help here, though I'd rather not add it as a dependency (`sqlite-utils` has very few dependencies at the moment). I could add it as an optional dependency though. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
711649325 | |
https://github.com/simonw/datasette/issues/1020#issuecomment-708670392 | https://api.github.com/repos/simonw/datasette/issues/1020 | 708670392 | MDEyOklzc3VlQ29tbWVudDcwODY3MDM5Mg== | 9599 | 2020-10-14T21:29:22Z | 2020-10-14T21:29:22Z | OWNER | I should also verify (and probably unit-test) that things like the `?_trace=1` mechanism work across the internal request boundary. `/-/permissions` appears to work across this boundary, but again a test would be useful confirmation. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721068929 | |
https://github.com/simonw/datasette/issues/1020#issuecomment-708669778 | https://api.github.com/repos/simonw/datasette/issues/1020 | 708669778 | MDEyOklzc3VlQ29tbWVudDcwODY2OTc3OA== | 9599 | 2020-10-14T21:27:58Z | 2020-10-14T21:27:58Z | OWNER | Maybe these internal requests should have some kind of flag that lets the underlying code tell that it's being called internally. One option: add a `x-internal: 1` request header - and ensure that any requests from outside Datasette have that header stripped. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721068929 | |
https://github.com/simonw/datasette/issues/1020#issuecomment-708669178 | https://api.github.com/repos/simonw/datasette/issues/1020 | 708669178 | MDEyOklzc3VlQ29tbWVudDcwODY2OTE3OA== | 9599 | 2020-10-14T21:26:37Z | 2020-10-14T21:26:37Z | OWNER | One option: add an optional request=... parameter which can be passed the current request, and will use that to populate the mock request with the exception of the bits that are passed explicitly (like the path): ```python response = await datasette.client.get("/db/table.json", request=request) ``` | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721068929 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708139822 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708139822 | MDEyOklzc3VlQ29tbWVudDcwODEzOTgyMg== | 9599 | 2020-10-14T03:53:21Z | 2020-10-14T03:53:21Z | OWNER | Demos: - https://latest.datasette.io/fixtures/neighborhood_search has the link - https://latest.datasette.io/fixtures/neighborhood_search?text=ber has the link, and the link passes through the parameter that has already been entered - https://latest.datasette.io/fixtures/%F0%9D%90%9C%F0%9D%90%A2%F0%9D%90%AD%F0%9D%90%A2%F0%9D%90%9E%F0%9D%90%AC has the link - https://latest.datasette.io/fixtures/pragma_cache_size does not have the link (`PRAGMA` is not allowed in regular editable queries) - https://latest.datasette.io/fixtures/magic_parameters does not have the link (magic parameters) | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708130290 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708130290 | MDEyOklzc3VlQ29tbWVudDcwODEzMDI5MA== | 9599 | 2020-10-14T03:17:57Z | 2020-10-14T03:17:57Z | OWNER | One last edge-case (I think) - magic parameters aren't supported for non-canned-queries, so if a query includes those it shouldn't show an Edit SQL link: https://latest.datasette.io/fixtures/magic_parameters I don't have a clean way of detecting if a query contains defined magic parameters, but I can instead do a dumb substring match for `:_` and skip showing the Edit SQL link if that is present. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708128286 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708128286 | MDEyOklzc3VlQ29tbWVudDcwODEyODI4Ng== | 9599 | 2020-10-14T03:11:33Z | 2020-10-14T03:14:07Z | OWNER | Another edge-case: https://latest.datasette.io/fixtures/pragma_cache_size (`PRAGMA cache_size;`) isn't an allowed query usually, so linking to "Edit SQL" for it would link to an error page: https://latest.datasette.io/fixtures?sql=PRAGMA+cache_size%3B Can use `datasette.utils.validate_sql_select(sql)` to check for that - it raises `datasette.utils.InvalidSql` if there's a problem. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708127294 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708127294 | MDEyOklzc3VlQ29tbWVudDcwODEyNzI5NA== | 9599 | 2020-10-14T03:08:13Z | 2020-10-14T03:08:13Z | OWNER | Maybe like this: <img width="1385" alt="fixtures__select_neighborhood__facet_cities_name__state_from_facetable_join_facet_cities_on_facetable_city_id___facet_cities_id_where_neighborhood_like_________text________order_by_neighborhood_" src="https://user-images.githubusercontent.com/9599/95938930-ce721700-0d8f-11eb-87c8-f67ea4e57d55.png"> | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708114636 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708114636 | MDEyOklzc3VlQ29tbWVudDcwODExNDYzNg== | 9599 | 2020-10-14T02:24:56Z | 2020-10-14T02:24:56Z | OWNER | So it would appear on this page: https://latest.datasette.io/fixtures/neighborhood_search#fragment-goes-here Probably as a blue "Edit SQL" link next to those buttons. ![575FB160-4F75-43B2-B2AB-D75E60F10477](https://user-images.githubusercontent.com/9599/95936143-c2835680-0d89-11eb-9cf3-06f86d923103.jpeg) | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 | |
https://github.com/simonw/datasette/issues/1019#issuecomment-708113989 | https://api.github.com/repos/simonw/datasette/issues/1019 | 708113989 | MDEyOklzc3VlQ29tbWVudDcwODExMzk4OQ== | 9599 | 2020-10-14T02:22:40Z | 2020-10-14T02:22:40Z | OWNER | I've found myself wanting this too. It should respect the allow-sql permission so it doesn't display if the user isn't able to run custom SQL. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
721050815 |