home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

11 rows where "updated_at" is on date 2020-11-02 sorted by updated_at descending

✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

issue 5

  • "View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 5
  • Handle really wide tables better 2
  • database_actions plugin hook 2
  • Redesign register_facet_classes plugin hook 1
  • Incorrect URLs when served behind a proxy with base_url set 1

user 3

  • simonw 9
  • psychemedia 1
  • terrycojones 1

author_association 3

  • OWNER 9
  • CONTRIBUTOR 1
  • NONE 1
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions issue performed_via_github_app
720741903 https://github.com/simonw/datasette/issues/596#issuecomment-720741903 https://api.github.com/repos/simonw/datasette/issues/596 MDEyOklzc3VlQ29tbWVudDcyMDc0MTkwMw== terrycojones 132978 2020-11-02T21:44:45Z 2020-11-02T21:44:45Z NONE

Hi & thanks for the note @simonw! I wish I had more time to play with (and contribute to) datasette. I know you don't need me to tell you that it's super cool :-)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Handle really wide tables better 507454958  
720700065 https://github.com/simonw/datasette/issues/830#issuecomment-720700065 https://api.github.com/repos/simonw/datasette/issues/830 MDEyOklzc3VlQ29tbWVudDcyMDcwMDA2NQ== simonw 9599 2020-11-02T20:15:36Z 2020-11-02T20:15:36Z OWNER

427 had a bunch of ambitious plans for faceting that I haven't realized yet:

Think of all of the potential kinds of facets:

  • ?_facet_array=tags where tags is a JSON array of values
  • _facet_date=datetimecol - faceted by date part of a datetime
  • _facet_bins=numeric_column - can I do some kind of fancy binning here? Might need to take an argument
  • ?_facet_bins=numeric_column:5 - could be a way to take an argument. We’ll ignore columns with a : in their name.
  • ?_facet_json=jsoncol:jsonpath - could use a JSON path to extract out something to facet on?
  • ?_facet_percentile=numericcolumn - could this work?
  • ?_facet_function=column:sqlfunctionname - maybe this could be interesting? Would allow for e.g. facet by soundex
  • ?_facet_prefix=column:prefix - facet by terms but only if they start with a specific prefix
  • ?_facet_substring=column:3,6 - facet by a substr(column, 3, 6)
{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Redesign register_facet_classes plugin hook 636511683  
720696827 https://github.com/simonw/datasette/issues/1080#issuecomment-720696827 https://api.github.com/repos/simonw/datasette/issues/1080 MDEyOklzc3VlQ29tbWVudDcyMDY5NjgyNw== simonw 9599 2020-11-02T20:08:49Z 2020-11-02T20:13:56Z OWNER

Implementing pagination for facets will be interesting. Would be easier if I had a nicer reusable internal pagination mechanism, which is also needed for #856 (pagination of canned queries).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 734777631  
720699160 https://github.com/simonw/datasette/issues/1080#issuecomment-720699160 https://api.github.com/repos/simonw/datasette/issues/1080 MDEyOklzc3VlQ29tbWVudDcyMDY5OTE2MA== simonw 9599 2020-11-02T20:13:42Z 2020-11-02T20:13:42Z OWNER

Also relevant to this issue: #830 - redesigning the facet plugin hook in preparation for Datasette 1.0. And #972 supporting faceting against arbitrary queries.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 734777631  
720698577 https://github.com/simonw/datasette/issues/1080#issuecomment-720698577 https://api.github.com/repos/simonw/datasette/issues/1080 MDEyOklzc3VlQ29tbWVudDcyMDY5ODU3Nw== simonw 9599 2020-11-02T20:12:26Z 2020-11-02T20:12:26Z OWNER

For regular column faceting, here's the query that is used:

https://github.com/simonw/datasette/blob/13d1228d80c91d382a05b1a9549ed02c300ef851/datasette/facets.py#L196-L204

Since it uses order by count desc, value maybe those values could be used to implement cursor-based pagination.

That wouldn't be robust in the face of changing data, but I'm not sure it's possible to implement paginated faceting in a way that survives ongoing changes to the underlying data.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 734777631  
720697226 https://github.com/simonw/datasette/issues/1080#issuecomment-720697226 https://api.github.com/repos/simonw/datasette/issues/1080 MDEyOklzc3VlQ29tbWVudDcyMDY5NzIyNg== simonw 9599 2020-11-02T20:09:38Z 2020-11-02T20:09:38Z OWNER

Maybe this ends up being code that defers to a simulated canned query, rendered using the existing query.html template.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 734777631  
720695174 https://github.com/simonw/datasette/issues/1080#issuecomment-720695174 https://api.github.com/repos/simonw/datasette/issues/1080 MDEyOklzc3VlQ29tbWVudDcyMDY5NTE3NA== simonw 9599 2020-11-02T20:05:26Z 2020-11-02T20:05:26Z OWNER

URL design:

/database/table/-/facet/colname

And for other types of facet (to be supported later):

/database/table/-/facet/colname?_type=m2m

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"View all" option for facets, to provide a (paginated) list of ALL of the facet counts plus a link to view them 734777631  
720689653 https://github.com/simonw/datasette/issues/596#issuecomment-720689653 https://api.github.com/repos/simonw/datasette/issues/596 MDEyOklzc3VlQ29tbWVudDcyMDY4OTY1Mw== simonw 9599 2020-11-02T19:53:36Z 2020-11-02T19:53:47Z OWNER

In #998 I implemented a horizontal scrollbar for these tables, which is a big improvement - demo here: https://global-power-plants.datasettes.com/global-power-plants/global-power-plants

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Handle really wide tables better 507454958  
720654925 https://github.com/simonw/datasette/issues/1077#issuecomment-720654925 https://api.github.com/repos/simonw/datasette/issues/1077 MDEyOklzc3VlQ29tbWVudDcyMDY1NDkyNQ== simonw 9599 2020-11-02T18:43:25Z 2020-11-02T18:43:25Z OWNER

Demo: https://latest.datasette.io/fixtures?_bot=1

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
database_actions plugin hook 733829385  
720637322 https://github.com/simonw/datasette/issues/1077#issuecomment-720637322 https://api.github.com/repos/simonw/datasette/issues/1077 MDEyOklzc3VlQ29tbWVudDcyMDYzNzMyMg== simonw 9599 2020-11-02T18:09:17Z 2020-11-02T18:09:17Z OWNER

Here's the table_actions implementation: 2f7731e9e5ff9b324beb5039fbe2be55d704a184

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
database_actions plugin hook 733829385  
720354227 https://github.com/simonw/datasette/issues/838#issuecomment-720354227 https://api.github.com/repos/simonw/datasette/issues/838 MDEyOklzc3VlQ29tbWVudDcyMDM1NDIyNw== psychemedia 82988 2020-11-02T09:33:58Z 2020-11-02T09:33:58Z CONTRIBUTOR

Thanks; just a note that the datasette.urls.static(path) and datasette.urls.static_plugins(plugin_name, path) items both seem to be repeated and appear in the docs twice?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Incorrect URLs when served behind a proxy with base_url set 637395097  

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 852.198ms · About: github-to-sqlite
  • Sort ascending
  • Sort descending
  • Facet by this
  • Hide this column
  • Show all columns
  • Show not-blank rows