#523 – MAY 3, 2022
View in Browser »
Dunder Methods in Python: The Ugliest Awesome Sauce
Double-underscore methods, also known as “dunder methods” or “magic methods” are an ugly way of bringing beauty to your code. Learn about constructors, __repr__
, __str__
, operator overloading, and getting your classes working with Python functions like len()
.
JOHN LOCKWOOD
Why Is It Important to Close Files in Python?
Model citizens use context managers to open and close file resources in Python, but have you ever wondered why it’s important to close files? In this tutorial, you’ll take a deep dive into the reasons why it’s important to close files and what can happen if you dont.
REAL PYTHON
Try atoti, A Free Collaborative Python BI Analytics Platform
atoti is a BI analytics platform combining a python library and a web application helping Quants, Data Analyst, Data Scientist and Business Users to collaborate, analyze and translate their data into business KPIs →
ACTIVEVIAMsponsor
When Python Can’t Thread: A Deep-Dive Into the GIL’s Impact
Python’s Global Interpreter Lock (GIL) stops threads from running in parallel or concurrently. Learn how to determine the impact of the GIL on your code.
ITAMAR TURNER-TRAURING
Discussions
Python Shouldn’t Be the Top Programming Language
Discussion of the controversial article Python Is Now Top Programming Language — But Shouldn’t Be
HACKER NEWS
Python Jobs
Senior Software Engineer - Python Full Stack (USA)
Gameful Learning Developer (Ann Arbor, MI, USA)
Data & Operations Engineer (Ann Arbor, MI, USA)
Python Technical Architect (USA)
Academic Innovation Software Developer (Ann Arbor, MI, USA)
Software Development Lead (Ann Arbor, MI, USA)
Lead Software Engineer (Anywhere)
Data Engineer (Chicago, IL, USA)
Articles & Tutorials
Python Testing With doctest
Python’s doctest
module allows you to write unit tests through REPL-like sessions in your doc-strings. Learn how to write and execute doctest
code. Also available in video.
MIKE DRISCOLL
Handling Retries in Python Requests
When coding with requests
and urllib3
you can automatically retry failed connections through the use of requests.adapters.HTTPAdapter
and urllib3.Retry
. Don’t code retry loops manually, learn how to take advantage of the features of the libraries.
MARKKU LEINIÖ• Shared by Markku Leiniö
Merge Faster with WorkerB for PRs Chrome Extension
The average pull request sits idle for two days! Add context to your PR & merge faster with WorkerB magic links. Get estimated review time, number of changes, & related issues in one click! Install it today →
LINEARBsponsor
Understanding Train Test Split
The Train-Test-Split methodology is useful for supervised machine learning with a given data set. It helps ensure that new data is more likely to be categorized correctly. Learn how to use it with Python and scikit-learn.
MICHAEL GALARNY• Shared by Michael Galarnyk
Pagination for a User-Friendly Django App
In this tutorial, you’ll learn how to serve paginated content in your Django apps. Using Django pagination can significantly improve your website’s performance and give your visitors a better user experience.
REAL PYTHON
Code Quality Tools in Python
The article describes what code quality means and introduces some cool tools to improve your Python, including a variety of linters, formatters, and IDE tools.
DOLLAR DHINGRA• Shared by Dollar Dhingra
Notes on Debugging
All programmers have to learn how to do it, and like all skills it takes practice. Learn some hints and approaches to the bane of us all: debugging.
IONEL CRISTIAN MĂRIEȘ
CData Software — The Easiest Way to Connect Python With Data
Connect, Integrate, & Automate your data from any other application or tool in real-time, on-premise or cloud, with simple data access to more than 250 cloud applications and data sources. Learn more at cdata.com
CDATA SOFTWAREsponsor
MicroPython in Docker Containers
Want to play with MicroPython without a board? Learn how to use the Unix port of MicroPython in a Docker container to test out your code.
BHAVESH KAKWANI
Incorporating Julia Into Python Programs
Learn what you need to get Julia running inside your Python programs, using PyJulia, PyCall, and how to set up your environments.
PETER BAUMGARTNER
Projects & Code
Events
PyCon US 2022
April 27 to May 6, 2022
PYCON.ORG
STL Python
May 4, 2022
MEETUP.COM
Heidelberg Python Meetup
May 4, 2022
MEETUP.COM
Canberra Python Meetup
May 5, 2022
MEETUP.COM
PyCon Kenya Conference 2022
May 6 to May 8, 2022
PYCONKE.ORG
Happy Pythoning!
This was PyCoder’s Weekly Issue #523.
View in Browser »
[ Subscribe to 🐍 PyCoder’s Weekly 💌 – Get the best Python news, articles, and tutorials delivered to your inbox once a week >> Click here to learn more ]