Skip to content
Permalink
Browse files
AIRAVATA-3460 Pass path as query param to handle full resource path p…
…aths when creating a directory
  • Loading branch information
machristie committed Jul 15, 2021
1 parent 46c15e6 commit f30958b5122818028da366a978cb2e92383838be
Showing 1 changed file with 4 additions and 6 deletions.
@@ -276,9 +276,8 @@ def dir_exists(request, path, storage_resource_id=None, experiment_id=None):
"Return True if path exists in user's data store."
if _is_remote_api():
resp = _call_remote_api(request,
"/user-storage/~/{path}",
path_params={"path": path},
params={"experiment-id": experiment_id},
"/user-storage/~/",
params={"path": path, "experiment-id": experiment_id},
raise_for_status=False)
if resp.status_code == HTTPStatus.NOT_FOUND:
return False
@@ -502,9 +501,8 @@ def listdir(request, path, storage_resource_id=None, experiment_id=None):

if _is_remote_api():
resp = _call_remote_api(request,
"/user-storage/~/{path}",
path_params={"path": path},
params={"experiment-id": experiment_id},
"/user-storage/~/",
params={"path": path, "experiment-id": experiment_id},
)
data = resp.json()
for directory in data['directories']:

0 comments on commit f30958b

Please sign in to comment.