Refactoring Videos

Refactoring: Heuristics library episode 2 – Separation of concerns

In this video we discuss the separation of concerns and apply that to improving some of the code: Summary Discussed the separation of concerns concept Improved code with this in mind Set up an upstream repository and updated the fork of the repo to get new upstream changes Made a PR with the changes in

Refactoring: Heuristics library episode 1 – introduction

We have a whole new refactoring series thanks to a library Billy has asked us to improve: Summary Here’s what happened in this video: First look at code Fixed mutable default parameter Set up Tox for testing Required writing a setup.py file Set up TravisCI for continuous integration Set up Coveralls for test coverage reports

Refactoring: Python server script episode 3 – modules

Summary Introduced modules Started cleaning up various global variables Removed “magic numbers” and replaced with named variables Links: Modules tutorial for Python 2 Modules tutorial for Python 3 David Beazley’s PyCon 2015 talk on modules  

Refactoring: Python server script episode 2 – environment setup

Summary Here’s a quick summary of what happened in the video: Set up a virtual environment for packages Updated PIP pip install –upgrade pip Installed packages then stored those packages in requirements.txt Ran into hard-coded platform specific paths that stopped script from running Dealt with exceptions that caught everything Try with no except: In this

Refactoring: Python server script episode 1 – intro

Summary The first video in the Python Server refactor series where we discuss the project and get started with the preliminary tasks. Heres what we did: Looked at architecture and other project information Got project into version control, set up Git repository Dealt with line endings issue Deal with trailing whitespace issue (see links) Initial