Title: token module documentation is incomplete · Issue #130587 · python/cpython · GitHub
Open Graph Title: token module documentation is incomplete · Issue #130587 · python/cpython
X Title: token module documentation is incomplete · Issue #130587 · python/cpython
Description: Documentation The token docs use a generated list of tokens, with short blurbs for the OP tokens but nothing for the other (more interesting) ones. Some tokens (COMMENT, NL, etc.) have secondary, hand-written definitions. However, these ...
Open Graph Description: Documentation The token docs use a generated list of tokens, with short blurbs for the OP tokens but nothing for the other (more interesting) ones. Some tokens (COMMENT, NL, etc.) have secondary, h...
X Description: Documentation The token docs use a generated list of tokens, with short blurbs for the OP tokens but nothing for the other (more interesting) ones. Some tokens (COMMENT, NL, etc.) have secondary, h...
Opengraph URL: https://github.com/python/cpython/issues/130587
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"token module documentation is incomplete","articleBody":"# Documentation\n\nThe [`token` docs](https://docs.python.org/3/library/token.html) use a generated list of tokens, with short blurbs for the OP tokens but nothing for the other (more interesting) ones.\nSome tokens (`COMMENT`, `NL`, etc.) have secondary, hand-written definitions. However, these are excluded from the index; [links](https://docs.python.org/3/library/token.html#token.COMMENT) go to the empty entries.\n\nI propose adding hand-written prose for the non-OP tokens, and changing the automation to *check* the entries rather than generate them.\nFor the OP tokens, generating the docs is the correct thing to do, but the list can be more compact since they're all the same.\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-130588\n* gh-131465\n* gh-132304\n* gh-132327\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/encukou","@type":"Person","name":"encukou"},"datePublished":"2025-02-26T15:37:02.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/130587/cpython/issues/130587"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b6fce1d9-51f0-1b7b-c398-06f7cc0b734d |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A544:1B1D69:1EAF11C:2A38668:696AB456 |
| html-safe-nonce | 6f750afca558f0bd13611db8ab65787288083aac7d5a72350ea105eb00cce78a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNTQ0OjFCMUQ2OToxRUFGMTFDOjJBMzg2Njg6Njk2QUI0NTYiLCJ2aXNpdG9yX2lkIjoiNzI2OTA0NDM1MjgwMzU4MzA2MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | ddbe2025e7d747dbc58afce10865c693dc29111b1a988bfe4d5b000299077d01 |
| hovercard-subject-tag | issue:2882028605 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/130587/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e2077717da89c9f7e2116063a087e4afd6bb9429afc1052b8630e27a0c1205f3/python/cpython/issues/130587 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e2077717da89c9f7e2116063a087e4afd6bb9429afc1052b8630e27a0c1205f3/python/cpython/issues/130587 |
| og:image:alt | Documentation The token docs use a generated list of tokens, with short blurbs for the OP tokens but nothing for the other (more interesting) ones. Some tokens (COMMENT, NL, etc.) have secondary, h... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | encukou |
| hostname | github.com |
| expected-hostname | github.com |
| None | 4fa1799b6a53c2d30c950d74230781bef9e7f61138c72c7727e4b83f0743752b |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 41f276818bd204c4a30a0281fb3c576298d9474c |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width