home / github

Menu
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

15 rows where issue = 1109808154

✎ 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
1017969452 https://github.com/simonw/datasette/issues/1608#issuecomment-1017969452 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rPss simonw 9599 2022-01-20T22:07:55Z 2022-01-20T22:07:55Z OWNER I think I want a banner at the top of the page making it obvious which version the documentation is talking about. This can be pretty low key for the current stable release, but should be visually more prominent for the `/latest/` branch and for older releases. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017970132 https://github.com/simonw/datasette/issues/1608#issuecomment-1017970132 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rP3U simonw 9599 2022-01-20T22:08:55Z 2022-01-20T22:08:55Z OWNER Might want to consider SEO here too - I want people from search engines to land on `/stable/`, I wonder if I should noindex or `rel=canonical` the other documentation versions? Not sure what best practices for that is. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017971905 https://github.com/simonw/datasette/issues/1608#issuecomment-1017971905 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rQTB simonw 9599 2022-01-20T22:11:40Z 2022-01-20T22:11:40Z OWNER Huh, I had forgotten I already have a banner on older versions: ![D1A65C68-9A37-4FA2-80C4-534739A9D292](https://user-images.githubusercontent.com/9599/150430410-1e22e23f-ed27-4271-89ff-63467eb5f466.jpeg) {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017975322 https://github.com/simonw/datasette/issues/1608#issuecomment-1017975322 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rRIa simonw 9599 2022-01-20T22:17:01Z 2022-01-20T22:27:07Z OWNER Turns out that banner is something that ReadTheDocs implemented - I found it using GitHub code search, it's produced by this piece of JavaScript: https://github.com/readthedocs/readthedocs.org/blob/0852d7c10d725d954d3e9a93513171baa1116d9f/readthedocs/core/static-src/core/js/doc-embed/version-compare.js#L13-L21 ```javascript function init(data) { var rtd = rtddata.get(); /// Out of date message if (data.is_highest) { return; } var currentURL = window.location.pathname.replace(rtd['version'], data.slug); var warning = $( '<div class="admonition warning"> ' + '<p class="first admonition-title">Note</p> ' + '<p class="last"> ' + 'You are not reading the most recent version of this documentation. ' + '<a href="#"></a> is the latest version available.' + '</p>' + '</div>'); warning .find('a') .attr('href', currentURL) .text(data.slug); var body = $("div.body"); if (!body.length) { body = $("div.document"); } body.prepend(warning); } ``` And here's where that module is called from the rest of their code: https://github.com/readthedocs/readthedocs.org/blob/bc3e147770e5740314a8e8c33fec5d111c850498/readthedocs/core/static-src/core/js/doc-embed/footer.js#L66-L86 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017981599 https://github.com/simonw/datasette/issues/1608#issuecomment-1017981599 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rSqf simonw 9599 2022-01-20T22:26:32Z 2022-01-20T22:26:32Z OWNER I'm tempted to imitate their JavaScript but check for `/latest/` in the URL and use that to append a similar message warning about this being the documentation for the in-development version. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017988556 https://github.com/simonw/datasette/issues/1608#issuecomment-1017988556 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rUXM simonw 9599 2022-01-20T22:37:51Z 2022-01-20T22:37:51Z OWNER Here's a jQuery recipe that seems to do the right thing: ```javascript jQuery(function ($) { // If this is a /latest/ doc page, show banner linking to /stable/ if (!/\/latest\//.test(location.pathname)) { return; } var stableUrl = location.pathname.replace("/latest/", "/stable/"); // Check it's not a 404 fetch(stableUrl, { method: "HEAD" }).then((response) => { if (response.status == 200) { var warning = $( `<div class="admonition warning"> <p class="first admonition-title">Note</p> <p class="last"> This documentation covers the <strong>development version</strong> of Datasette.</p> <p>See <a href="${stableUrl}">this page</a> for the current stable release. </p> </div>` ); warning.find("a").attr("href", stableUrl); var body = $("div.body"); if (!body.length) { body = $("div.document"); } body.prepend(warning); } }); }); ``` {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017993482 https://github.com/simonw/datasette/issues/1608#issuecomment-1017993482 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rVkK astrojuanlu 316517 2022-01-20T22:46:16Z 2022-01-20T22:46:16Z NONE Or you can use https://sphinx-version-warning.readthedocs.io/! 😄 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017994925 https://github.com/simonw/datasette/issues/1608#issuecomment-1017994925 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rV6t simonw 9599 2022-01-20T22:48:43Z 2022-01-20T22:54:02Z OWNER https://sphinx-version-warning.readthedocs.io/ looks like it can show a banner for "You are looking at v0.36 but you should be looking at 0.40" but doesn't hand the case I need here which is "you are looking at /latest/ but you should be looking at /stable/". Just shipped my fix here: https://docs.datasette.io/en/latest/ <img width="994" alt="image" src="https://user-images.githubusercontent.com/9599/150434433-e2f0d472-77a8-430b-88e5-f22e2c6e8ef0.png"> {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1017998993 https://github.com/simonw/datasette/issues/1608#issuecomment-1017998993 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rW6R simonw 9599 2022-01-20T22:56:00Z 2022-01-20T22:56:00Z OWNER > https://sphinx-version-warning.readthedocs.io/ looks like it can show a banner for "You are looking at v0.36 but you should be looking at 0.40" but doesn't hand the case I need here which is "you are looking at /latest/ but you should be looking at /stable/". Correction! That tool DOES support that, as can be seen in their example configuration for their own documentation: https://github.com/humitos/sphinx-version-warning/blob/a82156c2ea08e5feab406514d0ccd9d48a345f48/docs/conf.py#L32-L38 ```python versionwarning_messages = { 'latest': 'This is a custom message only for version "latest" of this documentation.', } versionwarning_admonition_type = 'tip' versionwarning_banner_title = 'Tip' versionwarning_body_selector = 'div[itemprop="articleBody"]' ``` {"total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1018017637 https://github.com/simonw/datasette/issues/1608#issuecomment-1018017637 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c48rbdl simonw 9599 2022-01-20T23:27:59Z 2022-01-20T23:27:59Z OWNER Got a couple of TILs out of this: - [Promoting the stable version of the documentation using rel=canonical](https://til.simonwillison.net/readthedocs/documentation-seo-canonical) - [Linking from /latest/ to /stable/ on Read The Docs](https://til.simonwillison.net/readthedocs/link-from-latest-to-stable) {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1484268146 https://github.com/simonw/datasette/issues/1608#issuecomment-1484268146 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c5YeCJy simonw 9599 2023-03-26T23:23:22Z 2023-03-26T23:23:22Z OWNER This broke when I upgraded to the Furo theme. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1484270067 https://github.com/simonw/datasette/issues/1608#issuecomment-1484270067 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c5YeCnz simonw 9599 2023-03-26T23:26:10Z 2023-03-26T23:27:42Z OWNER That didn't work, because `jQuery` isn't yet defined that high up the template. I should use `{% block scripts %}` instead: https://github.com/pradyunsg/furo/blob/05350110cf02d033ebb57147eb54e9371a63545a/src/furo/theme/furo/base.html#L89-L102 {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1484272313 https://github.com/simonw/datasette/issues/1608#issuecomment-1484272313 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c5YeDK5 simonw 9599 2023-03-26T23:36:17Z 2023-03-26T23:36:17Z OWNER Still getting this error: <img width="537" alt="image" src="https://user-images.githubusercontent.com/9599/227811947-a35a6758-cf94-4196-89ce-85ae2f48ab06.png"> Weird because `jQuery` is present in the devtools console. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1484274796 https://github.com/simonw/datasette/issues/1608#issuecomment-1484274796 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c5YeDxs simonw 9599 2023-03-26T23:38:18Z 2023-03-26T23:38:18Z OWNER ChatGPT prompt: > ``` > jQuery(function ($) { > // Show banner linking to /stable/ if this is a /latest/ page > if (!/\/latest\//.test(location.pathname)) { > return; > } > var stableUrl = location.pathname.replace("/latest/", "/stable/"); > // Check it's not a 404 > fetch(stableUrl, { method: "HEAD" }).then((response) => { > if (response.status == 200) { > var warning = $( > `<div class="admonition warning"> > <p class="first admonition-title">Note</p> > <p class="last"> > This documentation covers the <strong>development version</strong> of Datasette.</p> > <p>See <a href="${stableUrl}">this page</a> for the current stable release. > </p> > </div>` > ); > warning.find("a").attr("href", stableUrl); > $("article[role=main]").prepend(warning); > } > }); > }); > > Rewrite this to use vanilla JavaScript, no jQuery > ``` Got back: ```javascript document.addEventListener("DOMContentLoaded", function() { // Show banner linking to /stable/ if this is a /latest/ page if (!/\/latest\//.test(location.pathname)) { return; } var stableUrl = location.pathname.replace("/latest/", "/stable/"); // Check it's not a 404 fetch(stableUrl, { method: "HEAD" }).then((response) => { if (response.status === 200) { var warning = document.createElement("div"); warning.className = "admonition warning"; warning.innerHTML = ` <p class="first admonition-title">Note</p> <p class="last"> This documentation covers the <strong>development version</strong> of Datasette. </p> <p> See <a href="${stableUrl}">this page</a> for the current stable release. </p> `; var mainArticle = document.querySelector("article[role=main]"); mainArticle.insertBefore(warning, mainArticle.firstChild); } }); }); ``` {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  
1484276946 https://github.com/simonw/datasette/issues/1608#issuecomment-1484276946 https://api.github.com/repos/simonw/datasette/issues/1608 IC_kwDOBm6k_c5YeETS simonw 9599 2023-03-26T23:41:11Z 2023-03-26T23:41:11Z OWNER It's working again now: https://docs.datasette.io/en/latest/sql_queries.html {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} Documentation should clarify /stable/ vs /latest/ 1109808154  

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