Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
except CommandLineError as e:
parser.error(str(e))
return # avoid IDE warnings below
logger.info("Processing reads on %d core%s in %s mode ...",
cores, 's' if cores > 1 else '',
{False: 'single-end', True: 'paired-end'}[pipeline.paired])
try:
with runner as r:
stats = r.run()
except KeyboardInterrupt:
print("Interrupted", file=sys.stderr)
sys.exit(130)
except BrokenPipeError:
sys.exit(1)
except (dnaio.FileFormatError, dnaio.UnknownFileFormat, EOFError) as e:
sys.exit("cutadapt: error: {}".format(e))
elapsed = time.time() - start_time
if args.report == 'minimal':
report = minimal_report
else:
report = full_report
logger.log(REPORT, '%s', report(stats, elapsed, args.gc_content / 100))
if profiler is not None:
import pstats
profiler.disable()
pstats.Stats(profiler).sort_stats('time').print_stats(20)