Title: Build failure with "--with-address-sanitizer" flag · Issue #121847 · python/cpython · GitHub
Open Graph Title: Build failure with "--with-address-sanitizer" flag · Issue #121847 · python/cpython
X Title: Build failure with "--with-address-sanitizer" flag · Issue #121847 · python/cpython
Description: Bug report Bug description: When building Python with --with-address-sanitizer flag, the build fails. Leak sanitizer triggers when python is run. Possible way to reproduce: nix build --impure --expr \ 'with import
Open Graph Description: Bug report Bug description: When building Python with --with-address-sanitizer flag, the build fails. Leak sanitizer triggers when python is run. Possible way to reproduce: nix build --impure --exp...
X Description: Bug report Bug description: When building Python with --with-address-sanitizer flag, the build fails. Leak sanitizer triggers when python is run. Possible way to reproduce: nix build --impure --exp...
Opengraph URL: https://github.com/python/cpython/issues/121847
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Build failure with \"--with-address-sanitizer\" flag","articleBody":"# Bug report\n\n### Bug description:\n\nWhen building Python with `--with-address-sanitizer` flag, the build fails. Leak sanitizer triggers when python is run.\n\nPossible way to reproduce:\n```bash\nnix build --impure --expr \\\n 'with import \u003cnixpkgs\u003e {};\n python312.overrideAttrs (oldAttrs: {\n configureFlags = oldAttrs.configureFlags or [] ++ [\"--with-address-sanitizer\"];\n })'\n\n```\n\nRelevant portion of the build log:\n```\n...\n./_bootstrap_python ./Programs/_freeze_module.py abc ./Lib/abc.py Python/frozen_modules/abc.h\n./_bootstrap_python ./Programs/_freeze_module.py codecs ./Lib/codecs.py Python/frozen_modules/codecs.h\n./_bootstrap_python ./Programs/_freeze_module.py io ./Lib/io.py Python/frozen_modules/io.h\n./_bootstrap_python ./Programs/_freeze_module.py _collections_abc ./Lib/_collections_abc.py Python/frozen_modules/_collections_abc.h\n./_bootstrap_python ./Programs/_freeze_module.py _sitebuiltins ./Lib/_sitebuiltins.py Python/frozen_modules/_sitebuiltins.h\n./_bootstrap_python ./Programs/_freeze_module.py genericpath ./Lib/genericpath.py Python/frozen_modules/genericpath.h\n./_bootstrap_python ./Programs/_freeze_module.py ntpath ./Lib/ntpath.py Python/frozen_modules/ntpath.h\n./_bootstrap_python ./Programs/_freeze_module.py posixpath ./Lib/posixpath.py Python/frozen_modules/posixpath.h\n./_bootstrap_python ./Programs/_freeze_module.py os ./Lib/os.py Python/frozen_modules/os.h\n./_bootstrap_python ./Programs/_freeze_module.py site ./Lib/site.py Python/frozen_modules/site.h\n./_bootstrap_python ./Programs/_freeze_module.py stat ./Lib/stat.py Python/frozen_modules/stat.h\n./_bootstrap_python ./Programs/_freeze_module.py importlib.util ./Lib/importlib/util.py Python/frozen_modules/importlib.util.h\n./_bootstrap_python ./Programs/_freeze_module.py importlib.machinery ./Lib/importlib/machinery.py Python/frozen_modules/importlib.machinery.h\n./_bootstrap_python ./Programs/_freeze_module.py runpy ./Lib/runpy.py Python/frozen_modules/runpy.h\n./_bootstrap_python ./Programs/_freeze_module.py __hello__ ./Lib/__hello__.py Python/frozen_modules/__hello__.h\n./_bootstrap_python ./Programs/_freeze_module.py __phello__ ./Lib/__phello__/__init__.py Python/frozen_modules/__phello__.h\n./_bootstrap_python ./Programs/_freeze_module.py __phello__.ham ./Lib/__phello__/ham/__init__.py Python/frozen_modules/__phello__.ham.h\n./_bootstrap_python ./Programs/_freeze_module.py __phello__.ham.eggs ./Lib/__phello__/ham/eggs.py Python/frozen_modules/__phello__.ham.eggs.h\n./_bootstrap_python ./Programs/_freeze_module.py __phello__.spam ./Lib/__phello__/spam.py Python/frozen_modules/__phello__.spam.h\n./_bootstrap_python ./Programs/_freeze_module.py frozen_only ./Tools/freeze/flag.py Python/frozen_modules/frozen_only.h\n\n=================================================================\n[1m[31m==408115==ERROR: LeakSanitizer: detected memory leaks\n[1m[0m\n[1m[34mDirect leak of 15657 byte(s) in 318 object(s) allocated from:\n[1m[0m #0 0x7ffff79fd04f in __interceptor_malloc (/nix/store/c6r62m84hywf4i6qq1h28f13zv38yqyp-gcc-13.3.0-lib/lib/libasan.so.8+0xdc04f)\n #1 0x6efb6e in PyUnicode_New Objects/unicodeobject.c:1251\n #2 0x76ef10 in PyUnicode_New Objects/unicodeobject.c:1200\n #3 0x76ef10 in unicode_decode_utf8 Objects/unicodeobject.c:4693\n #4 0x4eb9ee in _PyPegen_decode_string Parser/string_parser.c:185\n #5 0x4eb9ee in _PyPegen_decode_string Parser/string_parser.c:182\n #6 0x4ec294 in _PyPegen_parse_string Parser/string_parser.c:273\n #7 0x44c06e in _PyPegen_constant_from_string Parser/action_helpers.c:1413\n #8 0x49e4df in string_rule Parser/parser.c:16242\n #9 0x49e4df in _tmp_259_rule Parser/parser.c:40700\n #10 0x49e4df in _loop1_115_rule Parser/parser.c:32163\n #11 0x49e4df in strings_rule Parser/parser.c:16294\n #12 0x45eecb in atom_rule Parser/parser.c:14690\n #13 0x464a8f in primary_raw Parser/parser.c:14328\n #14 0x464a8f in primary_rule Parser/parser.c:14126\n #15 0x4659f9 in await_primary_rule Parser/parser.c:14080\n #16 0x4668e7 in power_rule Parser/parser.c:13956\n #17 0x4668e7 in factor_rule Parser/parser.c:13906\n #18 0x467d8f in term_raw Parser/parser.c:13747\n #19 0x467d8f in term_rule Parser/parser.c:13509\n #20 0x4692c4 in sum_raw Parser/parser.c:13463\n #21 0x4692c4 in sum_rule Parser/parser.c:13342\n #22 0x46a224 in shift_expr_raw Parser/parser.c:13302\n #23 0x46a224 in shift_expr_rule Parser/parser.c:13181\n #24 0x46afa4 in bitwise_and_raw Parser/parser.c:13141\n #25 0x46afa4 in bitwise_and_rule Parser/parser.c:13059\n #26 0x46bbc4 in bitwise_xor_raw Parser/parser.c:13019\n #27 0x46bbc4 in bitwise_xor_rule Parser/parser.c:12937\n #28 0x46c7e4 in bitwise_or_raw Parser/parser.c:12897\n #29 0x46c7e4 in bitwise_or_rule Parser/parser.c:12815\n #30 0x46d4a0 in comparison_rule Parser/parser.c:12055\n #31 0x46d4a0 in inversion_rule Parser/parser.c:12006\n #32 0x4703be in conjunction_rule Parser/parser.c:11883\n #33 0x4713ae in disjunction_rule Parser/parser.c:11795\n #34 0x4729f4 in expression_rule Parser/parser.c:11083\n #35 0x476061 in kvpair_rule Parser/parser.c:16754\n #36 0x4ae2ce in double_starred_kvpair_rule Parser/parser.c:16714\n #37 0x4ae2ce in _loop0_118_rule Parser/parser.c:32287\n #38 0x4ae2ce in _gather_117_rule Parser/parser.c:32354\n #39 0x45fe55 in double_starred_kvpairs_rule Parser/parser.c:16642\n #40 0x45fe55 in dict_rule Parser/parser.c:16561\n #41 0x45fe55 in _tmp_96_rule Parser/parser.c:30838\n #42 0x45fe55 in atom_rule Parser/parser.c:14772\n #43 0x4b2e1b in t_primary_raw Parser/parser.c:18967\n #44 0x4b2e1b in t_primary_rule Parser/parser.c:18757\n #45 0x4b41d4 in target_with_star_atom_rule Parser/parser.c:18257\n #46 0x4b7059 in star_target_rule Parser/parser.c:18200\n #47 0x4b7769 in star_targets_rule Parser/parser.c:17942\n #48 0x4c8bba in _tmp_250_rule Parser/parser.c:40232\n #49 0x4c8bba in _loop1_14_rule Parser/parser.c:25810\n #50 0x4c8bba in assignment_rule Parser/parser.c:2360\n #51 0x4cc0f3 in simple_stmt_rule Parser/parser.c:1707\n...\n```\n\n### CPython versions tested on:\n\n3.10, 3.12\n\n### Operating systems tested on:\n\nLinux","author":{"url":"https://github.com/zack-alex","@type":"Person","name":"zack-alex"},"datePublished":"2024-07-16T11:16:29.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":9},"url":"https://github.com/121847/cpython/issues/121847"}
| 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:8d8c7e88-cf81-268c-2de2-61bf8a634bea |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 867C:1B7E6F:13B2940:1B2C347:696A9435 |
| html-safe-nonce | 1819d8c81c66b1cde60327ef607d20f33a5a0fce7f603d14bc1e5ee5e3c400c5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NjdDOjFCN0U2RjoxM0IyOTQwOjFCMkMzNDc6Njk2QTk0MzUiLCJ2aXNpdG9yX2lkIjoiNzAwNjIzODUxNjU5Njg3MjI0NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 5fb5580b7b15af66cd62bd87108f9f9e02b75aad5c17f9f472a179394a6d8918 |
| hovercard-subject-tag | issue:2410882360 |
| 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/121847/issue_layout |
| twitter:image | https://opengraph.githubassets.com/97cae0ba784138faf01087ecec36db43a6debd8cf402850a5e0610c3eedf9cef/python/cpython/issues/121847 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/97cae0ba784138faf01087ecec36db43a6debd8cf402850a5e0610c3eedf9cef/python/cpython/issues/121847 |
| og:image:alt | Bug report Bug description: When building Python with --with-address-sanitizer flag, the build fails. Leak sanitizer triggers when python is run. Possible way to reproduce: nix build --impure --exp... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | zack-alex |
| hostname | github.com |
| expected-hostname | github.com |
| None | c0d8175e41e0e55b9e984c935b24b808cabab919dd3174aa45dac3ef503ed1af |
| 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 | 99aab454e5ddc8df30805fb76c114c3008a15842 |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width