Skip to content

Commit

Permalink
more detailed error
Browse files Browse the repository at this point in the history
  • Loading branch information
BerndSchuller committed Nov 8, 2024
1 parent bc86bbc commit 2019d61
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pyunicore/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -701,8 +701,10 @@ def _wait_until_ready(self, timeout=30):
if "INITIALIZING" == st:
time.sleep(1)
i += 1
if "ERROR" == st or (timeout > 0 and i > timeout):
raise OSError()
if "ERROR" == st:
raise OSError("Storage error")
if timeout > 0 and i > timeout:
raise OSError("Timeout waiting for Storage to become useable")

def _to_file_url(self, path):
return (
Expand Down

0 comments on commit 2019d61

Please sign in to comment.