Skip to content

dirac-test-script: replace import at the proper place

bash-4.2$ dirac-test-plugin --Plugin=RemoveReplicas --FromSEs=CERN-CTA-DC1 --LFN=/lhcb/data/2017/RAW/FULL/LHCb/COLLISION17/193988/193988_0000000197.raw
Traceback (most recent call last):
  File "/cvmfs/lhcb.cern.ch/lhcbdirac/prod/LHCbDIRAC/TransformationSystem/scripts/dirac_test_plugin.py", line 501, in <module>
    main()
  File "/cvmfs/lhcb.cern.ch/lhcbdirac/prod/DIRAC/Core/Utilities/DIRACScript.py", line 42, in __call__
    return self._func()  # pylint: disable=not-callable
  File "/cvmfs/lhcb.cern.ch/lhcbdirac/prod/LHCbDIRAC/TransformationSystem/scripts/dirac_test_plugin.py", line 314, in main
    gLogger.showHeaders()
UnboundLocalError: local variable 'gLogger' referenced before assignment

I've opened an issue against pylint, such that we hopefully get an error in the future (https://github.com/PyCQA/pylint/issues/4624)

BEGINRELEASENOTES

*TS

FIX: correct order of import in dirac-test-script

ENDRELEASENOTES

Merge request reports