diff --git a/h5pyd/_hl/files.py b/h5pyd/_hl/files.py index 63b00c1e..a3a642ca 100644 --- a/h5pyd/_hl/files.py +++ b/h5pyd/_hl/files.py @@ -190,6 +190,10 @@ def __init__(self, domain, mode=None, endpoint=None, username=None, password=Non elif "hs_endpoint" in cfg: endpoint = cfg["hs_endpoint"] + # remove the trailing slash on endpoint if it exists + if endpoint.endswith('/'): + endpoint = endpoint.strip('/') + if username is None: if "H5SERV_USERNAME" in os.environ: username = os.environ["H5SERV_USERNAME"]