{"html_url": "https://github.com/simonw/datasette/issues/575#issuecomment-716048199", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/575", "id": 716048199, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNjA0ODE5OQ==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T20:05:44Z", "updated_at": "2020-10-24T20:05:44Z", "author_association": "OWNER", "body": "https://docs.datasette.io/en/latest/writing_plugins.html#static-assets", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 497162288, "label": "Plugin documentation should cover how to bundle static/templates in setup.py"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1033#issuecomment-716048564", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1033", "id": 716048564, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNjA0ODU2NA==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T20:08:31Z", "updated_at": "2020-10-24T20:08:31Z", "author_association": "OWNER", "body": "Documentation here: https://docs.datasette.io/en/latest/internals.html#datasette-urls", "reactions": "{\"total_count\": 1, \"+1\": 1, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 725099777, "label": "datasette.urls.static_plugins(...) method"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1033#issuecomment-716066000", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1033", "id": 716066000, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNjA2NjAwMA==", "user": {"value": 82988, "label": "psychemedia"}, "created_at": "2020-10-24T22:58:33Z", "updated_at": "2020-10-24T22:58:33Z", "author_association": "CONTRIBUTOR", "body": "From [the docs](https://docs.datasette.io/en/latest/internals.html#datasette-urls), I note:\r\n\r\n```\r\ndatasette.urls.instance()\r\nReturns the URL to the Datasette instance root page. This is usually \"/\"\r\n```\r\n\r\nWhat about the proxy case? Eg if I am using jupyter-server-proxy on a MyBinder or local Jupyter notebook server site, `https://example.com:PORT/weirdpath/datasette`, what does `datasette.urls.instance()` refer to?\r\n\r\n- [ ] `https://example.com:PORT/weirdpath/datasette`\r\n- [ ] `https://example.com:PORT/weirdpath/`\r\n- [ ] `https://example.com:PORT/`\r\n- [ ] `https://example.com`\r\n- [ ] something else?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 725099777, "label": "datasette.urls.static_plugins(...) method"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1042#issuecomment-715643646", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1042", "id": 715643646, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNTY0MzY0Ng==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T00:33:46Z", "updated_at": "2020-10-24T00:33:46Z", "author_association": "OWNER", "body": "I'd like to do this all in the `datasette.render_template()` method to ensure it's available to plugins as well, not just core code that uses the `BaseView` class.\r\n\r\nThis code is the problem:\r\nhttps://github.com/simonw/datasette/blob/d3e9b0aecb6f8e9b2befd9c654ccb7ce852db3e7/datasette/views/base.py#L114-L133\r\n\r\nI think I'll fix this by moving the `select_templates` mechanism into `datasette.render_templates()`.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 727802081, "label": "Plugin hook for loading templates"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1042#issuecomment-715643763", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1042", "id": 715643763, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNTY0Mzc2Mw==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T00:34:31Z", "updated_at": "2020-10-24T00:34:52Z", "author_association": "OWNER", "body": "I'm going to rename that to template variable from `select_templates` to `templates_considered` too.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 727802081, "label": "Plugin hook for loading templates"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1045#issuecomment-715641183", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1045", "id": 715641183, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNTY0MTE4Mw==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T00:19:29Z", "updated_at": "2020-10-24T00:19:29Z", "author_association": "OWNER", "body": "It turns out it already does that:\r\n\r\nhttps://github.com/simonw/datasette/blob/976e5f74aae1fa0d406df6691dc8b5feeebe8788/datasette/app.py#L710-L720\r\n\r\nBut the documentation doesn't reflect that:\r\n\r\n> `template` - string\r\n> \r\n> > The template file to be rendered, e.g. `my_plugin.html`. Datasette will search for this file first in the `--template-dir=` location, if it was specified - then in the plugin's bundled templates and finally in Datasette's set of default templates.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 728600048, "label": "Document that datasette.render_template(template, ...) also accepts a list of templates"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1046#issuecomment-716066342", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1046", "id": 716066342, "node_id": "MDEyOklzc3VlQ29tbWVudDcxNjA2NjM0Mg==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-10-24T23:02:07Z", "updated_at": "2020-10-24T23:02:25Z", "author_association": "OWNER", "body": "A download icon would be nice for the links in the table display. I like this one https://primer.style/octicons/download-24\r\n\r\n```svg\r\n\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": 728895193, "label": "Link to blob downloads in the right places"}, "performed_via_github_app": null}