Access violation in Python garbage collector (visit_decref) - how to debug?

Chris Angelico rosuav at gmail.com
Fri Oct 4 15:52:27 EDT 2019


On Sat, Oct 5, 2019 at 5:38 AM Geoff Bache <geoff.bache at gmail.com> wrote:
>
> Hi all,
>
> We are running Python embedded in our C++ product and are now experiencing
> crashes (access violation reading 0xffffffffff on Windows) in the Python
> garbage collector.
>
> We got this on Python 3.6.4 originally, but I can reproduce it with both
> Python 3.6.8 and Python 3.7.4.
>
> The chances of producing a minimal example that reproduces it reliably are
> currently small I would say. All attempts to simplify the set up seem to
> cause the problem to go away.
> Indeed I can only reproduce it by sending a fairly large amount of data 2
> or 3 times to our server - sending either half of the data does not
> reproduce it.

Have you tried to reproduce the issue outside of your application?
Even if it means creating a gigantic Python script with a whopping
triple-quoted string for the input data, it'd be helpful to try this.
If you CAN repro the problem, it'd be way easier to diagnose (since we
don't need your code, just your test case); and if you CAN'T, it may
mean an issue with the embedding aspects.

What's your definition of "fairly large" here? How many
kilobytes/megabytes/gigabytes, and how deeply nested is the JSON
object?

ChrisA



More information about the Python-list mailing list