I was very excited for 3.11. The speed improvements alone would be very helpful given that much of what I do is video processing which sometimes runs into days vs. hours. (the Self type is rather cool too) The only issue I have so far with it is the library adoption rate. (Kudos to PyCharm for being on the stick and having a upgrade version to the IDE ready to go.) Python core is a powerful language, but most of the extreme functionality resides in 3rd party libraries. For now some will work ok while others may not even be installable. While the issue will largely resolve itself in time as more libraries upgrade, the release of a new core doesn't instantly translate into improved functionality for all previous code. This to some degree illustrates a problem common throughout the programming world, and not just Python. It's not uncommon for programmers to take the easy path and only upgrade when absolutely necessary, or worse yet, just let the code fall into the realm of permanently broken. How many Pythonistas out there are still using 3.7 or even older? (heck, how long was it just getting everyone out of 2.x because 'Libraries'?) It might be a bit before the full benefits of 3.11 propagate down through the rest of the Python kingdom. Always looking forward to your content. ❤
SOLVED I can't import pytube in python , I don't know it;s because I am using python 3.11 or not , even though i install it after python 3.11. I read some advice but I can't solve the problem. Actually I Find the solution to my problem. after the python 3.11 , almost all of your libraries won't work unless you change your interpreter to python 3.11
Have they fixed the python addition of decimals error yet? As many older programming languages python still gives errors for simple additions. I can accept that COBOL can't handle the rounding of decimals BUT python as a modern language should be fixed. Try this in python: x = 0.1 + 0.1 + 0.1 and print( x ) gives you 0.3000000004 - yayy!! Thats a bad error. BTW: I know this is related to floating point aritmetic and hardware BUT it really should be fixed by translating the addition to Decimal( 0.1 ) + Decimal( 0.1 ) + Decimal( 0.1 ) in the "background". And YES I know this means python will become even slower than it already is. But I'll trade speed for correctness every time.
Your preference is not more correct. If the interpreter encounters a value that that can only be accurately represented in base two, then defaulting to decimal operations will be less accurate. If you want perfect accuracy in base 10 by default you are using the wrong data type. You might trade speed for correctness, but your proposed change does not make the addition more correct in a general sense. You would destroy alot of legacy code with that change even beyond the speed decrease.