In the dynamic world of Python programming, an efficient project setup is key to success. Although our beloved Python emphasizes There should be one— and preferably only one —obvious way to do it. in its Zen, we all know that it’s rather Perl’s There Is More Than One Way To Do It! when it comes to the nuts and bolts of a Python Package, like packaging, environment & dependency management, etc. In my talk, which was presented at PyConDE/PyData Berlin 2024, I demystify the process of setting up a Python project with clarity and efficiency. I’ll introduce Hatch, a cutting-edge tool that simplifies project management. We’ll delve into the functionalities and benefits of using pyproject.toml, a cornerstone in modern Python development for its streamlined approach to project configuration.
The talk will also cover effective strategies for organizing your project’s directory structure, ensuring a clean and manageable workspace. Understanding the importance of testing, we’ll discuss unit testing techniques for enhancing code reliability. Additionally, the presentation will feature mypy for type checking, an essential practice for catching errors early and improving code quality. Finally, we’ll explore the use of ruff, a modern linter, to keep your code clean and in line with Python standards.
By the end of this presentation, you will have gained a comprehensive understanding of the tools and methodologies necessary for a modern Python project setup, empowering them to create well-structured, high-quality Python applications.
Check out the video of the presentation, as well as the slides and the Cookiecutter template The Hatchlor that sets up a Python project just like presented in this talk!
Comments
comments powered by Disqus