UCL-COMP0233-24-25 / RSE-Classwork

6 stars 85 forks source link

Automating `git bisect` - part VI #27

Open dpshelio opened 2 weeks ago

dpshelio commented 2 weeks ago

Continuation from #26.

Now that you have a script that tests Charlene's script we can start to find when the error was introduced!

Step 6

Let's run our new script on the current state of Charlene's project and see what happens:

Now let's got to a point in history we believe the code was working correctly.

By now we should have told bisect that there is a good and a bad commit and we want to find when things started going wrong. You can see which ones are by running git bisect log.

Hint The output of the `log` should be something like: ``` git bisect start # bad: [d8bc3ebaecd0cc7a2872da4c81d30b56f9b746ad] Makes the file Pep8 compliant and fixessome typos on docs git bisect bad d8bc3ebaecd0cc7a2872da4c81d30b56f9b746ad # good: [9dc8a27ada280e4479241c37bcb4d7f50c34ca09] Adds input and output data for future testing git bisect good 9dc8a27ada280e4479241c37bcb4d7f50c34ca09 ```

Let's now git bisect to find the commit that introduce the bug!

git bisect run python test_sagittal_brain.py

React to this issue (#27) with a 🚀 when your team has completed the task.


Sample solution