From 29ed46e12bdc0d947d6eda9d510e7cea781696fb Mon Sep 17 00:00:00 2001 From: Eric House Date: Sat, 11 Apr 2020 19:23:20 -0700 Subject: [PATCH] fix so upgrade of release builds works --- xwords4/android/scripts/info.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xwords4/android/scripts/info.py b/xwords4/android/scripts/info.py index e74828eb7..387e396ed 100755 --- a/xwords4/android/scripts/info.py +++ b/xwords4/android/scripts/info.py @@ -204,7 +204,7 @@ def getOrderedApks( path, appID, debug ): files = ((os.stat(apk).st_mtime, apk) for apk in glob.glob(pattern)) for mtime, file in sorted(files, reverse=True): info = getAAPTInfo(file) - if info['appID'] == appID: + if info and 'appID' in info and info['appID'] == appID: apkToCode[file] = info['versionCode'] apkToMtime[file] = mtime result = sorted(apkToCode.keys(), reverse=True, key=lambda file: (apkToCode[file], apkToMtime[file])) @@ -326,7 +326,7 @@ def getApp( params, name = None, debug = False): apache.log_error( "name: %s; installer: %s; gvers: %s" % (name, installer, vers) ) print "name: %s; installer: %s; vers: %s" % (name, installer, vers) - dir = k_filebase + k_apkDir + 'rel/' + dir = k_filebase + k_apkDir apk = getNextAfter( dir, name, vers, debug ) if apk: apk = apk[len(k_filebase):] # strip fs path @@ -569,7 +569,7 @@ def getUpdates( req, params ): # result[k_XLATEINFO] = xlateResult; result = json.dumps( result ) - # apache.log_error( result ) + apache.log_error( 'getUpdates() => ' + result ) return result def clearShelf():