Пример #1
0
def addDirectory(sample, hdp_dir, user):
	"""proxy to smartsubmit.absorbDirectory, makes sure the file descriptor used for thread printing is closed"""
	try:
		ss.absorbDirectory(sample, hdp_dir, user)
	except Exception as err:
		print("There was an error adding the directory '%s' to the sample '%s'" % (hdp_dir, sample))
		print(err)
		logging.error("There was an error adding the directory '%s'" % hdp_dir)
		logging.exception(err)
	tp.closeThreadFile(threading.currentThread().name)
Пример #2
0
def addDirectory(sample, hdp_dir, user):
    """proxy to smartsubmit.absorbDirectory, makes sure the file descriptor used for thread printing is closed"""
    try:
        ss.absorbDirectory(sample, hdp_dir, user)
    except Exception as err:
        print("There was an error adding the directory '%s' to the sample '%s'" % (hdp_dir, sample))
        print(err)
        logging.error("There was an error adding the directory '%s'" % hdp_dir)
        logging.exception(err)
    tp.closeThreadFile(threading.currentThread().name)
Пример #3
0
def addFile(sample, hdp_path, user):
	"""proxy to smartsubmit.absorbSampleFile, makes sure the file descriptor used for thread printing is closed"""
	try:
		ss.absorbSampleFile(sample, hdp_path, user)
	except Exception as err:
		print("There was an error adding the file '%s' into sample '%s'" % (os.path.basename(hdp_path), sample))
		print(err)
		logging.error("There was an error adding the file '%s' into sample '%s'" % (os.path.basename(hdp_path), sample))
		logging.exception(err)
	tp.closeThreadFile(threading.currentThread().name)
Пример #4
0
def addFile(sample, hdp_path, user):
    """proxy to smartsubmit.absorbSampleFile, makes sure the file descriptor used for thread printing is closed"""
    try:
        ss.absorbSampleFile(sample, hdp_path, user)
    except Exception as err:
        print("There was an error adding the file '%s' into sample '%s'" % (os.path.basename(hdp_path), sample))
        print(err)
        logging.error("There was an error adding the file '%s' into sample '%s'" % (os.path.basename(hdp_path), sample))
        logging.exception(err)
    tp.closeThreadFile(threading.currentThread().name)