Skip to content

python env setting

Hello Rivet team,

I wonder if we can synchronize the python executable settings uniformly as it sometimes crashes at the last stage of the plotting using rivet-mkhtml-mpl.

For example, if I use rivet-mkhtml-mpl in CMSSW environment

cat /cvmfs/cms.cern.ch/el9_amd64_gcc12/cms/cmssw/CMSSW_13_3_3/external/el9_amd64_gcc12/bin/rivet-mkhtml-mpl
#!/usr/bin/env python3

"""\
%(prog)s [options] <yodafile1> [<yodafile2> <yodafile3>...] [PLOT:Key1=Val1:...]

The env is given with python3 where nothing crashes. However because the actual plotting script, as you can see below

cat rivet-plots/MC_ZINC/Z_mass.py 
#! /usr/bin/env python

# This Python script was auto-generated using YODA v1.9.8.
# Analysis object: /MC_ZINC/Z_mass
# Timestamp: 04-10-2024 (15:28:13)

is given with python instead, at least for me with my environment it crashes (python3 has every mpl things while python does not, they are different in versions). Probably it will be the same for other people who still has python with python2 as default (although it is rare at this point) and somebody who has different versions set up for python and python3 will hit the same crash. I am wondering if this could be synchronized to use the same python setting and if not whether there is a reason not to do it.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information