Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a retry to
detect_mount_points()
function
During a merscope pipeline analysis run, a dist-data-sync: Batch Data Sync Batch SubmitJob API call failed due to the following proximal causes: ``` File "/var/task/aibs_informatics_aws_utils/efs/mount_point.py", line 385, in detect_mount_points batch_mp_configs = _detect_moint_points_from_batch_job(batch_job_id) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/var/task/aibs_informatics_aws_utils/efs/mount_point.py", line 464, in _detect_moint_points_from_batch_job response = batch.describe_jobs(jobs=[batch_job_id]) ``` The last `batch.describe_jobs()` call eventually resulted in the error: `botocore.exceptions.NoCredentialsError: Unable to locate credentials` This commit tries to fix this by adding a retry to the `detect_mount_points()` function (which calls the `_detect_moint_points_from_batch_job() function) as well as a lambda version. This retry will only do so if a `NoCredentialsError` is encountered under the assumption that such an error is ephemeral.
- Loading branch information