You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
class Test(Document):
test = StringField()
def do_nothing(*args, **kwargs):
pass
post_delete.connect(do_nothing)
Test(test='001').save().delete()
Log example:
...
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 430, in delete
doc.delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 430, in delete
doc.delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 430, in delete
doc.delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 430, in delete
doc.delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 430, in delete
doc.delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/document.py", line 347, in delete
self._qs.filter(**self._object_key).delete(write_concern=write_concern)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 429, in delete
for doc in queryset:
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 157, in _iter_results
self._populate_cache()
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 167, in _populate_cache
self._result_cache.append(self.next())
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/mongoengine/queryset/queryset.py", line 1148, in next
raw_doc = self._cursor.next()
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/cursor.py", line 814, in next
if len(self.__data) or self._refresh():
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/cursor.py", line 763, in _refresh
self.__uuid_subtype))
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/cursor.py", line 700, in __send_message
**kwargs)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/mongo_client.py", line 1006, in _send_message_with_response
self.__pool.maybe_return_socket(sock_info)
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/pool.py", line 358, in maybe_return_socket
if sock_info != self._get_request_state():
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/pool.py", line 84, in __ne__
return not self == other
File "/home/tbicr/Projects/cspw-ui.env/local/lib/python2.7/site-packages/pymongo/pool.py", line 78, in __eq__
def __eq__(self, other):
File "/home/tbicr/Soft/pycharm-129.103/helpers/pydev/pydevd.py", line 998, in trace_dispatch
traceback.print_exc()
File "/usr/lib/python2.7/traceback.py", line 232, in print_exc
print_exception(etype, value, tb, limit, file)
File "/usr/lib/python2.7/traceback.py", line 125, in print_exception
print_tb(tb, limit, file)
File "/usr/lib/python2.7/traceback.py", line 67, in print_tb
' File "%s", line %d, in %s' % (filename, lineno, name))
RuntimeError: maximum recursion depth exceeded
The text was updated successfully, but these errors were encountered:
If I subscribe to signals for delete event: I have
RuntimeError: maximum recursion depth exceeded
, because document delete called again and again: https://github.com/MongoEngine/mongoengine/blob/master/mongoengine/queryset/queryset.py#L430. Affected on 0.8.1, on 0.7.10 all worked right: f182daa.Log example:
The text was updated successfully, but these errors were encountered: