What's New in Python 3.15
12 comments
·December 17, 2025stabbles
> On POSIX platforms, platlib directories will be created if needed when creating virtual environments, instead of using lib64 -> lib symlink. This means purelib and platlib of virtual environments no longer share the same lib directory on platforms where sys.platlibdir is not equal to lib.
Sigh. Why can't they just be the same in virtual environments.
PaulHoule
PEP 686 makes me smile
pjmlp
I am here for the JIT and improved profiling goodies, one day Python will finally be a proper Lisp replacement.
nurettin
I had a colleague who was hostile to any language other than common lisp. Except python, which I assume is just because this page exists. What if norvig woke up that day and decided to write about Ruby instead?
edflsafoiewq
Can definitely think of some places I should use bytearray.take_bytes.
ruuda
> Python now uses UTF-8 as the default encoding, independent of the system’s environment.
Nice, not specifying the encoding is one of the most common issues I need to point out in code reviews.
franga2000
You mean the coding= comment? Where are you shipping your code that that was actually a problem? I've never been on a project where we did that, let alone needed it.
joshribakoff
Have you considered reducing review noise by using static analysis?
KK7NIL
Yep, ruff has a warning for this exact issue.
formerly_proven
encode()/decode() have used UTF-8 as the default since Python 3.2 (soon, 15 years ago). This is about the default encoding for e.g. the "encoding" parameter of open().
Erenay09
Seeing this reminded me of version 3.14, where π is an infinity expressed through its fractional parts.
In the improved error message [0] how are they able to tell nested attributes without having a big impact in performance? Or maybe this has a big impact on performance, then using exceptions for control flow is deprecated?
> AttributeError: 'Container' object has no attribute 'area'. Did you mean: 'inner.area'?[0] -- https://docs.python.org/3.15/whatsnew/3.15.html#improved-err...