← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~arjan-i/openlp/check_dependencies_fix into lp:openlp

 

Arjan Schrijver has proposed merging lp:~arjan-i/openlp/check_dependencies_fix into lp:openlp.

Requested reviews:
  OpenLP Core (openlp-core)
Related bugs:
  Bug #1095699 in OpenLP: "check_dependencies.py fails on version numbers with letters"
  https://bugs.launchpad.net/openlp/+bug/1095699

For more details, see:
https://code.launchpad.net/~arjan-i/openlp/check_dependencies_fix/+merge/141931

fixed bug #1095699 'check_dependencies.py fails on version numbers with letters'
When version numbers are of type 'str', everything after the first non-numerical character is dropped, so '0.8.0b2' becomes '0.8.0'.
-- 
https://code.launchpad.net/~arjan-i/openlp/check_dependencies_fix/+merge/141931
Your team OpenLP Core is requested to review the proposed merge of lp:~arjan-i/openlp/check_dependencies_fix into lp:openlp.
=== modified file 'scripts/check_dependencies.py'
--- scripts/check_dependencies.py	2012-12-29 20:56:56 +0000
+++ scripts/check_dependencies.py	2013-01-04 15:09:27 +0000
@@ -38,6 +38,7 @@
 """
 import os
 import sys
+import re
 
 is_win = sys.platform.startswith('win')
 
@@ -90,6 +91,7 @@
 
 def check_vers(version, required, text):
     if type(version) is str:
+        version = re.sub(r'[^0-9.].*', r'', version)
         version = version.split('.')
         version = map(int, version)
     if type(required) is str:


Follow ups