home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

12 rows where "updated_at" is on date 2019-11-09 sorted by updated_at descending

✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

issue 7

  • `import` command fails on empty files 4
  • Support cross-database joins 2
  • `followers` fails because `transform_user` is called twice 2
  • Add indexes to followers table 1
  • Refactor TableView.data() method 1
  • Mechanism for seeing indexes on a specific table 1
  • "friends" command (similar to "followers") 1

author_association 3

  • MEMBER 7
  • OWNER 4
  • CONTRIBUTOR 1

user 2

  • simonw 11
  • jacobian 1
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions issue performed_via_github_app
552141417 https://github.com/simonw/datasette/issues/617#issuecomment-552141417 https://api.github.com/repos/simonw/datasette/issues/617 MDEyOklzc3VlQ29tbWVudDU1MjE0MTQxNw== simonw 9599 2019-11-09T21:58:40Z 2019-11-09T21:58:40Z OWNER

The function that builds the query could go in a new datasette.utils.sql module.

I can design it to only take simple arguments (the table name, list of columns, list of primary keys and a list of key/value tuples from the query string). This will make it really easy to test (and means it won't need to be async since it won't have to use queries to retrieve those values).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Refactor TableView.data() method 519613116  
552140975 https://github.com/simonw/datasette/issues/283#issuecomment-552140975 https://api.github.com/repos/simonw/datasette/issues/283 MDEyOklzc3VlQ29tbWVudDU1MjE0MDk3NQ== simonw 9599 2019-11-09T21:51:41Z 2019-11-09T21:51:41Z OWNER

It may turn out that we have to recommend NOT exposing a Datasette instance to the public with dozens of database files that has multi-db queries enabled - will need to load test to understand if this recommendation is needed or not.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Support cross-database joins 325958506  
552140870 https://github.com/simonw/datasette/issues/283#issuecomment-552140870 https://api.github.com/repos/simonw/datasette/issues/283 MDEyOklzc3VlQ29tbWVudDU1MjE0MDg3MA== simonw 9599 2019-11-09T21:49:51Z 2019-11-09T21:49:51Z OWNER

Better idea: if you run Datasette in cross-database joining mode, all connections start out as memory connections and then have new databases attached to them on-demand.

All table view queries will be automatically rewritten to start SELECT db.table.one, db.table.two FROM db.table ...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Support cross-database joins 325958506  
552139232 https://github.com/simonw/datasette/issues/618#issuecomment-552139232 https://api.github.com/repos/simonw/datasette/issues/618 MDEyOklzc3VlQ29tbWVudDU1MjEzOTIzMg== simonw 9599 2019-11-09T21:26:11Z 2019-11-09T21:26:11Z OWNER

Easiest solution here would be to append these on to the create table statement that is displayed on the table page.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Mechanism for seeing indexes on a specific table 520507306  
552135263 https://github.com/dogsheep/twitter-to-sqlite/issues/31#issuecomment-552135263 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/31 MDEyOklzc3VlQ29tbWVudDU1MjEzNTI2Mw== simonw 9599 2019-11-09T20:38:35Z 2019-11-09T20:38:35Z MEMBER

Command still needs documentation and a bit more testing.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
"friends" command (similar to "followers") 520508502  
552134876 https://github.com/dogsheep/twitter-to-sqlite/issues/29#issuecomment-552134876 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/29 MDEyOklzc3VlQ29tbWVudDU1MjEzNDg3Ng== jacobian 21148 2019-11-09T20:33:38Z 2019-11-09T20:33:38Z CONTRIBUTOR

❤️ thanks!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`import` command fails on empty files 518725064  
552133488 https://github.com/dogsheep/twitter-to-sqlite/issues/28#issuecomment-552133488 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/28 MDEyOklzc3VlQ29tbWVudDU1MjEzMzQ4OA== simonw 9599 2019-11-09T20:15:42Z 2019-11-09T20:15:42Z MEMBER

Released: https://github.com/dogsheep/twitter-to-sqlite/releases/tag/0.15

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Add indexes to followers table 515658861  
552133468 https://github.com/dogsheep/twitter-to-sqlite/issues/30#issuecomment-552133468 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/30 MDEyOklzc3VlQ29tbWVudDU1MjEzMzQ2OA== simonw 9599 2019-11-09T20:15:27Z 2019-11-09T20:15:27Z MEMBER

Released: https://github.com/dogsheep/twitter-to-sqlite/releases/tag/0.15

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`followers` fails because `transform_user` is called twice 518739697  
552133449 https://github.com/dogsheep/twitter-to-sqlite/issues/29#issuecomment-552133449 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/29 MDEyOklzc3VlQ29tbWVudDU1MjEzMzQ0OQ== simonw 9599 2019-11-09T20:15:15Z 2019-11-09T20:15:15Z MEMBER

