In this new podcast episode we are excited to have Chris May back to delve deeper into the intricacies of refactoring. Watch here: Listen here: We talk about the significance of the Flocking Rules, a set of guidelines derived from “99 Bottles of OOP” by Sandi Metz and Katrina Owen. These rules provide developers with… Continue reading How the Flocking Rules Can Help You Refactor Your Code
Articles on Concepts
The Arbitrary (Keyword) Arguments (args and kwargs) don’t come “for free” in Python
By Bob Belderbos on 9 August 2023
Python allows you to use *args and **kwargs in function definitions to accept an arbitrary number of positional and keyword arguments, respectively. Here is a simple example: Different types of function arguments In the above example, the arbitrary_args function is defined to accept any number of positional and keyword arguments using the *args and **kwargs… Continue reading The Arbitrary (Keyword) Arguments (args and kwargs) don’t come “for free” in Python
The power of mind mapping: why to start your project with one and how
By PyBites Team on 3 August 2023
When you start a bigger software project it’s very beneficial (and necessary) to make a mind map first! It helps planning, organizing, and executing the project. Here are 6 advantages of mind mapping: Here is an example of one we did for our coding platform: CodeChalleng.es: Mind mapping your idea helps foster a well-structured, organized,… Continue reading The power of mind mapping: why to start your project with one and how
Feel Comfortable with Git?
By Jeffrey Haemer on 27 February 2023
Folks come to me to ask for help with Git. Sometimes they can’t guess what git subcommand they need. (Git 2.37 has 169.) Sometimes they know what subcommand they want, but don’t know what flags to use. (git log now has 149 flags and options.) Sometimes they issued a command, and Git didn’t do what… Continue reading Feel Comfortable with Git?
Reflections on the Zen of Python
By Bob Belderbos on 21 December 2022
An initial version of this article appeared as a Pybites email first. If you like it join our friends list to get our valuable Python, developer and mindset content first … How following the Zen of Python will make your code better, a lot better. This epic set of axioms (triggered by typing import this in the… Continue reading Reflections on the Zen of Python
A Case Study in Refactoring Python: Clean Code Is Often Faster
By Russell Helmstedter on 20 July 2022
I have learned a lot over the past 2.5 years of my Python journey. What started out as a hobby during COVID-19 lock downs in 2020, has now become a major component of my professional workload. This article is designed to highlight the importance of the iterative process: write some code -> learn new stuff… Continue reading A Case Study in Refactoring Python: Clean Code Is Often Faster
Case study: How to parse nested JSON
By Michael Aydinbas on 3 June 2022
I was asked to help parse a JSON file that is delivered by the iTunes Store Customer Reviews API JSON endpoint. It is not so important how this API works or if there are better APIs for this. Instead, let’s assume that we found our favorite API to work with and that our request makes… Continue reading Case study: How to parse nested JSON
Code Better with Type Hints – Part 3
By Michael Aydinbas on 8 April 2022
This is the third part of a series of articles dealing with the type annotation system in Python, type hints for short. The second part discussed a set of beginner examples and highlighted the benefits of using type hints. This article series is aimed at newcomers to type hints and wants to help you get… Continue reading Code Better with Type Hints – Part 3
Code Better with Type Hints – Part 2
By Michael Aydinbas on 27 August 2021
This is the second part of a series of articles dealing with the type annotation system in Python, type hints for short. The first part gave an introduction to type hints. This article is aimed at newcomers to type hints and wants to help you get started. In this second part, I will go over… Continue reading Code Better with Type Hints – Part 2
Code Better with Type Hints – Part 1
By Michael Aydinbas on 12 August 2021
This is the first part of a series of articles dealing with the type annotation system in Python, type hints for short. With this opinionated article, I advocate the use of type hints. I want to explain why you should care and why your code will be better, more bug-free, more accessible, and easier to… Continue reading Code Better with Type Hints – Part 1