Bisecting to find when a problem occurred

Let's say that you have archives of some kind (they could be old versions of a file, code, or something else) and you realize that something's broken. If you have a known good version, "bisecting" is to go halfway between the broken version and the good version to see whether it's broken, and continuing to iterate until you find the version that's broken.

The first time I found this technique was with git-bisect. git, a version control tool, is the perfect example of bisecting. You need (a) a known good version, (b) a known bad version, and (c) a test of some kind you can run. git-bisect then walks you through finding the specific version that breaks. It is great.

Bisecting org-plus-contrib

I manually bisected org-plus-contrib today. Let me emphasize now that I have no skill at elisp debugging, so although I found when my issue was introduced I don't know what the actual issue is.

Problem statement

The most important part of any problem investigation is a good problem statement. Here's mine.

I was getting the error

"Wrong number of arguments: (0 . 0), 2"

when trying to look at my agenda via org-agenda. I was able to make the error repeat when I execute this elisp function:

(org-agenda-get-day-entries "~/Dropbox/org/main-todo.org"
  '(2 18 2019) :deadline :scheduled :timestamp :sexp)

Further, I found that this error would go away if the dates for a TODO were not in the past.

All that said, I still had other issues, so I decided to test older versions of org-plus-contrib because this all used to work.

Known good version

I then found the historic versions of this module. The first couple of versions I tested didn't work, but then I went back to an early 2018 version and my code was working again.

Bisecting

I then went halfway between the broken version and working version to see if the error still occurred, and so on and so on until I identified that whatever the problem is was introduced in org-plus-contrib-20181230.tar.

Analysis

Although I don't know the cause of the issue, I did submit a bug report. I am not super proud of my bug report, but I'm hoping the write up is descriptive enough that if someone else with more knowledge is interested then they could have a solid problem statement to work with.

Updated: