Skip to content

Commit 768e660

Browse files
jackal1-66sawenzel
authored andcommitted
Replace simple string search with regular expression
When adding -colBkg the simple search was wrongly returning true
1 parent 4b2ac04 commit 768e660

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎MC/bin/o2dpg_sim_workflow_anchored.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -742,7 +742,7 @@ def main():
742742
forwardargs += " -tf " + str(args.tf) + " --sor " + str(effective_run_start) + " --timestamp " + str(timestamp) + " --production-offset " + str(prod_offset) + " -run " + str(args.run_number) + " --run-anchored --first-orbit " \
743743
+ str(effective_first_orbit) + " --orbitsPerTF " + str(GLOparams["OrbitsPerTF"]) + str(energyarg)
744744
# the following options can be overwritten/influenced from the outside
745-
if not '-col' in forwardargs:
745+
if not re.search(r'(?<!\S)-col(?=[\s=])', forwardargs):
746746
forwardargs += ' -col ' + ColSystem
747747
if not '--readoutDets' in forwardargs:
748748
forwardargs += ' --readoutDets ' + GLOparams['detList']

0 commit comments

Comments
 (0)