Home | News | Documentation | Download

PyROOT crash after canvas.GetListOfPrimitives() call


I am seeing a crash when calling the GetListOfPrimitives() function of a TCanvas object in PyROOT. See very simple example code below to reproduce it. In the simple example, the crash occurs when python exists. It does not occur if I comment out the GetListOfPrimitives() call. Any idea what could be wrong?

I am using Python 3.4 and ROOT v6-12-04.

Example code is:

import ROOT

The output is:

<ROOT.TList object ("TList") at 0x56081804a110>
pure virtual method called
terminate called without an active exception
Aborted (core dumped)

Some additional information. I’ve tested this with the ATLAS environment on lxplus and can reproduce it with root 6.12.04-x86_64-slc6-gcc62-opt and python 2.7. However everything is fine with 6.10.06-x86_64-slc6-gcc62-opt.

Some more information, to narrow it down a bit:

It worked with ROOT 6.11.02 and appeared after going to ROOT 6.12.06.
Python 2.7 for both, gcc version 7.2.0 (Ubuntu 7.2.0-8ubuntu3.2) for the latter (not sure what the gcc version was for the 6.11).

Note that this does not always happen. For me it happens with your example script (where the canvas is in the global namespace and the script ends afterwards). But it does not happen if it is in a function like this:

import ROOT

def f()
    c = ROOT.TCanvas()


our pyROOT expert, @etejedor, will be back soon.
This looks like a bug report though. It would be a big help if you could file it over at https://sft.its.cern.ch/jira/projects/ROOT


JIRA ticket created:

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.