TrackClustersMapper only considers the first event
Reported by @vlisovsk:
Good morning, I would like to report an issue with the TupleToolDEDX spotted first by @jnicolin. In her case, some (1 permille) jobs failed on the grid due to this issue, and here I attach a minimal(-ish) reproducible example.
If the attached script is run with
lb-run -c best DaVinci/v46r4 gaudirun.py Lbellell_debug.py
, one getstuple_eeLine FATAL Tool 'TupleToolDEDX' acting on particle 'L1' returned a failure status. tuple_eeLine FATAL Tool 'TupleToolDEDX' acting on particle 'L2' returned a failure status. tuple_eeLine FATAL Failed to fill a candidate. Please fix your options. tuple_eeLine FATAL ### NOTE : This is a new behaviour since bug https://its.cern.ch/jira/browse/LHCBPS-690 tuple_eeLine FATAL ### NOTE : If you think this is wrong, report to lhcb-davinci@cern.ch
However, if one sets
DaVinci().SkipEvents = 1
the crash does not happen and the code runs smoothly. This happens only on certain (very few) MDSTs, two of them are referenced at the end of my example script. I also link there one MDST which is "normal" where the crash does never happen.
The underlying issue is that the TrackClustersMapper
tool has a cache (m_streamsDone
) which remembers that the first event didn't have any Velo clusters. The cache is never reset so it effecitvely remembers what happened in all later events:
-
master
: https://gitlab.cern.ch/lhcb/LHCb/-/blob/0f1e65a9e8e575871598188c3a200cac7603de9f/Event/EventPacker/src/component/TrackClustersMapper.cpp#L136-154 -
run2-patches
: https://gitlab.cern.ch/lhcb/LHCb/-/blob/289be64a6a404f89ff9f98e0a12f9faeaa06e311/Event/EventPacker/src/component/TrackClustersMapper.cpp#L70-90
This code is in both run2-patches
and master
.