def check_specs(args):
hostname = socket.gethostname()
specs = args.specs
if not specs:
martian.exit("Cannot create samplesheet with empty specs.")
for spec in specs:
check_spec(spec)
if len(specs) > 1 and any([spec.get('csv') is not None for spec in specs]):
martian.exit("Cannot combine specs for CSV plus additional entries")
# check for samplesheet
csv_specs = [spec for spec in specs if spec.get('csv')]
if csv_specs:
csv_spec = csv_specs[0]
csv_path = csv_spec['csv']
tk_preflight.check_file("samplesheet", csv_path, hostname)
is_iem = tk_sheet.file_is_iem_samplesheet(csv_path)
is_csv = tk_sheet.file_is_simple_samplesheet(csv_path)
if not (is_iem or is_csv):
martian.exit("Formatting error in sample sheet: %s" % csv_path)
评论列表
文章目录