simpleai-team/simpleai — pull request #35 by asbjxrn (2013-01-28 12:58:32+00:00)
Title: Make BoundedPriorityQueue use internal heap instead of subclassing from list

The python version of heapq.heappush starts by calling heap.append(item), with BoundedPriorityQueue calling heappush in it's append function the end result is endless recursion.

Cpython uses a c implementation of heapq, which doesn't have this issue (Apparently). But other impementations may use the python version, pypy is the one I tried where this issue appears.