Having just installed the plug-in and configured it with one repository - a local clone of linux.git -I'm seeing this error repeatedly during _poll() operations. (Additional traceback added to help diagnose):
ERROR 2012-10-27T12:20:25 supybot Git: Exception in _poll repository linux: 'listreverseiterator' object is unsubscriptable
ERROR 2012-10-27T12:20:25 supybot Git: Traceback (most recent call last):
File "/home/mooc/supybot/plugins/Git/plugin.py", line 375, in _poll
commits = repository.get_new_commits()[::-1]
TypeError: 'listreverseiterator' object is unsubscriptable
Having just installed the plug-in and configured it with one repository - a local clone of linux.git -I'm seeing this error repeatedly during _poll() operations. (Additional traceback added to help diagnose):
ERROR 2012-10-27T12:20:25 supybot Git: Exception in _poll repository linux: 'listreverseiterator' object is unsubscriptable ERROR 2012-10-27T12:20:25 supybot Git: Traceback (most recent call last): File "/home/mooc/supybot/plugins/Git/plugin.py", line 375, in _poll commits = repository.get_new_commits()[::-1] TypeError: 'listreverseiterator' object is unsubscriptable
So API_VERSION should be 1.
The code-path is:
Repository.get_new_commits() result = self.repo.commits_between(self.last_commit, self.branch) return reversed(Commit.find_all(self, "%s..%s" % (frm, to)))
This will return a class reversed() object which is a reverse iterator and cannot be subscripted:
The fix is to convert the reverseiterator to a list: