I'm testing some Ruby code that uses Mechanize under the covers. I found that when I pass a bad OAuth token in a request, Mechanize throws an unexpected exception.
I make my call with the bad token, and the call raises the following exception:
#<NoMethodError: undefined method `any?' for nil:NilClass>
I've got some additional analysis that I'll post as an answer, but if anyone has additional insight it would be appreciated.
I tried putting this question on the mechanize-users mailing list, but the moderator didn't post it.