Merge branch 'three-little-fixes' into 'master'

three little fixes

See merge request fdroid/fdroidserver!1052
This commit is contained in:
Jochen Sprickerhof 2021-12-07 09:37:54 +00:00
commit 4dd9c488d3
3 changed files with 9 additions and 2 deletions

View file

@ -203,16 +203,16 @@ lint_format_safety_bandit_checks:
lint_mypy: lint_mypy:
image: debian:bullseye image: debian:bullseye-backports
<<: *apt-template <<: *apt-template
script: script:
- sed -i '/pyjks/d' setup.py # TODO get from backports once available
# use Debian packages to avoid building C/rust sources # use Debian packages to avoid building C/rust sources
- apt-get install - apt-get install
mypy mypy
python3-cryptography python3-cryptography
python3-pip python3-pip
python3-wheel python3-wheel
- apt-get install -t bullseye-backports python3-pyjks
- pip install -e .[test] - pip install -e .[test]
- mypy - mypy

View file

@ -117,6 +117,11 @@ cat <<EOF > $ANDROID_HOME/licenses/android-sdk-preview-license-old
84831b9409646a918e30573bab4c9c91346d8abd 84831b9409646a918e30573bab4c9c91346d8abd
EOF EOF
cat <<EOF > $ANDROID_HOME/licenses/intel-android-extra-license
d975f751698a77b662f1254ddbeed3901e976f5a
EOF
echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout;1.0.1" echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout;1.0.1"
echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout-solver;1.0.1" echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout-solver;1.0.1"
echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout;1.0.2" echo y | $ANDROID_HOME/tools/bin/sdkmanager "extras;m2repository;com;android;support;constraint;constraint-layout;1.0.2"

View file

@ -27,6 +27,7 @@ def _run_wget(path, urls):
if not urls: if not urls:
return return
logging.debug(_('Running wget in {path}').format(path=path)) logging.debug(_('Running wget in {path}').format(path=path))
cwd = os.getcwd()
os.makedirs(path, exist_ok=True) os.makedirs(path, exist_ok=True)
os.chdir(path) os.chdir(path)
urls_file = '.fdroid-mirror-wget-input-file' urls_file = '.fdroid-mirror-wget-input-file'
@ -43,6 +44,7 @@ def _run_wget(path, urls):
] ]
) )
os.remove(urls_file) os.remove(urls_file)
os.chdir(cwd) # leave the working env the way we found it
def main(): def main():