home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

9 rows where issue = 1294641696 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

  • Ability to set a custom favicon · 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
1175396774 https://github.com/simonw/datasette/issues/1767#issuecomment-1175396774 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDyGm simonw 9599 2022-07-05T18:56:43Z 2022-07-05T18:56:43Z OWNER

Based on https://github.com/python/cpython/blob/3.11/Lib/imghdr.py I'm tempted to say that if the file starts with b'\211PNG\r\n\032\n' then it's a PNG, if it starts with b'GIF8 then it's a GIF, anything else I assume an ICO.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175391899 https://github.com/simonw/datasette/issues/1767#issuecomment-1175391899 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDw6b simonw 9599 2022-07-05T18:53:07Z 2022-07-05T18:53:07Z OWNER

https://www.w3.org/2005/10/howto-favicon suggests that it only needs to be able to identify PNG, GIF or ICO.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175388492 https://github.com/simonw/datasette/issues/1767#issuecomment-1175388492 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDwFM simonw 9599 2022-07-05T18:51:26Z 2022-07-05T18:51:26Z OWNER

I could vendor the necessary parts of imghdr - it's pretty tiny: https://github.com/python/cpython/blob/3.11/Lib/imghdr.py

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175385249 https://github.com/simonw/datasette/issues/1767#issuecomment-1175385249 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDvSh simonw 9599 2022-07-05T18:49:52Z 2022-07-05T18:49:52Z OWNER

I could use the imghdr standard library module, but frustratingly it's marked as deprecated in Python 3.11! https://docs.python.org/3/library/imghdr.html

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175381896 https://github.com/simonw/datasette/issues/1767#issuecomment-1175381896 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDueI simonw 9599 2022-07-05T18:48:14Z 2022-07-05T18:48:50Z OWNER

Annoyingly it looks like the standard library mimetypes module only uses filenames as the clue, it doesn't look at the bytes themselves.

I'm using that here: https://github.com/simonw/datasette/blob/9f1eb0d4eac483b953392157bd9fd6cc4df37de7/datasette/utils/asgi.py#L261-L277

https://pypi.org/project/python-magic/ can inspect files, but I don't want to add a whole new dependency just for this one feature.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175378678 https://github.com/simonw/datasette/issues/1767#issuecomment-1175378678 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDtr2 simonw 9599 2022-07-05T18:45:23Z 2022-07-05T18:45:23Z OWNER

The content type thing is a bit weird because usually I'd base that on the file extension, but here the favicon.ico file extension doesn't necessarily reflect if the image itself is a PNG or some other thing.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175377618 https://github.com/simonw/datasette/issues/1767#issuecomment-1175377618 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDtbS simonw 9599 2022-07-05T18:44:08Z 2022-07-05T18:44:08Z OWNER

Loading it using the existing templating system would be better I think, since that way both custom installations AND plugins could influence the favicon in the same way that they influence the templates.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175377125 https://github.com/simonw/datasette/issues/1767#issuecomment-1175377125 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDtTl simonw 9599 2022-07-05T18:43:35Z 2022-07-05T18:43:35Z OWNER

I think I want this to be a default feature, not a plugin.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  
1175376866 https://github.com/simonw/datasette/issues/1767#issuecomment-1175376866 https://api.github.com/repos/simonw/datasette/issues/1767 IC_kwDOBm6k_c5GDtPi simonw 9599 2022-07-05T18:43:12Z 2022-07-05T18:43:12Z OWNER

Some options:

  • Allow favicon path to be set in metadata.yml somehow, or via a --setting
  • Teach Datasette to check for templates/favicon.ico and fall back to the default static/favicon.png if that file does not exist
  • Document how to over-ride the favicon using the existing --static mechanism (if that's even possible)
  • Outsource this to a new plugin

Note that I need a way to set the content_type correctly too.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
Ability to set a custom favicon 1294641696  

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