diff --git a/HLTrigger/Configuration/python/Tools/options.py b/HLTrigger/Configuration/python/Tools/options.py index 2129f8d1468f0..cdfdadd2dc9f9 100644 --- a/HLTrigger/Configuration/python/Tools/options.py +++ b/HLTrigger/Configuration/python/Tools/options.py @@ -132,27 +132,27 @@ def __init__(self): # convert HLT and L1 menus to a dedicated object representation on the fly def __setattr__(self, name, value): - if name is 'menu' and not isinstance(value, ConnectionHLTMenu): + if name == 'menu' and not isinstance(value, ConnectionHLTMenu): # format 'menu' as needed object.__setattr__(self, name, ConnectionHLTMenu(value)) - elif name is 'l1' and not isinstance(value, ConnectionL1TMenu): + elif name == 'l1' and not isinstance(value, ConnectionL1TMenu): # format '--l1' as needed object.__setattr__(self, name, ConnectionL1TMenu(value)) - elif name is 'l1Xml' and not isinstance(value, ConnectionL1TMenuXml): + elif name == 'l1Xml' and not isinstance(value, ConnectionL1TMenuXml): # format '--l1Xml' as needed object.__setattr__(self, name, ConnectionL1TMenuXml(value)) - elif name is 'open' and value: + elif name == 'open' and value: # '--open' implies '--unprescale' object.__setattr__(self, 'open', True) object.__setattr__(self, 'prescale', "none") - elif name is 'prescale' and value is not None: + elif name == 'prescale' and value is not None: # '--open' overrides '--prescale', set the prescale value only if '--open' is not set if not self.open: object.__setattr__(self, 'prescale', value) - elif name is 'profiling' and value: + elif name == 'profiling' and value: # '--profiling' object.__setattr__(self, 'profiling', True) - elif name is 'timing' and value: + elif name == 'timing' and value: # '--timing' implies '--profiling' object.__setattr__(self, 'timing', True) object.__setattr__(self, 'profiling', True) diff --git a/HLTrigger/Configuration/test/getDatasets.py b/HLTrigger/Configuration/test/getDatasets.py index 2d25f01e7e2ec..e9a551f485714 100755 --- a/HLTrigger/Configuration/test/getDatasets.py +++ b/HLTrigger/Configuration/test/getDatasets.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env python3 import sys import subprocess diff --git a/HLTrigger/Configuration/test/getEventContent.py b/HLTrigger/Configuration/test/getEventContent.py index a8a8d4f824b5c..0f14ed67305d7 100755 --- a/HLTrigger/Configuration/test/getEventContent.py +++ b/HLTrigger/Configuration/test/getEventContent.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env python3 import sys import subprocess