Title: bpo-38870: Don't start generated output with newlines by isidentical · Pull Request #19636 · python/cpython · GitHub
Open Graph Title: bpo-38870: Don't start generated output with newlines by isidentical · Pull Request #19636 · python/cpython
X Title: bpo-38870: Don't start generated output with newlines by isidentical · Pull Request #19636 · python/cpython
Description: This is a small nit that can cause too much unnecessary nose when using ast.unparse for comparisons. Examples $ python Python 3.9.0a5+ (heads/master:5565c30f0b, Apr 17 2020, 16:56:39) [GCC 7.5.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import ast >>> ast.unparse(ast.parse("compile")) '\ncompile' >>> ast.unparse(ast.parse("compile")) == "compile" False >>> ast.unparse(ast.parse("class compile: pass")) '\n\nclass compile():\n pass' https://bugs.python.org/issue38870
Open Graph Description: This is a small nit that can cause too much unnecessary nose when using ast.unparse for comparisons. Examples $ python Python 3.9.0a5+ (heads/master:5565c30f0b, Apr 17 2020, 16:56:39) [GCC 7.5.0]...
X Description: This is a small nit that can cause too much unnecessary nose when using ast.unparse for comparisons. Examples $ python Python 3.9.0a5+ (heads/master:5565c30f0b, Apr 17 2020, 16:56:39) [GCC 7.5.0]...
Opengraph URL: https://github.com/python/cpython/pull/19636
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:246d75eb-f1bf-98ac-15c8-ea90c771b892 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | DC52:3641B1:1C67EC:278698:696A6401 |
| html-safe-nonce | 7340d56c5c2676bac441d84131beb9bea67f780c53595d087176af0c73581ef9 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQzUyOjM2NDFCMToxQzY3RUM6Mjc4Njk4OjY5NkE2NDAxIiwidmlzaXRvcl9pZCI6Ijg5ODkzNzkyOTU0NjQ1NDczMjkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 391e31fb873d5d0d2d9624c42e0e9c4e25009d5b5c687eb482ec24735d528422 |
| hovercard-subject-tag | pull_request:406936738 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,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/python/cpython/pull/19636/files |
| twitter:image | https://avatars.githubusercontent.com/u/47358913?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/47358913?s=400&v=4 |
| og:image:alt | This is a small nit that can cause too much unnecessary nose when using ast.unparse for comparisons. Examples $ python Python 3.9.0a5+ (heads/master:5565c30f0b, Apr 17 2020, 16:56:39) [GCC 7.5.0]... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9b7735a184970dd9333b2cbe036c8f3c0a9108c64aaa93827c5a64fc70993392 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| 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 full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 87cbd411c2982752221b5751d583a515b23bf5fa |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width