src/eric7/Globals/__init__.py

branch
eric7
changeset 9771
4d72243909ff
parent 9747
b7976868d5b0
child 9832
3885b9d7bd31
child 9846
f5a17960408a
--- a/src/eric7/Globals/__init__.py	Thu Feb 16 11:33:56 2023 +0100
+++ b/src/eric7/Globals/__init__.py	Fri Feb 17 10:46:26 2023 +0100
@@ -138,6 +138,10 @@
     @return version named tuple containing the version parts
     @rtype semver.VersionInfo
     """
+    while version and not version[0].isdecimal():
+        # sanitize version string (get rid of leading non-decimal characters)
+        version = version[1:]
+
     if len(version.split(".")) < 3:
         # ensure the version string contains at least three parts
         version += ".0"

eric ide

mercurial