Skip to content

Commit

Permalink
Stricter error for alignment with no --chromosomes listed
Browse files Browse the repository at this point in the history
  • Loading branch information
josiahseaman committed Jun 8, 2018
1 parent 3aa088a commit 3cd2580
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions DDV/fluentdna.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ def main():
parser.add_argument("-ch", "--chromosomes",
nargs='+',
type=str,
help="Chromosome to parse from Chain File. NOTE: Defaults to 'chr21' for testing.",
help="Chromosome to parse from Chain File. REQUIRED for alignments.",
dest="chromosomes")
parser.add_argument("-t", "--separate_translocations",
action='store_true',
Expand Down Expand Up @@ -499,7 +499,8 @@ def main():
args.layout = "NONE"

if not args.chromosomes and args.chain_file and args.layout != 'unique':
args.chromosomes = ['chr21']
print("Error: you must list the name of a scaffold you wish to display for an alignment.\n"
"Example: --chromosomes chrM chrX --chain_file=input.chain.liftover", file=sys.stderr)

if args.output_name and args.chain_file and args.output_name[-1] != '_':
args.output_name += '_' # prefix should always end with an underscore
Expand Down

0 comments on commit 3cd2580

Please sign in to comment.