Being a software engineer by craft, but future novel writer by passion, Claudiu tries to balance these two pursuits of his life on a daily basis. When he doesn't try to finish a new chapter of his novel, he's getting busy with Pylint, the popular static analysis tool for Python, or dabbles himself in some machine learning project, hoping that some good results will come out of his efforts to improve
the education with artificial intelligence.
Crossing the Python 3 Rubicon
- Location: R0
- Slot: Day 1, 10:45‑11:15
- Category: Best Practices & Patterns
- Language: English talk
- Python Level: Intermediate
Abstract
The clock is ticking for Python 2, we are getting close to its sunset in 2020, and we need to embrace the better Python. Python 3 comes with lots of shiny and great features, but what can you and your team do if you are still stuck on Python 2? Crossing the Python 3 Rubicon is going to show you the answers to the three questions of every successful migration, the inseparables "why, what and how", with a strong emphasis on "how" to approach a successful migration. We're going to see best practices, tips and tricks, tools and examples on how we approached the migration to Python 3 at Zapier. Will you do it?
Description
Targeted at engineers that want to make the switch to Python 3, but don't know exactly where to start. The talk will introduce best practices that were already used at various companies, and I'll emphasize the strategies that we use successfully at Zapier to move a big Python codebase to Python 3.
I'll present how to approach the migration starting from two main questions, what needs to be changed and how to change the codebase to work on both versions, while the migration is ongoing.
We'll see in action tools such as `pylint` that can be used for getting incompatibility warnings between the two versions, we'll see how running the tests with `python -bb` and `python -3` could also spot tricky differences, and we'll also see in action tools such as `python-futurize` and `modernize` for automating the boring parts of a migration.
At the end of this talk, the key takeaways will be a guideline that anyone could enforce for their projects for making the switch to Python 3, starting from the boring parts of a migration to the subtle parts where the semantics of the two versions are different.
Slides
https://www.slideshare.net/ClaudiuPopa10/pycon-taiwan-2018claudiupopa