# HG changeset patch # User Rodrigo Damazio # Date 1531964199 25200 # Node ID 25880ddf9a86dc8abb6e5ae3e4f0252425fae264 # Parent c2586a6e588479249545aa4a1e01112f47dbd282 macosx: fixing macOS version generation after db9d1dd01bf0 With the Python3 change, the string is now something like version = b'4.6.2+848-88be288e8ac1' where it was previously just: version = '4.6.2+848-88be288e8ac1' Differential Revision: https://phab.mercurial-scm.org/D3964 diff -r c2586a6e5884 -r 25880ddf9a86 contrib/genosxversion.py --- a/contrib/genosxversion.py Tue Jul 10 17:01:06 2018 +0530 +++ b/contrib/genosxversion.py Wed Jul 18 18:36:39 2018 -0700 @@ -117,9 +117,9 @@ return with open(opts.versionfile) as f: for l in f: - if l.startswith('version = '): + if l.startswith('version = b'): # version number is entire line minus the quotes - ver = l[len('version = ') + 1:-2] + ver = l[len('version = b') + 1:-2] break if opts.paranoid: print(paranoidver(ver))