This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author behackett
Recipients behackett, emptysquare, martin.panter, serhiy.storchaka, vstinner
Date 2015-09-24.17:10:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1443114620.7.0.430476486823.issue25222@psf.upfronthosting.co.za>
In-reply-to
Content
> File "D:\buildarea\3.4.bolen-windows10\build\lib\test\test_json\test_recursion.py", line 96 in test_endless_recursion

That test (and reason for existence) is almost exactly the same as the PyMongo test that causes abort reported in this ticket. I'm not surprised it is also failing. test_pickle appears to have a similar issue. For test_json see here:

https://hg.python.org/cpython/rev/a21f5af476cb

And PyMongo's equivalent test:

https://github.com/mongodb/mongo-python-driver/blob/4bbe2133a14df716b1dffe8ab7957ed67149b2cd/test/test_bson.py#L538-L543

> I'm unable to reproduce the issue on Linux.

The abort is very rare for me on Linux, so much so that I originally thought it only occurred on Windows. I can't reproduce it on a local Linux machine, but it has happened inconsistently in our Jenkins cluster. For example (note that this run includes a commit that uses sys.setrecursionlimit(250) and still aborts):

https://jenkins.mongodb.com/view/Python/job/mongo-python-driver/404/extensions=without-extensions,label=linux64,mongodb_configuration=single_server,mongodb_option=noauth,mongodb_server=26-release,python_language_version=3.5/console

> First I tried with no MongoDB server running. Then I tried with a MongoDB server running.

The problem only occurs for me when testing with a MongoDB instance running. Running background threads seem to be a key requirement for reproduction. Note also that this problem does not reproduce when using PyMongo's C extensions, only when using the pure python BSON encoder. You can run the tests like this from a clean git checkout:

python3.5 setup.py --no_ext test

> I don't have exactly the same version (I'm reading pymongo 3.0.3 source)

Clone master from github:

https://github.com/mongodb/mongo-python-driver

> @Bernie: Would you be able to get a C backtrace using gdb on such crash?

Not likely, since I can't reproduce it under Linux locally. But I *can* reproduce it consistently on a Windows 7 machine that has VS2015. I'll see what I can get out of the Visual Studio debugger and report back.
History
Date User Action Args
2015-09-24 17:10:20behackettsetrecipients: + behackett, vstinner, martin.panter, serhiy.storchaka, emptysquare
2015-09-24 17:10:20behackettsetmessageid: <1443114620.7.0.430476486823.issue25222@psf.upfronthosting.co.za>
2015-09-24 17:10:20behackettlinkissue25222 messages
2015-09-24 17:10:20behackettcreate