Skip to content

Commit

Permalink
working
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinpricethesecond committed Nov 5, 2024
1 parent 2cc2da4 commit 452bd68
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
9 changes: 2 additions & 7 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
1.7.0
1.7.1

Live-docs: https://tapis-project.github.io/live-docs/?service=GlobusProxy

Expand All @@ -9,9 +9,4 @@ New features:
- none

Bug fixes:
- fixed incorrect error code when globus errors happen while making a transfer
- fixed formatting of error logs
- fixed 400 error on GET when a content-type header is included
- added additional tenant
- better error messages for uncaught exceptions
- change schema to allow for larger file sizes
- fixed incorrect error code when performing operations on an endpoint/collection that has been deleted
7 changes: 6 additions & 1 deletion service/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,8 @@ def handle_transfer_error(exception, endpoint_id=None, msg=None):
error = GlobusInvalidRequestError(msg=message)
if exception.code == 404:
error = EndpointNotFoundError(msg=exception.message)
if exception.code == 'EndpointDeleted':
error = EndpointNotFoundError(msg=exception.message)
logger.error(error)
return error

Expand Down Expand Up @@ -331,7 +333,10 @@ def precheck(client_id, endpoints, access_token, refresh_token):
endpoints = list(endpoints.split())
logger.debug(f'have ep list:: {endpoints}')
for endpoint_id in endpoints:
endpoint_info = transfer_client.get_endpoint(endpoint_id)
try:
endpoint_info = transfer_client.get_endpoint(endpoint_id)
except TransferAPIError as e:
raise handle_transfer_error(e)
endpoint_type = endpoint_info["entity_type"]
if endpoint_type == "GCP_mapped_collection": # if it's a globus connect personal ep
connected = is_endpoint_connected(transfer_client, endpoint_id)
Expand Down

0 comments on commit 452bd68

Please sign in to comment.