Title: Argument Clinic's `[python input]` blocks do not support empty lines in comments · Issue #128152 · python/cpython · GitHub
Open Graph Title: Argument Clinic's `[python input]` blocks do not support empty lines in comments · Issue #128152 · python/cpython
X Title: Argument Clinic's `[python input]` blocks do not support empty lines in comments · Issue #128152 · python/cpython
Description: Bug report Bug description: The following is not a valid Python input clinic but should be: /*[python input] # Line 1 # # Line 3 [python start generated code]*/ This results in an assertion error: $ python ./Tools/clinic/clinic.py --forc...
Open Graph Description: Bug report Bug description: The following is not a valid Python input clinic but should be: /*[python input] # Line 1 # # Line 3 [python start generated code]*/ This results in an assertion error: ...
X Description: Bug report Bug description: The following is not a valid Python input clinic but should be: /*[python input] # Line 1 # # Line 3 [python start generated code]*/ This results in an assertion error: ...
Opengraph URL: https://github.com/python/cpython/issues/128152
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Argument Clinic's `[python input]` blocks do not support empty lines in comments","articleBody":"# Bug report\n\n### Bug description:\n\nThe following is not a valid Python input clinic but should be:\n\n```C\n/*[python input]\n# Line 1\n#\n# Line 3\n[python start generated code]*/\n```\n\nThis results in an assertion error:\n\n```sh\n$ python ./Tools/clinic/clinic.py --force --make --exclude Lib/test/clinic.test.c --srcdir .\nTraceback (most recent call last):\n File \"/lib/python/cpython/./Tools/clinic/clinic.py\", line 11, in \u003cmodule\u003e\n main()\n File \"/lib/python/cpython/Tools/clinic/libclinic/cli.py\", line 226, in main\n run_clinic(parser, args)\n File \"/lib/python/cpython/Tools/clinic/libclinic/cli.py\", line 205, in run_clinic\n parse_file(path,\n File \"/lib/python/cpython/Tools/clinic/libclinic/cli.py\", line 84, in parse_file\n cooked = clinic.parse(raw)\n ^^^^^^^^^^^^^^^^^\n File \"/lib/python/cpython/Tools/clinic/libclinic/app.py\", line 186, in parse\n for block in self.block_parser:\n ^^^^^^^^^^^^^^^^^\n File \"/lib/python/cpython/Tools/clinic/libclinic/block_parser.py\", line 132, in __next__\n return_value = self.parse_clinic_block(self.dsl_name)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/lib/python/cpython/Tools/clinic/libclinic/block_parser.py\", line 194, in parse_clinic_block\n line = self._line()\n ^^^^^^^^^^^^\n File \"/lib/python/cpython/Tools/clinic/libclinic/block_parser.py\", line 155, in _line\n self.language.parse_line(line)\n File \"/lib/python/cpython/Tools/clinic/libclinic/clanguage.py\", line 70, in parse_line\n self.cpp.writeline(line)\n File \"/lib/python/cpython/Tools/clinic/libclinic/cpp.py\", line 139, in writeline\n assert line\n ^^^^\nAssertionError\nmake: *** [Makefile:1055: clinic] Error 1\n```\n\n### CPython versions tested on:\n\nCPython main branch\n\n### Operating systems tested on:\n\n_No response_\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-128158\n* gh-128464\n* gh-128478\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/picnixz","@type":"Person","name":"picnixz"},"datePublished":"2024-12-21T10:50:31.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":6},"url":"https://github.com/128152/cpython/issues/128152"}
| 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:d7047ec3-909c-2a10-fd38-c8b4982efb02 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E1FC:1672C1:DCB45F:120E8E5:696B03BE |
| html-safe-nonce | baae66a90d639fcb5def046d0a7f69af990e5ecb8c60b46fce06240a60023fb5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMUZDOjE2NzJDMTpEQ0I0NUY6MTIwRThFNTo2OTZCMDNCRSIsInZpc2l0b3JfaWQiOiI2Mjc0NDkxMDM1NTY4MjQzNjQ2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 3428df1da69d55070ea963aa7a91ac8f021852e306b7ba34578d3f5f860142f4 |
| hovercard-subject-tag | issue:2753888268 |
| 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/128152/issue_layout |
| twitter:image | https://opengraph.githubassets.com/1ad20892d94b299ec19559dfca5fe0d1394828726a388d2648726c13bf5b71d2/python/cpython/issues/128152 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/1ad20892d94b299ec19559dfca5fe0d1394828726a388d2648726c13bf5b71d2/python/cpython/issues/128152 |
| og:image:alt | Bug report Bug description: The following is not a valid Python input clinic but should be: /*[python input] # Line 1 # # Line 3 [python start generated code]*/ This results in an assertion error: ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | picnixz |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| 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 | 82560a55c6b2054555076f46e683151ee28a19bc |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width