Name of head slots replaced by the name of a project
The following discussion from !475 (merged) should be addressed:
-
@clemenci started a discussion: (+1 comment) This is causing the nightly and ci-builds to fail before starting.
The bug is subtle: the loop overrides the value of name before it's used to create the slot a few lines below, thus creating a few slots called
MooreAnalysis
, which translates in the error:Traceback (most recent call last): File "/build/jenkins-tests/workspace/nightly-builds/main/venv/bin/lbn-enabled-slots", line 8, in <module> sys.exit(enabled_slots()) File "/build/jenkins-tests/workspace/nightly-builds/main/venv/lib/python2.7/site-packages/LbNightlyTools/Scripts/_entry_points.py", line 54, in enabled_slots return Script().run() File "/build/jenkins-tests/workspace/nightly-builds/main/venv/lib/python2.7/site-packages/LbCommon/Script.py", line 107, in run rc = self.main() File "/build/jenkins-tests/workspace/nightly-builds/main/venv/lib/python2.7/site-packages/LbNightlyTools/Scripts/EnabledSlots.py", line 134, in main slots = loadConfig(self.options.config_dir).values() File "/build/jenkins-tests/workspace/nightly-builds/main/venv/lib/python2.7/site-packages/LbNightlyTools/Configuration.py", line 2239, in loadConfig slot.name, slot_dict[slot.name]._source, slot._source) AssertionError: Slot MooreAnalysis defined in 2 places: lhcbnightlyconf.Main and lhcbnightlyconf.Main
Too bad that the CI jobs are not exposing the problem.
I'll commit the fix in the next few minutes and take note to improve the sanity check.