home / github

Menu
  • Search all tables
  • GraphQL API

issues

Table actions
  • GraphQL API for issues

19 rows where type = "pull" and user = 45057 sorted by updated_at descending

✖
✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

state 2

  • closed 18
  • open 1

type 1

  • pull · 19 ✖

repo 1

  • datasette 19
id node_id number title user state locked assignee milestone comments created_at updated_at ▲ closed_at author_association pull_request body repo type active_lock_reason performed_via_github_app reactions draft state_reason
438048318 MDExOlB1bGxSZXF1ZXN0Mjc0MTc0NjE0 437 Add inspect and prepare_sanic hooks russss 45057 closed 0     2 2019-04-28T11:53:34Z 2019-06-24T16:38:57Z 2019-06-24T16:38:56Z CONTRIBUTOR simonw/datasette/pulls/437

This adds two new plugin hooks:

The inspect hook allows plugins to add data to the inspect dictionary.

The prepare_sanic hook allows plugins to hook into the web router. I've attached a warning to this hook in the docs in light of #272 but I want this hook now...

On quick inspection, I don't think it's worthwhile to try and make this hook independent of the web framework (but it looks like Starlette would make the hook implementation a bit nicer).

Ref #14

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/437/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
440304714 MDExOlB1bGxSZXF1ZXN0Mjc1OTA5MTk3 450 Coalesce hidden table count to 0 russss 45057 closed 0     2 2019-05-04T09:37:10Z 2019-05-11T18:10:09Z 2019-05-11T18:10:09Z CONTRIBUTOR simonw/datasette/pulls/450

For some reason I'm hitting a None here with a FTS table. I'm not entirely sure why but this makes the logic work the same as with non-hidden tables.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/450/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
440325850 MDExOlB1bGxSZXF1ZXN0Mjc1OTIzMDY2 452 SQL builder utility classes russss 45057 open 0     0 2019-05-04T13:57:47Z 2019-05-04T14:03:04Z   CONTRIBUTOR simonw/datasette/pulls/452

This adds a straightforward set of classes to aid in the construction of SQL queries.

My plan for this was to allow plugins to manipulate the Datasette-generated SQL in a more structured way. I'm not sure that's going to work, but I feel like this is still a step forward - it reduces the number of intermediate variables in TableView.data which aids readability, and also factors out a lot of the boring string concatenation.

There are a fair number of minor structure changes in here too as I've tried to make the ordering of TableView.data a bit more logical. As far as I can tell, I haven't broken anything...

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/452/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
439487648 MDExOlB1bGxSZXF1ZXN0Mjc1MjgxMzA3 444 Add a max-line-length setting for flake8 russss 45057 closed 0     0 2019-05-02T08:58:57Z 2019-05-04T09:44:48Z 2019-05-03T13:11:28Z CONTRIBUTOR simonw/datasette/pulls/444

This stops my automatic editor linting from flagging lines which are too long. It's been lingering in my checkout for ages.

160 is an arbitrary large number - we could alter it if we have any opinions (but I find the line length limit to be my least favourite part of PEP8).

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/444/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
438450757 MDExOlB1bGxSZXF1ZXN0Mjc0NDc4NzYx 442 Suppress rendering of binary data russss 45057 closed 0     2 2019-04-29T18:36:41Z 2019-05-03T18:26:48Z 2019-05-03T16:44:49Z CONTRIBUTOR simonw/datasette/pulls/442

Binary columns (including spatialite geographies) get shown as ugly binary strings in the HTML by default. Nobody wants to see that mess.

Show the size of the column in bytes instead. If you want to decode the binary data, you can use a plugin to do it.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/442/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
439480260 MDExOlB1bGxSZXF1ZXN0Mjc1Mjc1NjEw 443 Pass view_name to extra_body_script hook russss 45057 closed 0     0 2019-05-02T08:38:36Z 2019-05-03T13:12:20Z 2019-05-03T13:12:20Z CONTRIBUTOR simonw/datasette/pulls/443

At the moment it's not easy to tell whether the hook is being called in (for example) the row or table view, as in both cases the database and table parameters are provided.

This passes the view_name added in #441 to the extra_body_script hook.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/443/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
438437973 MDExOlB1bGxSZXF1ZXN0Mjc0NDY4ODM2 441 Add register_output_renderer hook russss 45057 closed 0     8 2019-04-29T18:03:21Z 2019-05-01T23:01:57Z 2019-05-01T23:01:57Z CONTRIBUTOR simonw/datasette/pulls/441

This changeset refactors out the JSON renderer and then adds a hook and dispatcher system to allow custom output renderers to be registered.

