Live data from Hacker News

Python 3.12.0 is to remove long-deprecated items

discuss.python.org

201–210 of 257 posts

Re: Python 3.12.0 is to remove long-deprecated items

#201

I'm normally joyful when a modern language (say, julia) decides to break backward compatibility to improve the language on a fundamental level. This is mostly because I'm not too vested in it. For languages where I have 10+ years of work behind, it's the exact opposite, and where I see the c/c++ model of not breaking backward compatibility a much saner choice. Python in particular is an extremely bittersweet pill to…

> By comparison, I never experienced such churn with perl. I literally have 20+ years old perl scripts, usually doing one single thing (many of them) still working on new machines without issues. I've rewritten some stuff from python(2) to perl (instead of python3) because i was unsure when a new rewrite for whatever reasons... Now, more python stuff needs fixing, while perl still works.

Your kinda comparing simple basic api in perl vs likely more complicated python code here aren't you?

If you had a set of single simple python functions maybe they wouldn't have broke as much if at all?

Re: Python 3.12.0 is to remove long-deprecated items

#202
post #126

Earlier quoted context omitted.

This is circular: sure, if telnet is _obsolete_, then remove it. But being obsolete exactly means no one is using it anymore. If someone is using it, then it's not obsolete. Regarding security, some would advocate that telnet, or whatever else, is secure at least as much as the network underlying it. So anyone who puts their "legacy" telnet apps on a VPC is fine, and has decades more to enjoy software that has alread…

Telnet has been obsolete since the turn of the century. That doesn’t mean that nobody uses it but it does mean that everyone who does should be upgrading away from it. Trusting the network for security was common in the previous century but standards have improved since then. For example, sending your password in clear text is no longer considered acceptable by mainstream security standards since it avoids the risk o…

Obsolete means no longer in use or useful. It's been argued in this thread that it's both in use and useful. But yes, there are more secure protocols that overlap with most of what telnet can be used for.

Re: Python 3.12.0 is to remove long-deprecated items

#203

Earlier quoted context omitted.

I mean that level of breakage is good. You can’t keep running outdated stuff while expecting to interact with the wider world.

Okay, then practically you can't pin versions and have it work forever.

You can. Package everything you need with the environment and you’re done. Now whether future versions of whatever container you choose to run it in will support establishing the environment is a separate detail. There is no answer. You can go all the way to reserving an entire computer to run mission critical code but you don’t know if it is future proof in terms of electrical specifications.

That’s the point of civilization though. You iterate and what works out, other people copy and iterate even more.

Re: Python 3.12.0 is to remove long-deprecated items

#204
post #67

If we're going to be making backwards incompatible changes to unittest, it'd be nice to introduce PEP8-compatible names, deprecate the old ones, and remove then in 3.20 or something. (I know there's pytest and nosetests, but especially when teaching people, it's nice to use what's in the standard library and unittest sticks out for having things named differently)

yes, please! Very minor issue indeed, but this kind of cruft adds up and I'd love to see it fixed.

Re: Python 3.12.0 is to remove long-deprecated items

#205

I see telnetlib is on the way out in 3.13 or so, which means a lot of pointless busywork in my future. Its a super useful module for a lot of tasks. The suggested replacements either are asyncio based (which means whole ass rewrites as asyncio is really fucking opinionated), or are excessively restrictive in some stupid way. "Infosec" at work tend to raise a ruckus when their scans detect "older" versions of Python o…

What do you use telnet for today? Almost everyone uses ssh. The reason behind that was to provide TLS. Is there a reason you can’t use ssh?

Re: Python 3.12.0 is to remove long-deprecated items

#206
post #198

Earlier quoted context omitted.

Yah, nothing the GP says makes any sense. I've been working with large code bases with many languages for many years. None are perfect, but the GP makes no sense, sounds like poor decisions or poor code rather than a poor language.

The idea that pinning versions and using environments will make your code run stable forever is very wrong (in python). You can't even get things to run for a few years this way. Many of the packages are simply not available anymore. Ever tried to get an environment running that uses qt4 on py2.7? It really wasn't that long ago that py2.7 was standard (in the stable code realm that we're talking about).

If you want a long term snapshot of other people's packages, the onus is on you to store them indefinitely. Packages can be pinned and installed from a local folder.

Re: Python 3.12.0 is to remove long-deprecated items

#207
post #82

I see telnetlib is on the way out in 3.13 or so, which means a lot of pointless busywork in my future. Its a super useful module for a lot of tasks. The suggested replacements either are asyncio based (which means whole ass rewrites as asyncio is really fucking opinionated), or are excessively restrictive in some stupid way. "Infosec" at work tend to raise a ruckus when their scans detect "older" versions of Python o…

I would expect them to move telnetlib to a separate, unsupported repo that you can then import. Even if they don’t, from a cursory view, it seems it’s a pure python library ( https://github.com/python/cpython/blob/main/Lib/telnetlib.py ). If so, can’t you copy the current code into your project? You would take on the burden of supporting it, but looking at https://github.com/python/cpython/commits/main/Lib/telnetlib.…

PEP-0594 lists the deprecated packages and any potential replacements.

https://peps.python.org/pep-0594/#telnetlib

Re: Python 3.12.0 is to remove long-deprecated items

#208
post #202
post #126

Earlier quoted context omitted.

Telnet has been obsolete since the turn of the century. That doesn’t mean that nobody uses it but it does mean that everyone who does should be upgrading away from it. Trusting the network for security was common in the previous century but standards have improved since then. For example, sending your password in clear text is no longer considered acceptable by mainstream security standards since it avoids the risk o…

Obsolete means no longer in use or useful. It's been argued in this thread that it's both in use and useful. But yes, there are more secure protocols that overlap with most of what telnet can be used for.

Obsolete doesn’t mean something has no possibility of being useful but rather that it’s no longer commonly used because there are better alternatives. My son’s beloved steam locomotives still run but nobody uses them for normal commercial service because they became obsolete shortly after the invention of diesel and electric.

> (of words, equipment, etc.) No longer in use; gone into disuse; disused or neglected (often in favour of something newer)

https://en.wiktionary.org/wiki/obsolete

Bringing that full circle, telnet used to be common but it has security issues (lack of encryption or integrity unless you tunnel over TLS, lack of modern authentication options, etc.) and so anywhere it’s still used we should be looking in to replacing it.

Re: Python 3.12.0 is to remove long-deprecated items

#209

I'm normally joyful when a modern language (say, julia) decides to break backward compatibility to improve the language on a fundamental level. This is mostly because I'm not too vested in it. For languages where I have 10+ years of work behind, it's the exact opposite, and where I see the c/c++ model of not breaking backward compatibility a much saner choice. Python in particular is an extremely bittersweet pill to…

This doesn't make sense. You can pin versions and it will work forever. If you want to update you need to update your code.

A problem with pinning is that it doesn’t only freeze features, ensuring that the features you need will be available forever, but also bugs, in particular security bugs, ensuring that security bugs you have today, but that you and possibly even the entire world are unaware of, will stay around forever.

Re: Python 3.12.0 is to remove long-deprecated items

#210

I'm normally joyful when a modern language (say, julia) decides to break backward compatibility to improve the language on a fundamental level. This is mostly because I'm not too vested in it. For languages where I have 10+ years of work behind, it's the exact opposite, and where I see the c/c++ model of not breaking backward compatibility a much saner choice. Python in particular is an extremely bittersweet pill to…

I missing print without parentheses.

Me three, oops, meant two (extra parentheses to type). Not /s, but ;)
Post reply on HN