Ever been in a situation where you've hastily written a bunch of code, just to make something "work"?
Have you then trembled with fear, looking at your single, thousand line file, with global variables, multi parameter functions, and zero classes, not knowing where to start?
Or do you question why changing your complex code and fixing bugs takes so long?
Then come and learn about how refactoring can not only be fun and educational, but also profitable!
Often in programming projects, we find ourselves building layers and layers on top of a starting idea, without having been able to think about the long term design.
And that's fine! But unless push comes to shove, we often don't get the time or incentive to sit down and clean it up, especially if it all works.
In this talk, we'll discuss why you should care about good pythonic code, and how refactoring can not only be profitable, but also a fun and educational experience!
We'll look at easy to use tools and techniques that Python offers to make the process faster and future proof.
And finally, we'll cover some design principles and methodologies to keep in mind, alongside understandable real world examples.
0:00 - Start
0:17 - What is refactoring?
1:01 - Why refactor?
3:00 - Formatting
4:45 - Linting
5:44 - Abstracting
9:12 - Integrated Development Environments
11:17 - Typing
15:57 - Refactoring examples
19:11 - Named arguments
23:30 - Documentation of code
24:34 - Refactoring examples
25:29 - Logging
26:10 - Documentation of structure
27:23 - Single responsibility principle
29:08 - Don't Repeat Yourself
30:21 - Refactoring examples
31:13 - Keep It Simple Stupid
32:47 - You Ain't Gonna Need It
33:17 - Testing
35:09 - Profiling
35:55 - Refactoring examples
37:09 - Outro
38:57 - Question: Have you looked into using AI tools for refactoring?
40:47 - Question answered after session.
42:21 - Question: How much object oriented programming did you use at the end given that you started with functional programming?
43:56 - Question: Do you have comments on understanding the data you're working in relation to refactoring?
Смотрите видео Refactoring for fun and profit by Evan Kohilas онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Kiwi PyCon 12 Октябрь 2023, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 15 раз и оно понравилось людям.