mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-10-05 18:50:09 +02:00
Merge branch 'fix-ci' into 'master'
fix the current crop of new CI failures See merge request fdroid/fdroidserver!1327
This commit is contained in:
commit
99be8d679d
@ -888,7 +888,6 @@ timeout_event = threading.Event()
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global options, config, buildserverid, fdroidserverid
|
global options, config, buildserverid, fdroidserverid
|
||||||
|
|
||||||
options, parser = parse_commandline()
|
options, parser = parse_commandline()
|
||||||
|
@ -590,7 +590,6 @@ start_timestamp = time.gmtime()
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -51,11 +51,7 @@ import tempfile
|
|||||||
import json
|
import json
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
# TODO change to only import defusedxml once its installed everywhere
|
import defusedxml.ElementTree as XMLElementTree
|
||||||
try:
|
|
||||||
import defusedxml.ElementTree as XMLElementTree
|
|
||||||
except ImportError:
|
|
||||||
import xml.etree.ElementTree as XMLElementTree # nosec this is a fallback only
|
|
||||||
|
|
||||||
from base64 import urlsafe_b64encode
|
from base64 import urlsafe_b64encode
|
||||||
from binascii import hexlify
|
from binascii import hexlify
|
||||||
@ -4239,8 +4235,8 @@ def auto_install_ndk(build):
|
|||||||
for n in ndk:
|
for n in ndk:
|
||||||
_install_ndk(n)
|
_install_ndk(n)
|
||||||
else:
|
else:
|
||||||
BuildException(_('Invalid ndk: entry in build: "{ndk}"')
|
raise BuildException(_('Invalid ndk: entry in build: "{ndk}"')
|
||||||
.format(ndk=str(ndk)))
|
.format(ndk=str(ndk)))
|
||||||
|
|
||||||
|
|
||||||
def _install_ndk(ndk):
|
def _install_ndk(ndk):
|
||||||
|
@ -42,7 +42,6 @@ def status_update_json(signed):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -183,7 +183,6 @@ def get_app_from_url(url):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -49,7 +49,6 @@ def disable_in_config(key, value):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global options, config
|
global options, config
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -44,7 +44,6 @@ def devices():
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global options, config
|
global options, config
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -697,7 +697,6 @@ def check_updates_ucm_http_aum_pattern(app): # noqa: D403
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
@ -754,7 +753,6 @@ def main():
|
|||||||
|
|
||||||
# only run yamllint when linting individual apps.
|
# only run yamllint when linting individual apps.
|
||||||
if options.appid or options.force_yamllint:
|
if options.appid or options.force_yamllint:
|
||||||
|
|
||||||
# run yamllint on app metadata
|
# run yamllint on app metadata
|
||||||
ymlpath = Path('metadata') / (appid + '.yml')
|
ymlpath = Path('metadata') / (appid + '.yml')
|
||||||
if ymlpath.is_file():
|
if ymlpath.is_file():
|
||||||
|
@ -160,7 +160,6 @@ def get_repo_base_url(clone_url, repo_git_base, force_type=None):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
parser = ArgumentParser()
|
parser = ArgumentParser()
|
||||||
common.setup_global_opts(parser)
|
common.setup_global_opts(parser)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
|
@ -24,7 +24,6 @@ options = None
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
parser = ArgumentParser()
|
parser = ArgumentParser()
|
||||||
common.setup_global_opts(parser)
|
common.setup_global_opts(parser)
|
||||||
metadata.add_metadata_arguments(parser)
|
metadata.add_metadata_arguments(parser)
|
||||||
|
@ -45,7 +45,6 @@ def proper_format(app):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
parser = ArgumentParser()
|
parser = ArgumentParser()
|
||||||
|
@ -175,7 +175,6 @@ def status_update_json(signed):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
parser = ArgumentParser()
|
parser = ArgumentParser()
|
||||||
|
@ -2150,7 +2150,6 @@ start_timestamp = time.gmtime()
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global config, options
|
global config, options
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
|
@ -146,7 +146,6 @@ def write_json_report(url, remote_apk, unsigned_apk, compare_result):
|
|||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
||||||
global options, config
|
global options, config
|
||||||
|
|
||||||
# Parse command line...
|
# Parse command line...
|
||||||
@ -192,7 +191,6 @@ def main():
|
|||||||
vercodes = common.read_pkg_args(options.appid, True)
|
vercodes = common.read_pkg_args(options.appid, True)
|
||||||
|
|
||||||
for apkfile in sorted(glob.glob(os.path.join(unsigned_dir, '*.apk'))):
|
for apkfile in sorted(glob.glob(os.path.join(unsigned_dir, '*.apk'))):
|
||||||
|
|
||||||
apkfilename = os.path.basename(apkfile)
|
apkfilename = os.path.basename(apkfile)
|
||||||
url = 'https://f-droid.org/repo/' + apkfilename
|
url = 'https://f-droid.org/repo/' + apkfilename
|
||||||
appid, vercode = common.publishednameinfo(apkfile)
|
appid, vercode = common.publishednameinfo(apkfile)
|
||||||
@ -205,7 +203,6 @@ def main():
|
|||||||
processed.add(appid)
|
processed.add(appid)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
||||||
logging.info("Processing {apkfilename}".format(apkfilename=apkfilename))
|
logging.info("Processing {apkfilename}".format(apkfilename=apkfilename))
|
||||||
|
|
||||||
remote_apk = os.path.join(tmp_dir, apkfilename)
|
remote_apk = os.path.join(tmp_dir, apkfilename)
|
||||||
|
@ -52,6 +52,8 @@ confidence = ["HIGH", "INFERENCE"]
|
|||||||
|
|
||||||
# TODO many of these could be fixed if someone wants to spend the time
|
# TODO many of these could be fixed if someone wants to spend the time
|
||||||
disable = [
|
disable = [
|
||||||
|
"broad-exception-caught",
|
||||||
|
"broad-exception-raised",
|
||||||
"consider-iterating-dictionary",
|
"consider-iterating-dictionary",
|
||||||
"consider-using-sys-exit",
|
"consider-using-sys-exit",
|
||||||
"invalid-name",
|
"invalid-name",
|
||||||
|
@ -442,7 +442,6 @@ class BuildTest(unittest.TestCase):
|
|||||||
self.assertEqual(0, count, "Shouldn't error on jar from extlib")
|
self.assertEqual(0, count, "Shouldn't error on jar from extlib")
|
||||||
|
|
||||||
def test_failed_verifies_are_not_in_unsigned(self):
|
def test_failed_verifies_are_not_in_unsigned(self):
|
||||||
|
|
||||||
os.chdir(self.testdir)
|
os.chdir(self.testdir)
|
||||||
sdk_path = os.path.join(self.testdir, 'android-sdk')
|
sdk_path = os.path.join(self.testdir, 'android-sdk')
|
||||||
self.create_fake_android_home(sdk_path)
|
self.create_fake_android_home(sdk_path)
|
||||||
|
@ -31,7 +31,6 @@ class DeployTest(unittest.TestCase):
|
|||||||
fdroidserver.deploy.config = {}
|
fdroidserver.deploy.config = {}
|
||||||
|
|
||||||
def test_update_serverwebroot_make_cur_version_link(self):
|
def test_update_serverwebroot_make_cur_version_link(self):
|
||||||
|
|
||||||
# setup parameters for this test run
|
# setup parameters for this test run
|
||||||
fdroidserver.deploy.options.no_chcksum = True
|
fdroidserver.deploy.options.no_chcksum = True
|
||||||
fdroidserver.deploy.options.identity_file = None
|
fdroidserver.deploy.options.identity_file = None
|
||||||
@ -123,7 +122,6 @@ class DeployTest(unittest.TestCase):
|
|||||||
self.assertEqual(call_iteration, 3, 'expected 3 invocations of subprocess.call')
|
self.assertEqual(call_iteration, 3, 'expected 3 invocations of subprocess.call')
|
||||||
|
|
||||||
def test_update_serverwebroot_with_id_file(self):
|
def test_update_serverwebroot_with_id_file(self):
|
||||||
|
|
||||||
# setup parameters for this test run
|
# setup parameters for this test run
|
||||||
fdroidserver.deploy.options.no_chcksum = False
|
fdroidserver.deploy.options.no_chcksum = False
|
||||||
fdroidserver.deploy.options.verbose = True
|
fdroidserver.deploy.options.verbose = True
|
||||||
|
@ -171,7 +171,6 @@ class LintTest(unittest.TestCase):
|
|||||||
}
|
}
|
||||||
|
|
||||||
for field, values in fields.items():
|
for field, values in fields.items():
|
||||||
|
|
||||||
for bad in values['bad']:
|
for bad in values['bad']:
|
||||||
anywarns = False
|
anywarns = False
|
||||||
app[field] = bad
|
app[field] = bad
|
||||||
|
@ -48,7 +48,6 @@ class Options:
|
|||||||
|
|
||||||
|
|
||||||
class NightlyTest(unittest.TestCase):
|
class NightlyTest(unittest.TestCase):
|
||||||
|
|
||||||
basedir = Path(__file__).resolve().parent
|
basedir = Path(__file__).resolve().parent
|
||||||
path = os.environ['PATH']
|
path = os.environ['PATH']
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ class RewriteMetaTest(unittest.TestCase):
|
|||||||
os.chdir(self.basedir)
|
os.chdir(self.basedir)
|
||||||
|
|
||||||
def test_rewrite_scenario_trivial(self):
|
def test_rewrite_scenario_trivial(self):
|
||||||
|
|
||||||
sys.argv = ['rewritemeta', 'a', 'b']
|
sys.argv = ['rewritemeta', 'a', 'b']
|
||||||
|
|
||||||
with tempfile.TemporaryDirectory() as tmpdir, TmpCwd(tmpdir):
|
with tempfile.TemporaryDirectory() as tmpdir, TmpCwd(tmpdir):
|
||||||
|
@ -34,7 +34,6 @@ class Options:
|
|||||||
|
|
||||||
|
|
||||||
class SignindexTest(unittest.TestCase):
|
class SignindexTest(unittest.TestCase):
|
||||||
|
|
||||||
basedir = Path(__file__).resolve().parent
|
basedir = Path(__file__).resolve().parent
|
||||||
|
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
|
@ -48,7 +48,6 @@ TEST_APP_ENTRY = {
|
|||||||
|
|
||||||
|
|
||||||
class VerifyTest(unittest.TestCase):
|
class VerifyTest(unittest.TestCase):
|
||||||
|
|
||||||
basedir = Path(__file__).resolve().parent
|
basedir = Path(__file__).resolve().parent
|
||||||
|
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user