home / github

Menu
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

11 rows where issue = 1497909798

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: user, author_association, reactions, created_at (date), updated_at (date)

id ▼ html_url issue_url node_id user created_at updated_at author_association body reactions issue performed_via_github_app
1352644262 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644262 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7am davidhaley 11729897 2022-12-13T16:49:31Z 2022-12-13T16:49:52Z NONE I may have found the reason. I don't think the `--root` option is taking effect. Visited: http://127.0.0.1:8001/-/permissions ![image](https://user-images.githubusercontent.com/11729897/207394127-59f8320f-3410-4ff8-869d-b19ab955d67c.png) {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1352644267 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644267 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7ar simonw 9599 2022-12-13T18:33:32Z 2022-12-13T18:33:32Z OWNER When you run `--root` you need to follow the special link that gets output to the console: ``` % datasette --root http://127.0.0.1:8001/-/auth-token?token=036d8055cc8000e9667f21c1dd08722a9358c066463873ad9566d23d88765c52 INFO: Started server process [53934] INFO: Waiting for application startup. INFO: Application startup complete. ``` That `/-/auth-token?...` link is the one that sets the cookie and lets you in. {"total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1352644270 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644270 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7au davidhaley 11729897 2022-12-14T00:05:16Z 2022-12-14T00:05:16Z NONE FYI @simonw, I don't see that message. ![image](https://user-images.githubusercontent.com/11729897/207471893-1ec5d4d0-81db-4eaa-ba40-adedcc7c9a32.png) {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1352644274 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644274 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7ay davidhaley 11729897 2022-12-14T14:19:24Z 2022-12-14T14:19:24Z NONE Hmm, it appears after I kill the process with `Ctrl+c`: ![image](https://user-images.githubusercontent.com/11729897/207619736-a49b2e97-c5d0-4e54-ad3c-3c3c279927c7.png) {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1352644276 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644276 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7a0 davidhaley 11729897 2022-12-14T14:53:53Z 2022-12-14T14:53:53Z NONE I don't have much experience with Python; however, I wonder if this print statement needs `flush=True`? https://github.com/simonw/datasette/blob/fdf7c27b5438f02153c3a7f8ad1b320e4b29e4f4/datasette/cli.py#L621 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1352644281 https://github.com/simonw/datasette/issues/1958#issuecomment-1352644281 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5Qn7a5 simonw 9599 2022-12-15T07:08:14Z 2022-12-15T07:08:14Z OWNER Thanks for the details write-up! This looks like a bug in Datasette itself when run with Docker. Moving this issue there. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1353977605 https://github.com/simonw/datasette/issues/1958#issuecomment-1353977605 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5QtA8F simonw 9599 2022-12-16T00:38:23Z 2022-12-16T00:38:23Z OWNER Confirmed, I just got the same result: ``` - % docker run datasetteproject/datasette pip install datasette-upload-csvs ~ % docker commit $(docker ps -lq) datasette-with-plugins sha256:8cde4a6357b9221d6f9e15887a314f2b4d9d1b87b517764d207ccbaec7c0a69f ~ % docker run -p 8001:8001 -v $(pwd):/mnt datasette-with-plugins datasette --root -p 8001 -h 0.0.0.0 INFO: Started server process [1] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://0.0.0.0:8001 (Press CTRL+C to quit) ^CINFO: Shutting down INFO: Waiting for application shutdown. INFO: Application shutdown complete. INFO: Finished server process [1] http://0.0.0.0:8001/-/auth-token?token=4bd70fdbca215ea55c874eaf889adf8c09f2a00231f7e5e6d0470f3176407a98 ``` Note how the auth-token URL is only displayed after you hit `Ctrl+C`! {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1354008688 https://github.com/simonw/datasette/issues/1958#issuecomment-1354008688 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5QtIhw simonw 9599 2022-12-16T00:45:40Z 2022-12-16T00:45:40Z OWNER The fix may just be to switch to `click.echo()`. https://click.palletsprojects.com/en/8.1.x/api/#click.echo {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1354019543 https://github.com/simonw/datasette/issues/1958#issuecomment-1354019543 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5QtLLX simonw 9599 2022-12-16T00:54:11Z 2022-12-16T00:54:11Z OWNER To test the fix, I did a fresh checkout of `simonw/datasette` and edited `Dockerfile` to look like this: ```dockerfile FROM python:3.11.0-slim-bullseye as build RUN apt-get update && \ apt-get install -y --no-install-recommends libsqlite3-mod-spatialite && \ apt clean && \ rm -rf /var/lib/apt && \ rm -rf /var/lib/dpkg/info/* RUN pip install https://github.com/simonw/datasette/archive/refs/heads/main.zip && \ find /usr/local/lib -name '__pycache__' | xargs rm -r && \ rm -rf /root/.cache/pip EXPOSE 8001 CMD ["datasette"] ``` Then I built it like this: ``` docker build -f Dockerfile -t datasette-pre-click . ``` And ran like this: ``` docker run -p 8001:8001 -v $(pwd):/mnt datasette-pre-click datasette --root -p 8001 -h 0.0.0.0 ``` This exhibited the same problem. Then I pushed a changed to branch and changed the line to: ``` RUN pip install https://github.com/simonw/datasette/archive/refs/heads/click-echo-root.zip && \ ``` Ran this: ``` docker build -f Dockerfile -t datasette-post-click . ``` And this: ``` docker run -p 8001:8001 -v $(pwd):/mnt datasette-post-click datasette --root -p 8001 -h 0.0.0.0 ``` It fixed the problem! ``` datasette % docker run -p 8001:8001 -v $(pwd):/mnt datasette-post-click datasette --root -p 8001 -h 0.0.0.0 http://0.0.0.0:8001/-/auth-token?token=6542dcf5c8f34f8d13f4af9ce728359c602469efb54029098562bd06c87ad26d INFO: Started server process [1] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://0.0.0.0:8001 (Press CTRL+C to quit) ``` {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1354023960 https://github.com/simonw/datasette/issues/1958#issuecomment-1354023960 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5QtMQY simonw 9599 2022-12-16T00:58:14Z 2022-12-16T00:58:19Z OWNER This is in the `0.63.x` branch now, ready to go out in a bug fix release. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  
1354025319 https://github.com/simonw/datasette/issues/1958#issuecomment-1354025319 https://api.github.com/repos/simonw/datasette/issues/1958 IC_kwDOBm6k_c5QtMln davidhaley 11729897 2022-12-16T00:59:12Z 2022-12-16T00:59:12Z NONE Awesome. Thank you @simonw. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} datasette --root running in Docker doesn't reliably show the magic URL 1497909798  

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 28.465ms · About: simonw/datasette-graphql