Released: https://github.com/dogsheep/twitter-to-sqlite/releases/tag/0.15

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`import` command fails on empty files 518725064  
552131798 https://github.com/dogsheep/twitter-to-sqlite/issues/30#issuecomment-552131798 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/30 MDEyOklzc3VlQ29tbWVudDU1MjEzMTc5OA== simonw 9599 2019-11-09T19:54:45Z 2019-11-09T19:54:45Z MEMBER

Good catch - not sure how that bug crept in. Removing line 116 looks like the right fix to me.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`followers` fails because `transform_user` is called twice 518739697  
552129921 https://github.com/dogsheep/twitter-to-sqlite/issues/29#issuecomment-552129921 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/29 MDEyOklzc3VlQ29tbWVudDU1MjEyOTkyMQ== simonw 9599 2019-11-09T19:30:42Z 2019-11-09T19:30:42Z MEMBER

Confirmed, that seems to fix it: (twitter-to-sqlite) ~/Dropbox/Development/twitter-to-sqlite $ twitter-to-sqlite import blah.db ~/Dropbox/dogsheep/twitter-2019-06-25-b31f246100821b551f2f9a23f21ac6fb565dab49dd23a35630cabbf2b94a1f03/account-suspension.js Traceback (most recent call last): File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/bin/twitter-to-sqlite", line 11, in <module> load_entry_point('twitter-to-sqlite', 'console_scripts', 'twitter-to-sqlite')() File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/click/core.py", line 764, in __call__ return self.main(*args, **kwargs) File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/click/core.py", line 717, in main rv = self.invoke(ctx) File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/click/core.py", line 1137, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/click/core.py", line 956, in invoke return ctx.invoke(self.callback, **ctx.params) File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/click/core.py", line 555, in invoke return callback(*args, **kwargs) File "/Users/simonw/Dropbox/Development/twitter-to-sqlite/twitter_to_sqlite/cli.py", line 633, in import_ archive.import_from_file(db, path.name, open(path, "rb").read()) File "/Users/simonw/Dropbox/Development/twitter-to-sqlite/twitter_to_sqlite/archive.py", line 224, in import_from_file db[table_name].upsert_all(rows, hash_id="pk") File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/sqlite_utils/db.py", line 1094, in upsert_all extracts=extracts, File "/Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages/sqlite_utils/db.py", line 961, in insert_all first_record = next(records) StopIteration (twitter-to-sqlite) ~/Dropbox/Development/twitter-to-sqlite $ pip install -U sqlite-utils Collecting sqlite-utils Using cached https://files.pythonhosted.org/packages/ee/a2/1b135010c7ac8e2d7545f659e9e6c6ede0f406f20b52e08d5817e1e31a9a/sqlite_utils-1.12.1-py3-none-any.whl Requirement already satisfied, skipping upgrade: click in /Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages (from sqlite-utils) (7.0) Requirement already satisfied, skipping upgrade: tabulate in /Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages (from sqlite-utils) (0.8.5) Requirement already satisfied, skipping upgrade: click-default-group in /Users/simonw/.local/share/virtualenvs/twitter-to-sqlite-4ech4lJi/lib/python3.7/site-packages (from sqlite-utils) (1.2.2) Installing collected packages: sqlite-utils Found existing installation: sqlite-utils 1.11 Uninstalling sqlite-utils-1.11: Successfully uninstalled sqlite-utils-1.11 Successfully installed sqlite-utils-1.12.1 (twitter-to-sqlite) ~/Dropbox/Development/twitter-to-sqlite $ twitter-to-sqlite import blah.db ~/Dropbox/dogsheep/twitter-2019-06-25-b31f246100821b551f2f9a23f21ac6fb565dab49dd23a35630cabbf2b94a1f03/account-suspension.js (twitter-to-sqlite) ~/Dropbox/Development/twitter-to-sqlite $

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`import` command fails on empty files 518725064  
552129686 https://github.com/dogsheep/twitter-to-sqlite/issues/29#issuecomment-552129686 https://api.github.com/repos/dogsheep/twitter-to-sqlite/issues/29 MDEyOklzc3VlQ29tbWVudDU1MjEyOTY4Ng== simonw 9599 2019-11-09T19:27:39Z 2019-11-09T19:27:39Z MEMBER

I think this is fixed by the latest version of sqlite-utils - https://sqlite-utils.readthedocs.io/en/latest/changelog.html#v1-12-1 - I'll bump the dependency.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
`import` command fails on empty files 518725064  

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