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/issues/842#issuecomment-649014757 | https://api.github.com/repos/simonw/datasette/issues/842 | 649014757 | MDEyOklzc3VlQ29tbWVudDY0OTAxNDc1Nw== | 9599 | 2020-06-24T19:15:46Z | 2020-06-24T19:31:52Z | OWNER | I'm building this documentation-first - here's the documentation so far: https://github.com/simonw/datasette/blob/6fc8bd9c473f4a25e0a076f24c7e5a9b2f353bb8/docs/sql_queries.rst#magic-parameters | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
638212085 | |
https://github.com/simonw/datasette/issues/842#issuecomment-649000075 | https://api.github.com/repos/simonw/datasette/issues/842 | 649000075 | MDEyOklzc3VlQ29tbWVudDY0OTAwMDA3NQ== | 9599 | 2020-06-24T18:46:36Z | 2020-06-24T18:47:37Z | OWNER | Another magic parameter that would be useful would be `_random`. Consider https://github.com/simonw/datasette-auth-tokens/issues/1 for example - I'd like to be able to provide a writable canned query which can create new authentication tokens in the database, but ideally it would automatically populate a secure random secret for each one. Maybe `_random_chars_128` to create a 128 character long random string (using `os.urandom(64).hex()`). This would be the first example of a magic parameter where part of the parameter name is used to configure the resulting value. Maybe neater to separate that with a different character? Unfortunately `_random_chars:128` wouldn't work because these parameters are used in a SQLite query where `:` has special meaning: `insert into blah (secret) values (:_random_chars:128)` wouldn't make sense. Actually this is already supported by the proposed design - `_random_chars_128` would become `random("chars_128")` so the `random()` function could split off the 128 itself. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
638212085 | |
https://github.com/simonw/datasette/issues/865#issuecomment-648998264 | https://api.github.com/repos/simonw/datasette/issues/865 | 648998264 | MDEyOklzc3VlQ29tbWVudDY0ODk5ODI2NA== | 9599 | 2020-06-24T18:43:02Z | 2020-06-24T18:43:02Z | OWNER | Thanks for the bug report. Yes I think #838 may be the same issue. Will investigate. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
644582921 | |
https://github.com/simonw/datasette/issues/858#issuecomment-648997857 | https://api.github.com/repos/simonw/datasette/issues/858 | 648997857 | MDEyOklzc3VlQ29tbWVudDY0ODk5Nzg1Nw== | 9599 | 2020-06-24T18:42:10Z | 2020-06-24T18:42:10Z | OWNER | I really need to get myself a Windows 10 development environment working so I can dig into this kind of bug properly. I have a gaming PC lying around that I could re-task for that. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
642388564 | |
https://github.com/simonw/datasette/issues/864#issuecomment-648580556 | https://api.github.com/repos/simonw/datasette/issues/864 | 648580556 | MDEyOklzc3VlQ29tbWVudDY0ODU4MDU1Ng== | 9599 | 2020-06-24T04:40:49Z | 2020-06-24T04:40:49Z | OWNER | The ideal fix here would be to rework my `BaseView` subclass mechanism to work with `register_routes()` so that those views don't have any special privileges above plugin-provided views. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
644309017 | |
https://github.com/simonw/datasette/issues/864#issuecomment-648580236 | https://api.github.com/repos/simonw/datasette/issues/864 | 648580236 | MDEyOklzc3VlQ29tbWVudDY0ODU4MDIzNg== | 9599 | 2020-06-24T04:39:39Z | 2020-06-24T04:39:39Z | OWNER | Urgh, fixing this is going to be a bit of a pain. Here's where I added that custom `dispatch_request()` method - it was to implement flash messaging in #790: https://github.com/simonw/datasette/blame/1a5b7d318fa923edfcefd3df8f64dae2e9c49d3f/datasette/views/base.py#L85 If I want this to be made available to `register_routes()` views as well, I'm going to have to move the logic somewhere else. In particular I need to make sure that the `request` object is created once and used throughout the whole request cycle. Currently `register_routes()` view functions get their own separate request object which is created here: https://github.com/simonw/datasette/blob/1a5b7d318fa923edfcefd3df8f64dae2e9c49d3f/datasette/app.py#L1057-L1068 So I'm going to have to refactor this quite a bit to get that shared request object which can be passed both to `register_routes` views and to my various `BaseView` subclasses. | { "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
644309017 |