home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

9 rows where issue = 634917088 sorted by updated_at descending

✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 1

  • simonw 9

issue 1

  • Example permissions plugin · 9 ✖

author_association 1

  • OWNER 9
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions issue performed_via_github_app
642420375 https://github.com/simonw/datasette/issues/818#issuecomment-642420375 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MjQyMDM3NQ== simonw 9599 2020-06-11T05:40:07Z 2020-06-11T05:40:07Z OWNER

https://github.com/simonw/datasette-permissions-sql is now released as a 0.1a here: https://pypi.org/project/datasette-permissions-sql/

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
642231871 https://github.com/simonw/datasette/issues/818#issuecomment-642231871 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MjIzMTg3MQ== simonw 9599 2020-06-10T20:11:50Z 2020-06-10T20:11:50Z OWNER

datasette-permissions-sql yaml plugins: datasette-permissions-sql: view-instance: |- select count(*) from users where admin = 1 and id = :id

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
642230499 https://github.com/simonw/datasette/issues/818#issuecomment-642230499 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MjIzMDQ5OQ== simonw 9599 2020-06-10T20:08:46Z 2020-06-10T20:09:26Z OWNER

What's a simple but useful plugin I could release that exercises this hook?

Ideally one which executes permission checks against the database somehow.

I could do a simplest-possible implementation of the idea in #801 (allow-by-query).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
642229899 https://github.com/simonw/datasette/issues/818#issuecomment-642229899 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MjIyOTg5OQ== simonw 9599 2020-06-10T20:07:36Z 2020-06-10T20:07:36Z OWNER

New policy in 9f236c4 dictates that this should be in Milestone 0.44 after all:

  • New plugin hooks should only be shipped if accompanied by a separate release of a non-demo plugin that uses them.
{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
641026230 https://github.com/simonw/datasette/issues/818#issuecomment-641026230 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MTAyNjIzMA== simonw 9599 2020-06-09T04:50:24Z 2020-06-09T04:50:24Z OWNER

I'm dropping this from the 0.44 milestone.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
641013524 https://github.com/simonw/datasette/issues/818#issuecomment-641013524 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MTAxMzUyNA== simonw 9599 2020-06-09T03:57:38Z 2020-06-09T04:00:24Z OWNER

Problem with that is it's more of a actor_from_request opportunity than permission_allowed. You could use actor_from_request to authenticate API clients from their Authorization: header, then use the regular "allow" blocks in metadata.json to actually assign their permissions.

The most interesting permissions plugin would be one that implements permissions against some kind of database schema, hence allowing admins to edit permissions through writable canned queries.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
641009744 https://github.com/simonw/datasette/issues/818#issuecomment-641009744 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MTAwOTc0NA== simonw 9599 2020-06-09T03:43:18Z 2020-06-09T03:43:18Z OWNER

datasette-auth-bearer perhaps?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
641009442 https://github.com/simonw/datasette/issues/818#issuecomment-641009442 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MTAwOTQ0Mg== simonw 9599 2020-06-09T03:41:55Z 2020-06-09T03:41:55Z OWNER

I want to build a plugin that does Authorization: Bearer xxx API key authentication.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  
640929693 https://github.com/simonw/datasette/issues/818#issuecomment-640929693 https://api.github.com/repos/simonw/datasette/issues/818 MDEyOklzc3VlQ29tbWVudDY0MDkyOTY5Mw== simonw 9599 2020-06-08T22:56:38Z 2020-06-08T22:56:38Z OWNER

https://datasette.readthedocs.io/en/latest/plugins.html#permission-allowed-datasette-actor-action-resource has a couple of examples now.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Example permissions plugin 634917088  

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