Skip to content
Open
3 changes: 3 additions & 0 deletions envs.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[smaht-submitr-pEqN3rsm]
minor = "3.11"
patch = "3.11.5"
997 changes: 555 additions & 442 deletions poetry.lock

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "smaht-submitr"
version = "1.16.0"
version = "1.16.0.1b2"
description = "Support for uploading file submissions to SMAHT."
# TODO: Update this email address when a more specific one is available for SMaHT.
authors = ["SMaHT DAC <smhelp@hms-dbmi.atlassian.net >"]
Expand Down Expand Up @@ -47,7 +47,8 @@ include = [

python = ">=3.10,<3.13"
boto3 = "^1.43.58"
dcicutils = "^8.19.0"
# dcicutils = "^8.19.0"
dcicutils = { git = "https://github.com/4dn-dcic/utils.git", branch = "fm/protected-donor-dcicutils" }
PyYAML = "^6.0.1"
requests = "^2.31.0"
googleapi = "^0.1.0"
Expand Down
12 changes: 11 additions & 1 deletion submitr/scripts/submit_metadata_bundle.py
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,10 @@ def main(simulated_args_for_testing=None):
parser.add_argument('--timeout', help="Wait timeout for server validation/submission.")
parser.add_argument('--debug', action="store_true", help="Debug output.", default=False)
parser.add_argument('--debug-sleep', help="Sleep on each row read for troubleshooting/testing.", default=False)
# Retained as a hidden compatibility switch for internal workflows/tests.
parser.add_argument('--no-transform-protected-donor', action="store_true",
help=argparse.SUPPRESS, default=False)
parser.add_argument('--save-transformed-workbook', help=argparse.SUPPRESS, default=None)
parser.add_argument('--skip-validator', action='append', dest='skip_validators',
help=argparse.SUPPRESS, default=None)
parser.add_argument('--ping', action="store_true", help="Ping server.", default=False)
Expand Down Expand Up @@ -336,6 +340,10 @@ def main(simulated_args_for_testing=None):
else:
args.timeout = int(args.timeout)

if args.no_transform_protected_donor and args.save_transformed_workbook:
PRINT("May not specify both --no-transform-protected-donor and --save-transformed-workbook.")
sys.exit(2)

if args.info:
if not os.path.exists(args.bundle_filename):
PRINT(f"File does not exist: {args.bundle_filename}")
Expand Down Expand Up @@ -392,7 +400,9 @@ def main(simulated_args_for_testing=None):
timeout=args.timeout,
debug=args.debug,
debug_sleep=args.debug_sleep,
skip_validators=args.skip_validators)
skip_validators=args.skip_validators,
transform_protected_donor=not args.no_transform_protected_donor,
transformed_workbook_path=args.save_transformed_workbook)


def _sanity_check_submitted_file(file_name: str) -> bool:
Expand Down
Loading
Loading