home / github

Menu
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

11 rows where issue = 663228985

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: created_at (date), updated_at (date)

id ▼ html_url issue_url node_id user created_at updated_at author_association body reactions issue performed_via_github_app
709633823 https://github.com/simonw/datasette/issues/904#issuecomment-709633823 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcwOTYzMzgyMw== simonw 9599 2020-10-15T23:01:13Z 2020-10-15T23:01:13Z OWNER Tracking ticket: #1023 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
709634261 https://github.com/simonw/datasette/issues/904#issuecomment-709634261 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcwOTYzNDI2MQ== simonw 9599 2020-10-15T23:02:43Z 2020-10-15T23:02:43Z OWNER Here's the current implementation of `database_url` - on the `BaseView` class, but only because it needs access to a `datasette` instance (to read `base_url`): https://github.com/simonw/datasette/blob/8f97b9b58e77f82fef1f10e9c9f6754b993544b6/datasette/views/base.py#L102-L108 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
709635021 https://github.com/simonw/datasette/issues/904#issuecomment-709635021 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcwOTYzNTAyMQ== simonw 9599 2020-10-15T23:05:11Z 2020-10-15T23:05:11Z OWNER I think this should be a family of functions: - `instance_url()` - the root URL of the instance (usually `/` unless `base_url` is set) - `database_url(database_name)` - already got this - `table_url(database_name, table_name)` - `row_url(database_name, table_name, row)` - not sure about this one. The idea would be for `row` to be correctly turned into a URL by introspecting the primary keys for that table, then pulling those values out of the SQLite `row` object. Might not be necessary though. I also need a way for plugins to link to e.g. `/-/configure-fts` - or even `/-/configure-fts/database-name/table-name`. What should that look like? {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
709635276 https://github.com/simonw/datasette/issues/904#issuecomment-709635276 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcwOTYzNTI3Ng== simonw 9599 2020-10-15T23:05:54Z 2020-10-15T23:05:54Z OWNER Could have `instance_url()` take an optional path argument which is then turned into the correct path. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
710487083 https://github.com/simonw/datasette/issues/904#issuecomment-710487083 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMDQ4NzA4Mw== simonw 9599 2020-10-16T19:34:10Z 2020-10-19T17:39:04Z OWNER Alternatively, I could expose a single object that knows how to construct all kinds of URLs. Something like this: ``` {{ urls.instance() }} {{ urls.database(database_name) }} {{ urls.table(database_name, table_name) }} etc ``` {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712324077 https://github.com/simonw/datasette/issues/904#issuecomment-712324077 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjMyNDA3Nw== simonw 9599 2020-10-19T17:39:38Z 2020-10-19T17:39:38Z OWNER If I do these methods I think this should be available on the `datasette` object too, as an internal API for plugins to use to construct redirects and suchlike. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712354600 https://github.com/simonw/datasette/issues/904#issuecomment-712354600 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjM1NDYwMA== simonw 9599 2020-10-19T18:15:03Z 2020-10-19T18:15:39Z OWNER Related: #1026 (How should datasette.client interact with base_url) Also this comment from https://github.com/simonw/datasette/issues/943#issuecomment-675752436 > One thing to consider here: Datasette's table and database name escaping rules can be a little bit convoluted. > > If a plugin wants to get back the first five rows of a table, it will need to construct a URL `/dbname/tablename?_size=5` - but it will need to know how to turn the database and table names into the correctly escaped `dbname` and `tablename` values. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712355706 https://github.com/simonw/datasette/issues/904#issuecomment-712355706 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjM1NTcwNg== simonw 9599 2020-10-19T18:17:03Z 2020-10-19T18:17:03Z OWNER Options: - `datasette.urls.instance()` (or `datasette.urls.root()`), `datasette.urls.table()` etc - `datasette.url_for.instance()`... - `datasette.url.instance()`... - `datasette.root_url()`, `datasette.table_url()`... {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712355877 https://github.com/simonw/datasette/issues/904#issuecomment-712355877 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjM1NTg3Nw== simonw 9599 2020-10-19T18:17:22Z 2020-10-19T18:17:22Z OWNER I quite like `datasette.urls.table()` but I'm not sure why. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712483066 https://github.com/simonw/datasette/issues/904#issuecomment-712483066 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjQ4MzA2Ng== simonw 9599 2020-10-19T22:46:48Z 2020-10-19T22:46:48Z OWNER OK, I'm committing to `datasette.urls.table()` and friends, which will be available to (and documented for use in) plugins and will be exposed to templates as `{{ urls.table(...) }}`. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  
712524699 https://github.com/simonw/datasette/issues/904#issuecomment-712524699 https://api.github.com/repos/simonw/datasette/issues/904 MDEyOklzc3VlQ29tbWVudDcxMjUyNDY5OQ== simonw 9599 2020-10-20T01:04:12Z 2020-10-20T01:04:12Z OWNER Documentation is https://docs.datasette.io/en/latest/writing_plugins.html#building-urls-within-plugins and https://docs.datasette.io/en/latest/internals.html#internals-datasette-urls {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette.urls.table() / .instance() / .database() methods for constructing URLs, also exposed to templates 663228985  

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
, [performed_via_github_app] TEXT);
CREATE INDEX [idx_issue_comments_issue]
                ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
                ON [issue_comments] ([user]);
Powered by Datasette · Queries took 20.738ms · About: simonw/datasette-graphql