home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

10 rows where author_association = "OWNER" and "updated_at" is on date 2021-06-15 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

issue 4

  • Idea: import CSV to memory, run SQL, export in a single command 6
  • Mechanism for plugins to exclude certain paths from CSRF checks 2
  • Add some types, enforce with mypy 1
  • bool type not supported 1

user 1

  • simonw 10

author_association 1

  • OWNER · 10 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions issue performed_via_github_app
861891835 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861891835 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg5MTgzNQ== simonw 9599 2021-06-15T23:09:31Z 2021-06-15T23:09:31Z OWNER

--load-csv and --load-json and --load-nl and --load-tsv are unambiguous.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861891693 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861891693 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg5MTY5Mw== simonw 9599 2021-06-15T23:09:08Z 2021-06-15T23:09:08Z OWNER

Problem: --csv and --json and --nl are already options for sqlite-utils query - need new non-conflicting names.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861891272 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861891272 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg5MTI3Mg== simonw 9599 2021-06-15T23:08:02Z 2021-06-15T23:08:02Z OWNER

--csv - should work though, for reading from stdin. The table can be called stdin.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861891110 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861891110 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg5MTExMA== simonw 9599 2021-06-15T23:07:38Z 2021-06-15T23:07:38Z OWNER

--csvt seems unnecessary to me: if people want to load different CSV files with the same filename (but in different directories) they will get an error unless they rename the files first.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861890689 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861890689 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg5MDY4OQ== simonw 9599 2021-06-15T23:06:37Z 2021-06-15T23:06:37Z OWNER

How about --json and --nl and --tsv too? Imitating the format options for sqlite-utils insert.

And what happens if you provide a filename too? I'm tempted to say that the --csv stuff still gets loaded into an in-memory database but it's given a name and can then be joined against using SQLite memory.blah syntax.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861889437 https://github.com/simonw/sqlite-utils/issues/272#issuecomment-861889437 https://api.github.com/repos/simonw/sqlite-utils/issues/272 MDEyOklzc3VlQ29tbWVudDg2MTg4OTQzNw== simonw 9599 2021-06-15T23:03:26Z 2021-06-15T23:03:26Z OWNER

Maybe also support --csvt as an alternative option which takes two arguments: the CSV path and the name of the table that should be created from it (rather than auto-detecting from the filename).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Idea: import CSV to memory, run SQL, export in a single command 921878733  
861103967 https://github.com/simonw/sqlite-utils/issues/269#issuecomment-861103967 https://api.github.com/repos/simonw/sqlite-utils/issues/269 MDEyOklzc3VlQ29tbWVudDg2MTEwMzk2Nw== simonw 9599 2021-06-15T01:34:10Z 2021-06-15T01:34:10Z OWNER

SQLite doesn't have the concept of a boolean column, so there's not much I can do here: https://www.sqlite.org/datatype3.html#boolean_datatype

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
bool type not supported 919250621  
861103684 https://github.com/simonw/sqlite-utils/issues/266#issuecomment-861103684 https://api.github.com/repos/simonw/sqlite-utils/issues/266 MDEyOklzc3VlQ29tbWVudDg2MTEwMzY4NA== simonw 9599 2021-06-15T01:33:13Z 2021-06-15T01:33:13Z OWNER

Dupe of #37

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Add some types, enforce with mypy 913135723  
861089794 https://github.com/simonw/datasette/issues/1377#issuecomment-861089794 https://api.github.com/repos/simonw/datasette/issues/1377 MDEyOklzc3VlQ29tbWVudDg2MTA4OTc5NA== simonw 9599 2021-06-15T00:53:29Z 2021-06-15T00:53:29Z OWNER

Potential hook names:

  • skip_csrf(scope, datasette)
  • ... I can't think of any other ones I would tolerate to be honest
{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Mechanism for plugins to exclude certain paths from CSRF checks 920884085  
861087949 https://github.com/simonw/datasette/issues/1377#issuecomment-861087949 https://api.github.com/repos/simonw/datasette/issues/1377 MDEyOklzc3VlQ29tbWVudDg2MTA4Nzk0OQ== simonw 9599 2021-06-15T00:49:19Z 2021-06-15T00:49:19Z OWNER

The new skip_if_scope mechanism in asgi-csrf https://github.com/simonw/asgi-csrf/issues/20 is designed to help here.

Now I need to design a plugin hook that allows plugins to have an opinion on whether a specific scope should have CSRF skipped.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Mechanism for plugins to exclude certain paths from CSRF checks 920884085  

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 514.608ms · About: github-to-sqlite