The CSV output renderer is untouched because supporting streaming renderers through this system would be significantly more complex, and probably not worthwhile.

We can't simply allow hooks to be called at request time because we need a list of supported file extensions when the request is being routed in order to resolve ambiguous database/table names. So, renderers need to be registered at startup.

I've tried to make this API independent of Sanic's request/response objects so that this can remain stable during the switch to ASGI. I'm using dictionaries to keep it simple and to make adding additional options in the future easy.

Fixes #440

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/441/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
438240541 MDExOlB1bGxSZXF1ZXN0Mjc0MzEzNjI1 439 [WIP] Add primary key to the extra_body_script hook arguments russss 45057 closed 0     2 2019-04-29T10:08:23Z 2019-05-01T09:58:32Z 2019-05-01T09:58:30Z CONTRIBUTOR simonw/datasette/pulls/439

This allows the row to be identified on row pages. The context here is that I want to access the row's data to plot it on a map.

I considered passing the entire template context through to the hook function. This would expose the actual row data and potentially avoid a further fetch request in JS, but it does make the plugin API a lot more leaky.

(At any rate, using the selected row data is tricky in my case because of Spatialite's infuriating custom binary representation...)

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/439/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
427429265 MDExOlB1bGxSZXF1ZXN0MjY2MDM1Mzgy 424 Column types in inspected metadata russss 45057 closed 0     2 2019-03-31T18:46:33Z 2019-04-29T18:30:50Z 2019-04-29T18:30:46Z CONTRIBUTOR simonw/datasette/pulls/424

This PR does two things:

  • Adds the sqlite column type for each column to the inspected table info.
  • Stops binary columns from being rendered to HTML, unless a plugin handles it.

There's a bit more detail in the changeset descriptions.

These changes are intended as a precursor to a plugin which adds first-class support for Spatialite geographic primitives, and perhaps more useful geo-stuff.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/424/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
341235633 MDExOlB1bGxSZXF1ZXN0MjAxNDUxMzMy 345 Allow app names for `datasette publish heroku` russss 45057 closed 0     1 2018-07-14T13:12:34Z 2018-07-14T14:09:54Z 2018-07-14T14:04:44Z CONTRIBUTOR simonw/datasette/pulls/345

Lets you supply the -n parameter for Heroku deploys, which also lets you update existing Heroku deployments.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/345/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
324836533 MDExOlB1bGxSZXF1ZXN0MTg5MzE4NDUz 277 Refactor inspect logic russss 45057 closed 0     2 2018-05-21T08:49:31Z 2018-05-22T16:07:24Z 2018-05-22T14:03:07Z CONTRIBUTOR simonw/datasette/pulls/277

This pulls the logic for inspect out into a new file which makes it a bit easier to understand.

This was going to be the first part of an implementation for #276, but it seems like that might take a while so I'm going to PR a few bits of refactoring individually.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/277/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314455877 MDExOlB1bGxSZXF1ZXN0MTgxNzIzMzAz 209 Don't duplicate simple primary keys in the link column russss 45057 closed 0     6 2018-04-15T21:56:15Z 2018-04-18T08:40:37Z 2018-04-18T01:13:04Z CONTRIBUTOR simonw/datasette/pulls/209

When there's a simple (single-column) primary key, it looks weird to duplicate it in the link column.

This change removes the second PK column and treats the link column as if it were the PK column from a header/sorting perspective.

This might make it a bit more difficult to tell what the link for the row is, I'm not sure yet. I feel like the alternative is to change the link column to just have the text "view" or something, instead of repeating the PK. (I doubt it makes much more sense with compound PKs.)

Bonus change in this PR: fix urlencoding of links in the displayed HTML.

Before:

After:

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/209/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314340944 MDExOlB1bGxSZXF1ZXN0MTgxNjU0ODM5 208 Return HTTP 405 on InvalidUsage rather than 500 russss 45057 closed 0     0 2018-04-14T16:12:50Z 2018-04-14T18:00:39Z 2018-04-14T18:00:39Z CONTRIBUTOR simonw/datasette/pulls/208

This also stops it filling up the logs. This happens for HEAD requests at the moment - which perhaps should be handled better, but that's a different issue.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/208/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314319372 MDExOlB1bGxSZXF1ZXN0MTgxNjQyMTE0 205 Support filtering with units and more russss 45057 closed 0     3 2018-04-14T10:47:51Z 2018-04-14T15:24:04Z 2018-04-14T15:24:04Z CONTRIBUTOR simonw/datasette/pulls/205

The first commit: * Adds units to exported JSON * Adds units key to metadata skeleton * Adds some docs for units

The second commit adds filtering by units by the first method I mentioned in #203:

Try it here. I think it integrates pretty neatly.

The third commit adds support for registering custom units with Pint from metadata.json. Probably pretty niche, but I need decibels!

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/205/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314329002 MDExOlB1bGxSZXF1ZXN0MTgxNjQ3NzE3 207 Link foreign keys which don't have labels russss 45057 closed 0     1 2018-04-14T13:27:14Z 2018-04-14T15:00:00Z 2018-04-14T15:00:00Z CONTRIBUTOR simonw/datasette/pulls/207

This renders unlabeled FKs as simple links. I can't see why this would cause any major problems.

Also includes bonus fixes for two minor issues:

  • In foreign key link hrefs the primary key was escaped using HTML escaping rather than URL escaping. This broke some non-integer PKs.
  • Print tracebacks to console when handling 500 errors.
datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/207/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314323977 MDExOlB1bGxSZXF1ZXN0MTgxNjQ0ODA1 206 Fix sqlite error when loading rows with no incoming FKs russss 45057 closed 0     0 2018-04-14T12:08:17Z 2018-04-14T14:32:42Z 2018-04-14T14:24:25Z CONTRIBUTOR simonw/datasette/pulls/206

This fixes ERROR: conn=<sqlite3.Connection object at 0x10bbb9f10>, sql = 'select ', params = {'id': '1'} caused by an invalid query loading incoming FKs when none exist.

The error was ignored due to async but it still got printed to the console.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/206/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
314256802 MDExOlB1bGxSZXF1ZXN0MTgxNjAwOTI2 204 Initial units support russss 45057 closed 0     0 2018-04-13T21:32:49Z 2018-04-14T09:44:33Z 2018-04-14T03:32:54Z CONTRIBUTOR simonw/datasette/pulls/204

Add support for specifying units for a column in metadata.json and rendering them on display using pint.

Example table metadata: json "license_frequency": { "units": { "frequency": "Hz", "channel_width": "Hz", "height": "m", "antenna_height": "m", "azimuth": "degrees" } }

Example result

This works surprisingly well! I'd like to add support for using units when querying but this is PR is pretty usable as-is.

(Pint doesn't seem to support decibels though - it thinks they're decibytes - which is an annoying omission.)

(ref ticket #203)

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/204/reactions",
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
313785206 MDExOlB1bGxSZXF1ZXN0MTgxMjQ3NTY4 202 Raise 404 on nonexistent table URLs russss 45057 closed 0     2 2018-04-12T15:47:06Z 2018-04-13T19:22:56Z 2018-04-13T18:19:15Z CONTRIBUTOR simonw/datasette/pulls/202

Currently they just 500. Also cleaned the logic up a bit, I hope I didn't miss anything.

This is issue #184.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/202/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  
313494458 MDExOlB1bGxSZXF1ZXN0MTgxMDMzMDI0 200 Hide Spatialite system tables russss 45057 closed 0     3 2018-04-11T21:26:58Z 2018-04-12T21:34:48Z 2018-04-12T21:34:48Z CONTRIBUTOR simonw/datasette/pulls/200

They were getting on my nerves.

datasette 107914493 pull    
{
    "url": "https://api.github.com/repos/simonw/datasette/issues/200/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
0  

Advanced export

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

CSV options:

CREATE TABLE [issues] (
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [number] INTEGER,
   [title] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [state] TEXT,
   [locked] INTEGER,
   [assignee] INTEGER REFERENCES [users]([id]),
   [milestone] INTEGER REFERENCES [milestones]([id]),
   [comments] INTEGER,
   [created_at] TEXT,
   [updated_at] TEXT,
   [closed_at] TEXT,
   [author_association] TEXT,
   [pull_request] TEXT,
   [body] TEXT,
   [repo] INTEGER REFERENCES [repos]([id]),
   [type] TEXT
, [active_lock_reason] TEXT, [performed_via_github_app] TEXT, [reactions] TEXT, [draft] INTEGER, [state_reason] TEXT);
CREATE INDEX [idx_issues_repo]
                ON [issues] ([repo]);
CREATE INDEX [idx_issues_milestone]
                ON [issues] ([milestone]);
CREATE INDEX [idx_issues_assignee]
                ON [issues] ([assignee]);
CREATE INDEX [idx_issues_user]
                ON [issues] ([user]);
Powered by Datasette · Queries took 150.178ms · About: github-to-sqlite
  • Sort ascending
  • Sort descending
  • Facet by this
  • Hide this column
  • Show all columns
  • Show not-blank rows