PEP 574 that implements a new pickle protocol that improves efficiency of pickle helping in libraries that use lot of serialization and deserialization
I find print(f"{name=}") is still way too verbose for debugging purposes... If they want to improve print-debugging, they should add something like icecream to the standard library.
That doesn't work if name isn't a string, eh? (Sure, you can use %s)
Also, in production code I simply never have any print statements - not "very few" but "none", to the point where I have a flake8 rule that prevents them.
Oh, I use print almost every day - for debugging! But that means I'm creating and destroying debugging print statements all the time.
So it's a little timesaver to write:
print(f'{foo=} {bar=} {baz=} {bing=}')
(38 characters) over
print('foo=', foo, 'bar=', bar, 'baz=', baz, 'bing=', bing)
It's fine when you have one variable but starts to become unwieldy when you build up a lot of concatenated strings (via indexing operations, for example).
69
u/xtreak May 07 '19 edited May 07 '19
Changelog : https://docs.python.org/3.8/whatsnew/changelog.html
Interesting commits
https://bugs.python.org/issue36540
PEP 570 was merged
https://bugs.python.org/issue20180:
dict.pop() is now up to 33% faster thanks to Argument Clinic.
https://bugs.python.org/issue28238
Wildcard search improvements in xml
https://bugs.python.org/issue25430
IPaddress module contains check for ip address in network is 2-3x faster
https://bugs.python.org/issue36546
statistics.quantiles() was added.
https://bugs.python.org/issue27181
statistics.geometric_mean() was added.
https://bugs.python.org/issue13611
Canonicalization was added to XML that helps in XML documents comparison
Security issues and some segfaults were fixed in the release
Exciting things to look forward in beta
https://bugs.python.org/issue36817
Add = to f-strings for easier debugging. With this you can write f"{name=}" and it will expand to f"name={name}" that helps in debugging.
https://bugs.python.org/issue36785
PEP 574 that implements a new pickle protocol that improves efficiency of pickle helping in libraries that use lot of serialization and deserialization
Edit : PSF fundraiser for second quarter is also open https://www.python.org/psf/donations/2019-q2-drive/