Something I did in a commit broke my code. I have a git bisect that shows me the last good commit and the first bad one.Continue reading
Ampere Computing chips run the ARM64 instruction set. My laptop is a Dell running x86_64. In order to edit locally, but build remotely, I make use of servers in our datacenter. These are the steps I am taking.Continue reading
While writing the last article, I noticed that I had made a bunch of little changes to the files without explicitly meaning to. I didn’t include them in the diffs. However, on my screen, I have a bunch of changes that appear to be…not changes:Continue reading
The typical approach to Data handling is
We want out code to reflect that structure. In doing so, we make it much easier to adapt the code to read from different sources and write to different destinations.Continue reading
The heart of the code is the call to solve a single puzzle; the function tree_to_solution_string. We want to write a test that runs just this function. Getting there is not so easy.
This method is buried deep within the class SudokuSolver. But creating one of these essentially runs the entire code. In fact, we can redo our original test to run the code as a python call as opposed to a subprocess call. Lets’ start with that.Continue reading
Our test takes 5 seconds to run. That is not horrible, but it does not bode well for when we write more tests. We don’t want to explode that number, and we want to be able to write more focused test. I’m going to do some project setup that will enable us to do more development, including fine grained unit tests.
I’m going to start by using tox.Continue reading
Congratulations, you got your code to run! You are done! Ship it!. Just don’t expect to be able to read it next month. You need to maintain it. You need to add new features. It is a mess.
Give yourself a well deserved break. Then come back to it.Continue reading
When a user requests a code review, the review is responsible for making sure that the code is tested.Â While the quality of the tests is a subjective matter, their presences is not;Â either they are there or they are not there.Â If they are not there, it is on the developer to explain why or why not.
Not every line of code is testable.Â Not every test is intelligent.Â But, at a minimum, a test should ensure that the code in a patch is run at least once, without an unexpected exception.