diff options
author | Gauvain Pocentek <gauvain@pocentek.net> | 2017-05-20 10:24:08 +0200 |
---|---|---|
committer | Gauvain Pocentek <gauvain@pocentek.net> | 2017-05-23 15:41:54 +0200 |
commit | c02dabd25507a14d666e85c7f1ea7831c64d0394 (patch) | |
tree | b44597e02ee6811764b54ae123f315caee007969 /gitlab/config.py | |
parent | ce3dd0d1ac3fbed3cf671720e273470fb1ccdbc6 (diff) | |
download | gitlab-c02dabd25507a14d666e85c7f1ea7831c64d0394.tar.gz |
Initial, non-functional v4 support
Diffstat (limited to 'gitlab/config.py')
-rw-r--r-- | gitlab/config.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gitlab/config.py b/gitlab/config.py index 3ef2efb..9af804d 100644 --- a/gitlab/config.py +++ b/gitlab/config.py @@ -88,3 +88,12 @@ class GitlabConfigParser(object): 'http_password') except Exception: pass + + self.api_version = '3' + try: + self.api_version = self._config.get(self.gitlab_id, 'api_version') + except Exception: + pass + if self.api_version not in ('3', '4'): + raise GitlabDataError("Unsupported API version: %s" % + self.api_version) |