#!/usr/bin/env python #this script runs cmsStage multiple times in the case where it failes for some reason from __future__ import print_function from builtins import range if __name__ == '__main__': import PhysicsTools.HeppyCore.utils.eostools as eostools eostools.setCAFPath() from cmsIO import * from cmsStage import * import sys, time #this taken from the main of cmsStage argv = sys.argv[1:] (args, debug, force ) = parseOpts( argv ) if not os.path.isfile(args[0]): print(args[0], 'does not exist.') sys.exit(1) source = cmsFile( args[0], "rfio" ) destination = cmsFile( args[1], "stageout" ) checkArgs( source, destination, force ) #find the destination LFN dest = args[1] if eostools.isDirectory(dest): dest = os.path.join(dest,os.path.basename(args[0]))
#!/usr/bin/env python #this script runs cmsStage multiple times in the case where it failes for some reason from __future__ import print_function from builtins import range if __name__ == '__main__': import PhysicsTools.HeppyCore.utils.eostools as eostools eostools.setCAFPath() from cmsIO import * from cmsStage import * import sys, time #this taken from the main of cmsStage argv = sys.argv[1:] (args, debug, force) = parseOpts(argv) if not os.path.isfile(args[0]): print(args[0], 'does not exist.') sys.exit(1) source = cmsFile(args[0], "rfio") destination = cmsFile(args[1], "stageout") checkArgs(source, destination, force) #find the destination LFN dest = args[1] if eostools.isDirectory(dest): dest = os.path.join(dest, os.path.basename(args[0]))