Live data from Hacker News

What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

bitecode.dev

11–20 of 123 posts

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#12
post #6

Do we have any idea how the introduction of the JIT compiler in CPython 3.13 will impact the performance?

The paper on copy-and-patch compilation [0] may give you a general idea although they didn't apply their technique to CPython.

[0] https://fredrikbk.com/publications/copy-and-patch.pdf

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#14
The deprecation of "crypt" could have been handled a bit better, IMHO.

It recommends to use "hashlib" instead, which isn't API compatible to crypt, and if you load it on a new enough python... triggers a deprecation warning about "crypt" being deprecated. Oh, and it seems unmaintained.

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#15
I'm very excited to see 2FA become mandatory.

It's worth noting that that 2FA requirement will have (virtuous) knock-on effects: package uploads will require an API token instead of allowing a password, meaning one less place where a user can accidentally expose control over their entire account. For packages published through GitHub Actions, PyPI's Trusted Publishing goes a step further and removes the need for a shared API token entirely[1].

[1]: https://docs.pypi.org/trusted-publishers/

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#16

[flagged]

I prefer compiled and statically typed languages myself, but it seems a bit absurd to not consider Python a general purpose programming language. It's Turing complete, has one of the most fully-featured standard libraries in existence, and can interface with native libraries.

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#18
post #5

If you read nothing else, the commit message adding JIT support is worth your time: https://github.com/python/cpython/pull/113465

Yeah, I'm getting old. I would prefer TLDR formal version and then the fun xmas version for people that feel festive. But hey I'm not paying for this so who am I to complain :)

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#19

2FA but still no namespaces? Dependency confusion attacks are still trivial on PyPI.

Namespacing does not prevent (or even significantly complicate) dependency confusion, unless we think that there's some difference in confusability between these two errors:

    requestss
and

    requestss/requests
(I think namespacing is a good idea in general, but dependency confusion is mostly a disjoint namespaces problem, not a depth problem. Python could solve the former by doing what Go does and make the source repository itself be the namespace, but this a significant incompatible breakage.)

Re: What's up Python? Epic CPython commit, Django 5 and 2FA for PyPI

#20
post #4

Is there a PEP 8106 alternative coming for the unittest module too? The naming scheme really looks odd.

Unlikely: https://discuss.python.org/t/enhance-logging-api-with-pep-8-...

It is interesting to see just how conservative the core devs are against even the most benign way forward (including more consistent aliases without immediate deprecation).

Indeed, not a hill worth dying on either way but it’s a little wild the counter argument is “increased support costs” when, let’s be real, there is no significant increased support beyond the initial scope of work.

If core Python ever plans on consistency, introducing these aliases early is the main way for them to achieve it. Even if there is no direct plan for deprecation. Something something about the best time to plant a tree.

Post reply on HN