python/cpython
View on GitHub ↗ ★ 77,791 Python
The Python programming language
548 mentions on Hacker News by 400 people: 44 stories, 504 comments · first 2014-12-30 · latest 2026-10-27
20082026
-
…you can do on a dict is thread safe but if you find a situation where it isn't it's a bug. https://github.com/python/cpython/issues/112075 Google is recommending people not rely on it because it does make dict subclasses not substitutable.…
comment by Spivak · 2025-01-01 · in Databases in 2024: A Year in Review -
Dang: Link should be https://github.com/python/cpython/issues/86904
comment by zitterbewegung · 2024-12-26 · in Subprocess: Don't close all file descriptors by default (close_fds=False) -
https://github.com/python/cpython/issues/86904
comment by williamjackson · 2024-12-26 · in Subprocess: Don't close all file descriptors by default (close_fds=False) -
…a self-socket, but yeah, it's the same approach. The function is even called `_make_self_pipe`. https://github.com/python/cpython/blob/bf21e2160d1dc6869fb23...
comment by badmintonbaseba · 2024-12-02 · in The GNU make jobserver Implementation (2015) -
…incidents reported on status.python.org. there was some discussion on at least two github issues: https://github.com/python/cpython/issues/127307 and https://github.com/python/pythondotorg/issues/2663
comment by jepler · 2024-11-27 · in All Python Downloads from Python.org Return 403 Forbidden -
…also detects this situation (at runtime using refcounts) and does in-place mutations where possible https://github.com/python/cpython/blob/a2ee89968299fc4f0da4b...
comment by ketralnis · 2024-11-25 · in Owl Lisp – A functional Scheme for world domination -
There’s a nasty bug in the python cookie parser, cookies after a cookie with quotes will be dropped: https://github.com/python/cpython/pull/113663 Zoom or some other website our customers use was writing a cookie with quotes that would…
comment by NegativeLatency · 2024-11-22 · in Handling cookies is a minefield -
I went and dug up the original code that caused an issue. Here it is: https://github.com/python/cpython/blob/v2.7.1/Lib/cgi.py#L60... Python's std lib `cgi.FieldStorage` object was falsy if it did not define any headers , even if it…
comment by lihaoyi · 2024-11-17 · in The Pythonic Emptiness -
The issue was migrated to github so more up-to-date discussion is in https://github.com/python/cpython/issues/62817
comment by anttihaapala · 2024-11-02 · in RCE Vulnerability in QBittorrent -
…but only on MacOS (I only tested ARM, no idea on x86). Linux was about the same as for lists. [0]: https://github.com/python/cpython/issues/123540
comment by sgarland · 2024-10-26 · in Python 3.13, what didn't make the headlines -
…that when the user is already in async code they don't call the sync form out of laziness." [1] [1] https://github.com/python/cpython/issues/66435#issuecomment-...
comment by enragedcacti · 2024-10-24 · in What Color is Your Function? (2015) -
…you'll be out of the real Internet. Go ahead man! Upgrade your IP!! Change is a good thing.” [1]: https://github.com/python/cpython/blob/5f5c0b9c23238dc0a1fdb... [2]: https://adminhacks.com/broken-IPv6.html [3]:…
comment by SmartHypercube · 2024-10-21 · in The IPv6 Transition -
…released in Python 3.13 aims to provide modern features No `vi` mode and not planned. Very modern. https://github.com/python/cpython/issues/118840
comment by wiseowise · 2024-10-15 · in PEP 762 – REPL-acing the default REPL -
…call out to C extensions. Peruse the standard library code, if you want to get a sense of it: https://github.com/python/cpython/tree/main/Lib So you can expect any code that heavily relies on the standard library to be slower than the Rust…
comment by tuveson · 2024-10-09 · in My negative views on Rust (2023) -
I've been tracking this one: https://github.com/python/cpython/issues/109534 , but there are multiple others raised in the cpython repo over on Github. Searching for asyncio or sslcontext shows multiple issues raised over the years with no…
comment by boarush · 2024-10-08 · in Python 3.13.0 Is Released -
not just this one, I've been tracking this too https://github.com/python/cpython/issues/109534
comment by boarush · 2024-10-08 · in Python 3.13.0 Is Released -
…the recent deadlocks are due to this pull request as an example that calls out how risky this is. https://github.com/python/cpython/pull/114279 Personally knowing the pain of fork() in the way you are using it, I have moved on. But I would…
comment by nyrikki · 2024-10-08 · in Python 3.13.0 Is Released -
…REPL will not be implementing inputrc support, and consequently there won't be a vi editing mode. https://github.com/python/cpython/issues/118840#issuecomment...
comment by cmdlineluser · 2024-10-07 · in Python 3.13.0 Is Released -
…seen is doing weird rebinding/shadowing stuff with e.g. closures and prebound exception captures. https://github.com/python/cpython/blob/10094a533a947b72d01ed... https://github.com/python/cpython/blob/10094a533a947b72d01ed... So too for…
comment by zbentley · 2024-10-07 · in Python 3.13.0 Is Released -
…longer than merely since 3.10, I am betting this is the one, based on the description of the issue: https://github.com/python/cpython/issues/84904 (Don't let the associates with asyncio throw you: that was merely the code in which it was…
comment by saurik · 2024-10-07 · in Python 3.13.0 Is Released -
Maybe related to this segfault I found on MacOS? https://github.com/python/cpython/issues/114653
comment by orf · 2024-10-07 · in Python 3.13.0 Is Released -
…specific course of action here, but you should probably try to wade into the linked discussion ( https://github.com/python/cpython/issues/84559 ). Looks like the push to disable warnings (in 3.13) is mostly coming from one guy.
comment by icegreentea2 · 2024-10-07 · in Python 3.13.0 Is Released -
You'll also be happy to learn that there's an issue open to deprecate them: https://github.com/python/cpython/issues/78125 It's been open since 2018 though. You might find it worth a read.
comment by talideon · 2024-10-07 · in HPy – A better C API for Python -
…I've opened a CPython/PR that may help a bit by adding `python3 -m sysconfig --json` flag [0] [0] https://github.com/python/cpython/pull/123318
comment by fforflo · 2024-10-06 · in HPy – A better C API for Python -
…templates for JIT. And JIT itself currently has some memory management issues to iron out. [1]: https://github.com/python/cpython/issues/118093 Talk by Brandt Butcher was there but it was made private:…
comment by Ralfp · 2024-09-28 · in Everything you need to know about Python 3.13 – JIT and GIL went up the hill -
…it was. ReStructured Text (.rst) source for the documentation is in the CPython GitHub repository: https://github.com/python/cpython/tree/main/Doc/tutorial . You can see for yourself the commit histories and get a sense of who wrote the…
comment by zahlman · 2024-09-24 -
…Edit: This one is a decent example (and hasn't been fixed for a long time) https://github.com/python/cpython/issues/74957
comment by Retr0id · 2024-09-06 · in Achieving high Python performance with code generation (2022) -
…granularly than lists, so as it grows, it’ll have to do so more frequently compared to lists? [0]: https://github.com/python/cpython/blob/main/Modules/arraymod...
comment by sgarland · 2024-09-06 · in Lesser known parts of Python standard library -
…a heap allocated `unsigned long *` or what have you. https://docs.python.org/3/library/array.html https://github.com/python/cpython/blob/main/Modules/arraymod... And you can use struct for heterogenous data =) It has a neat DSL for…
comment by tomjakubowski · 2024-09-05 · in Lesser known parts of Python standard library -
…in how this (hilarious) error text came to be, it's been hardcoded in cpython since 2001! https://github.com/python/cpython/commit/ad3d3f2f3f19833f59f... The author, Jeremy Hylton, is now a Principal Engineer at Google working on AI search…
comment by btown · 2024-08-22 · in Python’s Preprocessor -
…name). 3. Memoize these steps, much as we see with builtin DSLs in Python, like the re module; see https://github.com/python/cpython/blob/3.12/Lib/re/__init__.... We do plan to make this easier/faster by supporting getting the original…
comment by jimbaker · 2024-08-17 · in PEP 750: Tag Strings for Writing Domain-Specific Languages -
…GitHub-Flavored Markdown, GitHub will auto-embed the current issue title and closed/open status: - https://github.com/python/cpython/issues/1 - python/cpython#1 This without the leading `- ` doesn't get the card embed though:…
comment by westurner · 2024-08-16 · in Architectural Retrospectives: The Key to Getting Better at Architecting -
…[2]: https://pypi.org/project/nest-asyncio/ [3]: https://bugs.python.org/issue22239 [4]: https://github.com/python/cpython/issues/66435
comment by gsmecher · 2024-08-15 · in Awaitless: Ipython and REPL and Coroutines – Suffering -
They removed most of superinstructions because those prevented other more effective optimizations: https://github.com/python/cpython/issues/105229
comment by Ralfp · 2024-08-08 · in Recent Performance Improvements in Function Calls in CPython -
…function in CPython’s `Python/pythonrun.c` [0] to a commit-based link [1]. [0]: https://github.com/python/cpython/blob/main/Python/pythonrun... [1]: https://github.com/python/cpython/blob/967a4f1d180d4cd669d5c...
comment by jay-barronville · 2024-08-07 · in Python extensions should be lazy -
…month [1]. There seems to have been a big influx of new contributors in the last few years. [2] [1] https://github.com/python/cpython/pulse/monthly [2] https://github.com/python/cpython/graphs/contributors
comment by the_duke · 2024-08-02 · in Russ Cox is stepping down as the Go tech lead -
It's still there! https://github.com/python/cpython/blob/main/Python/future.c#...
comment by qrian · 2024-07-08 · in Python with Braces -
…parsing of such URLs on the server side, without the actual interaction happening [1]. [1] https://github.com/python/cpython/issues/104139
comment by lifthrasiir · 2024-06-28 · in Python grapples with Apple App Store rejections -
…the `itms-services://?` URL format is non-standard and broke the existing logic in `urllib.parse`: https://github.com/python/cpython/pull/104312
comment by 7A2A-4AC · 2024-06-27 · in Python grapples with Apple App Store rejections -
…app uses the itms-services URL scheme to install an app. Seems like pretty clear direction to me: https://github.com/python/cpython/issues/120522
comment by threeseed · 2024-06-27 · in Python grapples with Apple App Store rejections -
Python has a trick allowing mutable concat when reference count is 1 https://github.com/python/cpython/blob/08d09cf5ba041c9c5c386...
comment by __s · 2024-06-16 · in Joining Strings in Python: A "Huh" Moment -
…for random. https://docs.python.org/3/library/random.html#random.shuffle Modules/_randommodule.c: https://github.com/python/cpython/blob/main/Modules/_randomm... , Library/random.py: https://github.com/python/cpython/blob/main/Lib/random.py…
comment by westurner · 2024-06-10 · in Zero Tolerance for Bias -
…automatically by the site module. Heres is the code with the function site.main that is doing it: https://github.com/python/cpython/blob/8af84b503d0b62a3db0d8... and more specifically here https://github.com/python/cpython/blob/8af84b503d0b…
comment by mariocesar · 2024-05-09 · in The new REPL in Python 3.13 -
…are outside the PyObject, last I checked) That's wrong. That was never the case. Recent CPython: https://github.com/python/cpython/blob/6d419db10c84cacbb3862... CPython 2.0: https://github.com/python/cpython/blob/2a9b0a93091b9ef7350a9...…
comment by albertzeyer · 2024-05-08 · in A library to assist writing memory-unsafe code in "pure" Python -
The “load_verify_locations” also causes a segfault sometimes: https://github.com/python/cpython/issues/114653
comment by orf · 2024-04-26 · in Patching requests for fun and (concurrent) profit -
…"hard guarantee". I was not sure what you meant, so I answered both, as you may have noticed. [1] https://github.com/python/cpython/blob/796b3fb28057948ea5b98...
comment by rbehrends · 2024-04-25 · in Borrow Checking, RC, GC, and the Eleven () Other Memory Safety Approaches -
…code"... you're going to be in for a bad time and your future collaborators will not be happy. [1]: https://github.com/python/cpython/blob/3.12/Lib/statistics.p... [2]: https://github.com/python/cpython/blob/3.12/Lib/collections/...
comment by martinky24 · 2024-04-19 · in Ask HN: High quality Python scripts or small libraries to learn from -
…They link a list of some proposed improvements already underway, with quantitative estimates, at https://github.com/python/cpython/issues/115802 The TL;DR is: > Stop using the "large" code model. (...) Benchmarking runs suggest that this…
comment by Qem · 2024-04-18 · in PEP 744 – JIT Compilation -
…[0] vendored into the Python project's repo on 2022-04-18 [1], so that should be fine, right? [0] https://github.com/python/cpython/blob/main/PCbuild/get_exte... [1] https://github.com/python/cpython-source-deps/tree/xz
comment by ptx · 2024-03-30 · in Backdoor in upstream xz/liblzma leading to SSH server compromise -
…covering his track e.g. found a cpython issue where he got reprimanded for serially opening issues: https://github.com/python/cpython/issues/115195#issuecomment... But clicking around he seems to mostly be interacting with interest around…
comment by masklinn · 2024-03-29 · in Backdoor in upstream xz/liblzma leading to SSH server compromise