Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broaden ONT transfer script's categorization of QC runs #424

Merged
merged 2 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions VERSIONLOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# TACA Version Log

## 20240507.1

Broaden ONT transfer script's categorization of QC runs to either experiment dir or sample dir starting with "QC\_".

## 20240422.1

Refine GHA VERSIONLOG.md check to compare to merge-base, not branch-base.
Expand Down
5 changes: 3 additions & 2 deletions taca/nanopore/instrument_transfer.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,9 @@ def main(args):
for run_path in run_paths:
logging.info(f"Handling {run_path}...")

if run_path.split(os.sep)[-2][0:3] == "QC_":
# For QC runs, the sample name should start with "QC_"
experiment_name = run_path.split(os.sep)[-3]
sample_name = run_path.split(os.sep)[-2]
if sample_name[0:3] == "QC_" or experiment_name[0:3] == "QC_":
logging.info("Run categorized as QC.")
rsync_dest = args.dest_dir_qc
else:
Expand Down
2 changes: 1 addition & 1 deletion taca/utils/misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def query_yes_no(question, default="yes", force=False):
elif default == "no":
prompt = " [y/N] "
else:
raise ValueError('invalid default answer: "%s"' % default)
raise ValueError(f'invalid default answer: "{default}"')

while True:
sys.stdout.write(question + prompt)
Expand Down
Loading