| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:e7a69f45-64bc-e060-eed7-5d18b7699f50 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 9A62:29B8E2:241A608:3137F4E:696AD49D |
| html-safe-nonce | bac4508ff56e17c79647552541b029674abbddac534c11a821d687a6cd86266f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QTYyOjI5QjhFMjoyNDFBNjA4OjMxMzdGNEU6Njk2QUQ0OUQiLCJ2aXNpdG9yX2lkIjoiNTA0MTk3MzcxOTU2MzE2Mjc4MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | cf76df020c45bbf8c709a782bbe8a07003bb208c69be6824e6c1d71c71fcfca7 |
| hovercard-subject-tag | pull_request:405771811 |
| 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 | ///pull_requests/show/files |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/python/cpython/pull/19612/files |
| twitter:image | https://avatars.githubusercontent.com/u/12621235?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/12621235?s=400&v=4 |
| og:image:alt | By attempting to avoid backslashes in f-string expressions.
We also now proactively raise errors for some backslashes we can't
avoid while unparsing FormattedValues
https://bugs.python.org/is... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | c785f4ce187e9e7331257791b36ddee01625bb8e292a9b4fe2c16d4c006abf5d |
| 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 | c718a376fcf780eb22089171adb84a543f660bf7 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| Skip to content | https://github.com/python/cpython/pull/19612/files#start-of-content |
|
| https://github.com/ |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F19612%2Ffiles |
| GitHub CopilotWrite better code with AI | https://github.com/features/copilot |
| GitHub SparkBuild and deploy intelligent apps | https://github.com/features/spark |
| GitHub ModelsManage and compare prompts | https://github.com/features/models |
| MCP RegistryNewIntegrate external tools | https://github.com/mcp |
| ActionsAutomate any workflow | https://github.com/features/actions |
| CodespacesInstant dev environments | https://github.com/features/codespaces |
| IssuesPlan and track work | https://github.com/features/issues |
| Code ReviewManage code changes | https://github.com/features/code-review |
| GitHub Advanced SecurityFind and fix vulnerabilities | https://github.com/security/advanced-security |
| Code securitySecure your code as you build | https://github.com/security/advanced-security/code-security |
| Secret protectionStop leaks before they start | https://github.com/security/advanced-security/secret-protection |
| Why GitHub | https://github.com/why-github |
| Documentation | https://docs.github.com |
| Blog | https://github.blog |
| Changelog | https://github.blog/changelog |
| Marketplace | https://github.com/marketplace |
| View all features | https://github.com/features |
| Enterprises | https://github.com/enterprise |
| Small and medium teams | https://github.com/team |
| Startups | https://github.com/enterprise/startups |
| Nonprofits | https://github.com/solutions/industry/nonprofits |
| App Modernization | https://github.com/solutions/use-case/app-modernization |
| DevSecOps | https://github.com/solutions/use-case/devsecops |
| DevOps | https://github.com/solutions/use-case/devops |
| CI/CD | https://github.com/solutions/use-case/ci-cd |
| View all use cases | https://github.com/solutions/use-case |
| Healthcare | https://github.com/solutions/industry/healthcare |
| Financial services | https://github.com/solutions/industry/financial-services |
| Manufacturing | https://github.com/solutions/industry/manufacturing |
| Government | https://github.com/solutions/industry/government |
| View all industries | https://github.com/solutions/industry |
| View all solutions | https://github.com/solutions |
| AI | https://github.com/resources/articles?topic=ai |
| Software Development | https://github.com/resources/articles?topic=software-development |
| DevOps | https://github.com/resources/articles?topic=devops |
| Security | https://github.com/resources/articles?topic=security |
| View all topics | https://github.com/resources/articles |
| Customer stories | https://github.com/customer-stories |
| Events & webinars | https://github.com/resources/events |
| Ebooks & reports | https://github.com/resources/whitepapers |
| Business insights | https://github.com/solutions/executive-insights |
| GitHub Skills | https://skills.github.com |
| Documentation | https://docs.github.com |
| Customer support | https://support.github.com |
| Community forum | https://github.com/orgs/community/discussions |
| Trust center | https://github.com/trust-center |
| Partners | https://github.com/partners |
| GitHub SponsorsFund open source developers | https://github.com/sponsors |
| Security Lab | https://securitylab.github.com |
| Maintainer Community | https://maintainers.github.com |
| Accelerator | https://github.com/accelerator |
| Archive Program | https://archiveprogram.github.com |
| Topics | https://github.com/topics |
| Trending | https://github.com/trending |
| Collections | https://github.com/collections |
| Enterprise platformAI-powered developer platform | https://github.com/enterprise |
| GitHub Advanced SecurityEnterprise-grade security features | https://github.com/security/advanced-security |
| Copilot for BusinessEnterprise-grade AI features | https://github.com/features/copilot/copilot-business |
| Premium SupportEnterprise-grade 24/7 support | https://github.com/premium-support |
| Pricing | https://github.com/pricing |
| Search syntax tips | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
| documentation | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F19612%2Ffiles |
|
Sign up
| https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python%2Fcpython |
| Reload | https://github.com/python/cpython/pull/19612/files |
| Reload | https://github.com/python/cpython/pull/19612/files |
| Reload | https://github.com/python/cpython/pull/19612/files |
|
python
| https://github.com/python |
| cpython | https://github.com/python/cpython |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
|
Notifications
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Fork
33.9k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Star
71.1k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Code
| https://github.com/python/cpython |
|
Issues
5k+
| https://github.com/python/cpython/issues |
|
Pull requests
2.1k
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
31
| https://github.com/python/cpython/projects |
|
Security
Uh oh!
There was an error while loading. Please reload this page.
| https://github.com/python/cpython/security |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
|
Insights
| https://github.com/python/cpython/pulse |
|
Code
| https://github.com/python/cpython |
|
Issues
| https://github.com/python/cpython/issues |
|
Pull requests
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
| https://github.com/python/cpython/projects |
|
Security
| https://github.com/python/cpython/security |
|
Insights
| https://github.com/python/cpython/pulse |
| Sign up for GitHub
| https://github.com/signup?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| terms of service | https://docs.github.com/terms |
| privacy statement | https://docs.github.com/privacy |
| Sign in | https://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| isidentical | https://github.com/isidentical |
| python:master | https://github.com/python/cpython/tree/master |
| hauntsaninja:astunparse | https://github.com/hauntsaninja/cpython/tree/astunparse |
|
Conversation
73
| https://github.com/python/cpython/pull/19612 |
|
Commits
32
| https://github.com/python/cpython/pull/19612/commits |
|
Checks
0
| https://github.com/python/cpython/pull/19612/checks |
|
Files changed
| https://github.com/python/cpython/pull/19612/files |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
|
bpo-28002: Roundtrip f-strings with ast.unparse better
| https://github.com/python/cpython/pull/19612/files#top |
|
Show all changes
32 commits
| https://github.com/python/cpython/pull/19612/files |
|
cc318ee
bpo-28002: Roundtrip f-strings with ast.unparse better
Apr 19, 2020
| https://github.com/python/cpython/pull/19612/commits/cc318ee7a9481b99e461107e673225011ba12457 |
|
4743d8d
Update Lib/ast.py
hauntsaninja May 21, 2020
| https://github.com/python/cpython/pull/19612/commits/4743d8df71704cf735ed91d13a2c5d2897f1a2cb |
|
98878ba
_Unparser: make avoid_backslashes keyword only
May 22, 2020
| https://github.com/python/cpython/pull/19612/commits/98878ba2dcba96717030657daab966634970916d |
|
a0a7b26
test_unparse: add test_fstring to run_always_files
May 22, 2020
| https://github.com/python/cpython/pull/19612/commits/a0a7b260bb33787ca77bd9fab20372c98d4b357e |
|
0c95e56
unparse fstrings: improve cosmetics by escaping whitespace
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/0c95e56657cd27579328fd2c370f0ad7a76c7fd0 |
|
ac49be1
unparse: add another test case
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/ac49be13d85b435a5ab2c022d971fdccfbcc4f5e |
|
714a269
unparse: fix final quote escaping issues
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/714a2697588228b608843216cd945a93c5534808 |
|
85521c0
unparse: simplify, share code with docstring writing
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/85521c0a27e3305bdc2f2efe880be90e7341d2b5 |
|
106cdd2
Merge remote-tracking branch 'upstream/master' into astunparse
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/106cdd25d3300ba2904966620c03ce2e3a7f87d7 |
|
4e4a4b4
remove comment
Jun 3, 2020
| https://github.com/python/cpython/pull/19612/commits/4e4a4b49d1c11fbb1857bb4bb55078509750eee7 |
|
91430f5
reduce assignments to qts
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/91430f5f2fcdf331ff38bf0279cb0b9f44e06115 |
|
81ff3cb
use join instead of multiple replace
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/81ff3cbbba73e57969131989127e6cce198ca7fe |
|
bd05428
use write_str_avoiding_backslashes for docstrings
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/bd054287a70c04c13f5a483837647fe919d2d9ef |
|
cd2c107
don't use replace for backslashes
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/cd2c1074571178188a9fc3c569b5d66615411d86 |
|
4a7037a
use isprintable
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/4a7037aa86c3d7a03b9c1e1c0ff0c6cb84b6ba9f |
|
228f0b3
fix comment
Jun 4, 2020
| https://github.com/python/cpython/pull/19612/commits/228f0b32257a64ac9f1c1b6b5cbeb5bb1402c7c2 |
|
debc3dd
Use American English
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/debc3dda6fb65c3faba043f2aa00911f7bee7c17 |
|
32d34e6
s/qts/possible_quotes/g
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/32d34e61bc84b02c9671ceb78811667884fb5377 |
|
1fdb075
Prefix undesrscore to avoid_backslashes
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/1fdb0752d14619ba531a3daaac17f06f810693d4 |
|
c3fd073
Rename value and val
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/c3fd073ce21ab5227d2e7a0f8f0da85e5859060b |
|
a3b48a0
Reformat string escaping
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/a3b48a03a2623dd73dd56e420f4ecacbe096ac80 |
|
84485ab
Add a comment to visit_JoinedStr
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/84485abd9cd703ab381a45cc10731fe789971710 |
|
4f32cf0
Fix line lengths
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/4f32cf0f9eb3aa380654f690d754779f7e8e6932 |
|
d31b376
Update comment for variable name change
Jun 7, 2020
| https://github.com/python/cpython/pull/19612/commits/d31b376bc85dded9d059259737b204e544707d07 |
|
428fab7
move variable from start of __init__ to end
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/428fab735b5c8c0131363fc193fd4235d9d9e4ad |
|
ec38952
use global constants for quote types
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/ec3895270e76b02af833460218bac17cf774eeea |
|
b903dcf
make docstring explicit about returning a tuple
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/b903dcf4bcb9661ddae92ac4e3e5ad6a49f3756d |
|
007bb4a
use kw only args
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/007bb4aabf002e71d6024ae7480aae7e2b6b603c |
|
4c09b96
add escape_special_whitespace boolean argument
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/4c09b961d9b937029a84f4b846958b9c1e7e0a9a |
|
7735da5
use an inner function instead of a comprehension
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/7735da54bcd80a8e6b06c4a6c57306b47c986382 |
|
593b0d2
add to comment when falling back to repr
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/593b0d2af6f435e613909bcbd2bd2a3ffb26cd34 |
|
fc6166f
swap the order of the iterations to save a little effort
Oct 18, 2020
| https://github.com/python/cpython/pull/19612/commits/fc6166f79be4029dbe66f81c6fbfd11026027830 |
|
Clear filters
| https://github.com/python/cpython/pull/19612/files |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
|
ast.py
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
test_unparse.py
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
| Lib/ast.py | https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
View file
| https://github.com/hauntsaninja/cpython/blob/fc6166f79be4029dbe66f81c6fbfd11026027830/Lib/ast.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19612/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
|
| https://github.com/python/cpython/pull/19612/files#diff-abeeed217a24ce3c21e15c2e32e2f0886cea69986c2641455c1eefc983c1f977 |
| Lib/test/test_unparse.py | https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
View file
| https://github.com/hauntsaninja/cpython/blob/fc6166f79be4029dbe66f81c6fbfd11026027830/Lib/test/test_unparse.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19612/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
| Please reload this page | https://github.com/python/cpython/pull/19612/files |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com/python/cpython/pull/19612/files#diff-1393034a674edcc67802941e0e8cfa4966c9927ba9bde2cace103593140e3f89 |
|
| https://github.com |
| Terms | https://docs.github.com/site-policy/github-terms/github-terms-of-service |
| Privacy | https://docs.github.com/site-policy/privacy-policies/github-privacy-statement |
| Security | https://github.com/security |
| Status | https://www.githubstatus.com/ |
| Community | https://github.community/ |
| Docs | https://docs.github.com/ |
| Contact | https://support.github.com?tags=dotcom-footer |