From a1d7663f146571cdd0044969ec228f85b2bc65f5 Mon Sep 17 00:00:00 2001 From: Vanessa Sochat Date: Fri, 10 May 2019 13:46:06 -0400 Subject: [PATCH] fixing bug that the registry api base needs to end with api Signed-off-by: Vanessa Sochat --- CHANGELOG.md | 1 + sregistry/main/registry/__init__.py | 3 ++- sregistry/version.py | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ee5f4cf..4274908 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ and **Merged pull requests**. Critical items to know are: The versions coincide with releases on pip. Only major versions will be released as tags on Github. ## [0.0.x](https://github.com/singularityhub/sregistry-cli/tree/master) (0.0.x) + - bug with sregistry push api endpoint, needs to end with api (0.01.41) - docker auth is undefined, and storage attribute needs to be checked for naming (0.01.40) - fixing bug with tag specification for registry pull (0.01.39) - registry client should honor base, if provided with uri (0.01.38) diff --git a/sregistry/main/registry/__init__.py b/sregistry/main/registry/__init__.py index 188c948..c2db41f 100644 --- a/sregistry/main/registry/__init__.py +++ b/sregistry/main/registry/__init__.py @@ -31,8 +31,9 @@ def __init__(self, secrets=None, base=None, **kwargs): def _update_base(self): if self.base is not None: + self.base = self.base.strip('/') if not self.base.endswith('api'): - self.base = self.base.strip('/') + self.base = "%s/api" % self.base def _read_response(self,response, field="detail"): diff --git a/sregistry/version.py b/sregistry/version.py index 0d95a0c..86053d7 100644 --- a/sregistry/version.py +++ b/sregistry/version.py @@ -8,7 +8,7 @@ ''' -__version__ = "0.1.40" +__version__ = "0.1.41" AUTHOR = 'Vanessa Sochat' AUTHOR_EMAIL = 'vsochat@stanford.edu' NAME = 'sregistry'