summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Ombredanne <pombredanne@nexb.com>2021-11-17 14:47:39 +0100
committerRaphaƫl Barrois <raphael.barrois@polytechnique.org>2022-02-06 20:08:48 +0100
commit47be07eb4a632850b28cc584b4caa54ed02cd924 (patch)
treea7713fa916e86e65be77053cd1293c1f75bb7b5b
parent8a7162fc01b33964688a5be41df3865bceb875c3 (diff)
downloadsemantic-version-47be07eb4a632850b28cc584b4caa54ed02cd924.tar.gz
Update the Version.parse() to match the code
The docstring was lying by saying a Version object was returned. Rather this function returns a tuple of version parts. Signed-off-by: Philippe Ombredanne <pombredanne@nexb.com>
-rw-r--r--semantic_version/base.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/semantic_version/base.py b/semantic_version/base.py
index 871ccb0..82a9af0 100644
--- a/semantic_version/base.py
+++ b/semantic_version/base.py
@@ -290,7 +290,8 @@ class Version(object):
@classmethod
def parse(cls, version_string, partial=False, coerce=False):
- """Parse a version string into a Version() object.
+ """Parse a version string into a tuple of components:
+ (major, minor, patch, prerelease, build).
Args:
version_string (str), the version string to parse