This week we welcome Claudio Jolowicz (@cjolowicz) as our PyDev of the Week! Claudio is the author of an upcoming book titled Hypermodern Python Tooling. Claudio writes about Python on Medium. You can also see what Claudio has been working on over on GitHub.

Let’s take a few moments to get to know Claudio better!

Can you tell us a little about yourself?

I’m a dad of two daughters in pre-school age and a software engineer at Cloudflare, where I work on the Web Application Firewall. I’m also currently writing a book for O’Reilly about Python developer tooling, titled Hypermodern Python Tooling. (It’s in Early Release, you can take a peek!) I spent most of the past decade as a session and tour musician, playing saxophones, flutes, and keyboards with over a hundred different artists, particularly from West Africa and the Caribbean. I decided to take a break from touring in 2019, and have since become active in the open-source community and written an article series about Python developer tooling, which I’m now updating and turning into this book. I’ve been fascinated with computer programming since childhood. I live in Berlin, Germany.

Why did you start using Python?

I first came across Python in a book about UNIX I was reading at college, at the time of Python 2.3. Its intuitive and elegant design immediately struck a chord with me. Coming batteries included was also a big motivator, at a time when PyPI was only just being launched. I love how Python is simple at the surface but lets you access its inner workings when you need to, the special methods, descriptors, metaclasses, or import machinery. I advocated for Python in every team I joined, and it was never hard to convince anybody. Most of the time, Python wasn’t the main implementation language. We’d work in C++ (or now Go and Rust), while Python was used for building, testing, and prototyping.

What other programming languages do you know and which is your favorite?

My Haskell is more than a bit rusty, but it’s been a huge influence and it’s still a natural way to approach problems because of its conceptual clarity. Apart from Python, I’m most proficient in C++, having spent years in cloud email security working on services and libraries written in this language. C++ can be a great language to work in if you chose the right subset and follow good practices. (It’s a complete nightmare if you don’t, but you probably already knew that.) These days I’m getting up to speed with the Go and Rust codebases at Cloudflare. I’m pretty excited about Rust in particular; it combines everything I love in other languages and throws some new ideas into the pot, like the borrow checker. My first programming was in a BASIC dialect on the Commodore 64 and in Visual Basic, and there are a bunch of other languages I’ve worked with over the years, such as C, Lua, and JavaScript.

What projects are you working on now?

All my time goes into the book right now. It’s a great opportunity to take a look at how the Python packaging and tooling ecosystem has evolved in the past three years, and so much has happened! I also maintain the Hypermodern Python Cookiecutter, a Python project template using Poetry for packaging, Nox for automation, and GitHub Actions for CI/CD. It comes with testing, linting, code formatting, type-checking, and documentation, and aims to help you write better code and maintain it, without getting in your way too much.

Which Python libraries are your favorite (core or 3rd party)?

I’ll go with attrs. It’s as much about its practical value as it is about its philosophy. You start using attrs (or dataclasses) because it removes the boilerplate from your class definitions. But attrs also gently nudges you towards a domain-driven software design with immutable value objects at the core of your application. If you’re doing everything right, your domain layer has all of the business logic and none of the dependencies of your application. Keep persistence, messaging, and presentation out of the domain layer, and you end up with software that’s testable and easy to change.

Is there anything else you’d like to say?

Python packaging is actually delightful to use these days. If you haven’t seen some of the recent developments, I recommend starting with the Packaging Python Projects tutorial at the Python Packaging User Guide, which is a short read. For very small projects like single-file scripts, I love dropping a minimal `pyproject.toml` next to the script and running `pipx install -e .`. This will install the script and its third-party dependencies into an isolated environment and place the script on your `PATH`. No need to activate the virtualenv, no need to reinstall when you edit the script. Finally, check out pipx and Nox.

Thanks for doing the interview, Claudio!

The post PyDev of the Week: Claudio Jolowicz appeared first on Mouse Vs Python.

Categories: Python