René's URL Explorer Experiment


Title: Segfault with lambda nested in comprehension · Issue #104377 · python/cpython · GitHub

Open Graph Title: Segfault with lambda nested in comprehension · Issue #104377 · python/cpython

X Title: Segfault with lambda nested in comprehension · Issue #104377 · python/cpython

Description: def gen_params(): def bound(): return [lambda: T for T in (T, [1])[1]] T = ... This segfaults on current main. Stack trace: Details (lldb) bt * thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x8...

Open Graph Description: def gen_params(): def bound(): return [lambda: T for T in (T, [1])[1]] T = ... This segfaults on current main. Stack trace: Details (lldb) bt * thread #1, queue = 'com.apple.main-thread', stop reas...

X Description: def gen_params(): def bound(): return [lambda: T for T in (T, [1])[1]] T = ... This segfaults on current main. Stack trace: Details (lldb) bt * thread #1, queue = 'com.apple.main-thread', s...

Opengraph URL: https://github.com/python/cpython/issues/104377

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Segfault with lambda nested in comprehension","articleBody":"```\r\ndef gen_params():\r\n    def bound():\r\n        return [lambda: T for T in (T, [1])[1]]\r\n    T = ...\r\n```\r\n\r\nThis segfaults on current main.\r\n\r\nStack trace:\r\n\r\n\u003cdetails\u003e\r\n\r\n```\r\n(lldb) bt\r\n* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x8)\r\n  * frame #0: 0x000000010008bcc4 python.exe`Py_TYPE(ob=0x0000000000000000) at object.h:204:16 [opt]\r\n    frame #1: 0x000000010008d414 python.exe`Py_IS_TYPE(ob=\u003cunavailable\u003e, type=0x00000001004210b8) at object.h:235:12 [opt]\r\n    frame #2: 0x000000010008e4c0 python.exe`_PyCode_ConstantKey(op=0x0000000000000000) at codeobject.c:2163:11 [opt]\r\n    frame #3: 0x000000010008e688 python.exe`_PyCode_ConstantKey(op=0x0000000102a42620) at codeobject.c:2225:24 [opt]\r\n    frame #4: 0x000000010016deec python.exe`_PyCompile_ConstCacheMergeOne(const_cache=0x000000010282d610, obj=0x000000016fdfefd8) at compile.c:6943:21 [opt]\r\n    frame #5: 0x0000000100149330 python.exe`makecode(umd=0x0000000102b04820, a=0x000000016fdff050, const_cache=0x000000010282d610, constslist=0x0000000102a419a0, maxdepth=5, nlocalsplus=2, code_flags=19, filename=0x00000001028761b0) at assemble.c:568:9 [opt]\r\n    frame #6: 0x000000010014905c python.exe`_PyAssemble_MakeCodeObject(umd=0x0000000102b04820, const_cache=0x000000010282d610, consts=0x0000000102a419a0, maxdepth=5, instrs=\u003cunavailable\u003e, nlocalsplus=2, code_flags=19, filename=0x00000001028761b0) at assemble.c:597:14 [opt]\r\n    frame #7: 0x000000010016f1ec python.exe`optimize_and_assemble_code_unit(u=0x0000000102b04600, const_cache=0x000000010282d610, code_flags=19, filename=0x00000001028761b0) at compile.c:7219:10 [opt]\r\n    frame #8: 0x000000010016f030 python.exe`optimize_and_assemble(c=0x000000010288b610, addNone=1) at compile.c:7246:12 [opt]\r\n    frame #9: 0x0000000100170f84 python.exe`compiler_function(c=0x000000010288b610, s=0x0000000102063f10, is_async=0) at compile.c:2166:10 [opt]\r\n    frame #10: 0x000000010016faec python.exe`compiler_visit_stmt(c=0x000000010288b610, s=0x0000000102063f10) at compile.c:3518:16 [opt]\r\n    frame #11: 0x0000000100170f40 python.exe`compiler_function(c=0x000000010288b610, s=0x0000000104008530, is_async=0) at compile.c:2158:9 [opt]\r\n    frame #12: 0x000000010016faec python.exe`compiler_visit_stmt(c=0x000000010288b610, s=0x0000000104008530) at compile.c:3518:16 [opt]\r\n    frame #13: 0x000000010016e438 python.exe`compiler_codegen(c=0x000000010288b610, mod=0x0000000104008590) at compile.c:1684:9 [opt]\r\n    frame #14: 0x000000010016dcdc python.exe`compiler_mod(c=0x000000010288b610, mod=\u003cunavailable\u003e) at compile.c:1702:9 [opt]\r\n    frame #15: 0x000000010016dbf8 python.exe`_PyAST_Compile(mod=0x0000000104008590, filename=\u003cunavailable\u003e, pflags=\u003cunavailable\u003e, optimize=\u003cunavailable\u003e, arena=\u003cunavailable\u003e) at compile.c:575:24 [opt]\r\n    frame #16: 0x00000001001bae6c python.exe`run_mod(mod=\u003cunavailable\u003e, filename=\u003cunavailable\u003e, globals=0x000000010282ce30, locals=0x000000010282ce30, flags=\u003cunavailable\u003e, arena=\u003cunavailable\u003e) at pythonrun.c:1707:24 [opt]\r\n    frame #17: 0x00000001001b9e90 python.exe`PyRun_InteractiveOneObjectEx(fp=0x0000000209e4b848, filename=0x00000001028761b0, flags=0x000000016fdff550) at pythonrun.c:260:9 [opt]\r\n    frame #18: 0x00000001001b9878 python.exe`_PyRun_InteractiveLoopObject(fp=0x0000000209e4b848, filename=0x00000001028761b0, flags=0x000000016fdff550) at pythonrun.c:137:15 [opt]\r\n    frame #19: 0x00000001001b96f8 python.exe`_PyRun_AnyFileObject(fp=0x0000000209e4b848, filename=0x00000001028761b0, closeit=0, flags=0x000000016fdff550) at pythonrun.c:72:15 [opt]\r\n    frame #20: 0x00000001001b9c64 python.exe`PyRun_AnyFileExFlags(fp=0x0000000209e4b848, filename=\u003cunavailable\u003e, closeit=0, flags=0x000000016fdff550) at pythonrun.c:104:15 [opt]\r\n    frame #21: 0x00000001001d8d78 python.exe`pymain_run_stdin(config=0x000000010054a2c0) at main.c:520:15 [opt]\r\n    frame #22: 0x00000001001d8444 python.exe`pymain_run_python(exitcode=0x000000016fdff5ec) at main.c:613:21 [opt]\r\n    frame #23: 0x00000001001d82ac python.exe`Py_RunMain at main.c:689:5 [opt]\r\n    frame #24: 0x00000001001d8524 python.exe`pymain_main(args=0x000000016fdff650) at main.c:719:12 [opt]\r\n    frame #25: 0x00000001001d8568 python.exe`Py_BytesMain(argc=\u003cunavailable\u003e, argv=\u003cunavailable\u003e) at main.c:743:12 [opt]\r\n    frame #26: 0x0000000100003e94 python.exe`main(argc=\u003cunavailable\u003e, argv=\u003cunavailable\u003e) at python.c:15:12 [opt]\r\n    frame #27: 0x000000010086108c dyld`start + 520\r\n```\r\n\r\n\u003c/details\u003e\r\n\r\nI got crashes here at some point too while working on PEP 695; I think it means there's something wrong with how the cellvars/freevars are tracked.\r\n\r\ncc @carljm.\r\n\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-104394\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/JelleZijlstra","@type":"Person","name":"JelleZijlstra"},"datePublished":"2023-05-11T01:27:13.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/104377/cpython/issues/104377"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:f50f1d42-6a9f-fde8-ef7a-780011689948
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idCC60:D0F38:3F0AFF:5700AA:696A02A7
html-safe-noncebade759e1bff88e80279d748b665c3de05550640bf66d4b619af702efa983f99
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQzYwOkQwRjM4OjNGMEFGRjo1NzAwQUE6Njk2QTAyQTciLCJ2aXNpdG9yX2lkIjoiNDk4NzYwNjk0NTQ5MzU0OTczNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac02aa59da33b4ec8e9f30caab9358a2722b7ae5d1f68060bbcb43eef4cc13a49c
hovercard-subject-tagissue:1704852282
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/104377/issue_layout
twitter:imagehttps://opengraph.githubassets.com/cf7d186f46437b67b6e64218915f0a79171d35a01e1266eec1793dea824ad581/python/cpython/issues/104377
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/cf7d186f46437b67b6e64218915f0a79171d35a01e1266eec1793dea824ad581/python/cpython/issues/104377
og:image:altdef gen_params(): def bound(): return [lambda: T for T in (T, [1])[1]] T = ... This segfaults on current main. Stack trace: Details (lldb) bt * thread #1, queue = 'com.apple.main-thread', stop reas...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameJelleZijlstra
hostnamegithub.com
expected-hostnamegithub.com
None578c119ff0247c8b2f2491fbf4fc0395cdf909d4df66598cebdc96ddfc4418dc
turbo-cache-controlno-preview
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release671c2f67171dbced24284331f3133a613d08c366
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/issues/104377#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fissues%2F104377
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://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%2Fissues%2F104377
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%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/issues/104377
Reloadhttps://github.com/python/cpython/issues/104377
Reloadhttps://github.com/python/cpython/issues/104377
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/issues/104377
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 pagehttps://github.com/python/cpython/issues/104377
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
New issuehttps://github.com/login?return_to=https://github.com/python/cpython/issues/104377
New issuehttps://github.com/login?return_to=https://github.com/python/cpython/issues/104377
#104394https://github.com/python/cpython/pull/104394
Segfault with lambda nested in comprehensionhttps://github.com/python/cpython/issues/104377#top
#104394https://github.com/python/cpython/pull/104394
https://github.com/carljm
release-blockerhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22release-blocker%22
type-bugAn unexpected behavior, bug, or errorhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22type-bug%22
https://github.com/JelleZijlstra
https://github.com/JelleZijlstra
JelleZijlstrahttps://github.com/JelleZijlstra
on May 11, 2023https://github.com/python/cpython/issues/104377#issue-1704852282
@carljmhttps://github.com/carljm
gh-104377: fix cell in comprehension that is free in outer scope #104394https://github.com/python/cpython/pull/104394
carljmhttps://github.com/carljm
release-blockerhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22release-blocker%22
type-bugAn unexpected behavior, bug, or errorhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22type-bug%22
Release and Deferred blockers 🚫https://github.com/orgs/python/projects/2
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.