1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-11-14 11:00:10 +01:00
Commit Graph

8514 Commits

Author SHA1 Message Date
Hans-Christoph Steiner
1b65e33835 make it easy to keep test artifacts from jobs
When troubleshooting things that are difficult to reproduce locally, like
different behaviors in the fedora_latest job, these changes make it easy to
keep the test files around after the tests run.  For example, if PNGs are
processed differently by newer Python versions.
2024-05-07 12:58:23 +00:00
Hans-Christoph Steiner
299e3e5f4c index: handle image processing diffs across various Python versions
Apparently, the newest Python thingies strip the PNGs a tiny bit smaller,
so a fixed file size will lead to the test failing:

https://gitlab.com/fdroid/fdroidserver/-/jobs/6703386074
```
Traceback (most recent call last):
  File "/builds/fdroid/fdroidserver/tests/index.TestCase", line 704, in test_package_metadata
    self.assertEqual(36027, metadata['featureGraphic']['en-US']['size'])
AssertionError: 36027 != 35619
```
2024-05-07 12:58:23 +00:00
Hans-Christoph Steiner
1cb1394de3 Merge branch 'debugkey' into 'master'
lint: blocklist known AOSP debug keys in AASK

See merge request fdroid/fdroidserver!1478
2024-05-07 11:33:12 +00:00
Hans-Christoph Steiner
9a9b5beeaa simplify test setup
I'm in the midst of working towards getting rid of the "config" instances
that are in the subcommand module, e.g. `fdroidserver.lint.config`
2024-05-07 11:33:04 +00:00
Hans-Christoph Steiner
14c8647909 add additional tests 2024-05-07 11:33:04 +00:00
linsui
d243cbd030 lint: blocklist known AOSP debug keys in AASK 2024-05-07 11:33:04 +00:00
Michael Pöhn
08c553e1cb Merge branch 'deploy' into 'master'
deploy: retry when git push fails

See merge request fdroid/fdroidserver!1480
2024-05-06 06:36:58 +00:00
linsui
f82d648cb1 deploy: retry when git push fails 2024-05-05 20:53:35 +00:00
Michael Pöhn
79586fd9e3 Merge branch 'fix-icons-in-fdroid-mirror' into 'master'
mirror: apparently the 'icons' dir does not always exist

See merge request fdroid/fdroidserver!1476
2024-05-05 17:14:49 +00:00
Hans-Christoph Steiner
6f07538cdc mirror: apparently the 'icons' dir does not always exist
https://apt.izzysoft.de/fdroid/archive/com.futsch1.medtimer_28.apk:
2024-04-21 18:55:20 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.hardbacknutter.nevertoomanybooks_75.apk:
2024-04-21 18:55:20 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.jovial.jrpn15_20.apk:
2024-04-21 18:55:20 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.jovial.jrpn2_20.apk:
2024-04-21 18:55:20 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.logger.app_8.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.lorenzovainigli.foodexpirationdates.foss_22.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.openathena_36.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.oppzippy.openscq30_21.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.sanmer.mrepo_713.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/com.starry.myne_325.apk:
2024-04-21 18:55:21 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/dev.imranr.obtainium_22602.apk:
2024-04-21 18:55:22 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/dev.sanmer.pi_137.apk:
2024-04-21 18:55:22 ERROR 404: Not Found.
https://apt.izzysoft.de/fdroid/archive/org.breezyweather_50108.apk:
2024-04-21 18:55:22 ERROR 404: Not Found.
2024-04-21 18:55:22,448 ERROR: no "icon" in org.breezyweather
2024-04-21 18:55:22,449 ERROR: no "icon" in com.lorenzovainigli.foodexpirationdates.foss
2024-04-21 18:55:22,449 ERROR: no "icon" in com.jovial.jrpn15
2024-04-21 18:55:22,450 ERROR: no "icon" in com.jovial.jrpn2
2024-04-21 18:55:22,450 ERROR: no "icon" in com.logger.app
2024-04-21 18:55:22,450 ERROR: no "icon" in com.futsch1.medtimer
2024-04-21 18:55:22,451 ERROR: no "icon" in com.sanmer.mrepo
2024-04-21 18:55:22,451 ERROR: no "icon" in com.starry.myne
2024-04-21 18:55:22,451 ERROR: no "icon" in com.hardbacknutter.nevertoomanybooks
2024-04-21 18:55:22,452 ERROR: no "icon" in dev.imranr.obtainium
2024-04-21 18:55:22,452 ERROR: no "icon" in com.openathena
2024-04-21 18:55:22,453 ERROR: no "icon" in com.oppzippy.openscq30
2024-04-21 18:55:22,453 ERROR: no "icon" in dev.sanmer.pi
2024-04-21 18:55:22,454 CRITICAL: Unknown exception found!
Traceback (most recent call last):
  File "/home/fdroid/code/fdroid/fdroidserver/fdroid", line 22, in <module>
    fdroidserver.__main__.main()
  File "/home/fdroid/code/fdroid/fdroidserver/fdroidserver/__main__.py", line 230, in main
    raise e
  File "/home/fdroid/code/fdroid/fdroidserver/fdroidserver/__main__.py", line 211, in main
    mod.main()
  File "/home/fdroid/code/fdroid/fdroidserver/fdroidserver/mirror.py", line 269, in main
    _run_wget(os.path.join(basedir, section, icondir), urls[icondir])
KeyError: 'icons'
2024-05-02 18:29:42 +02:00
Hans-Christoph Steiner
32ef77ecb6 Merge branch 'androguard-modernization' into 'master'
port to androguard >= 4 and drop support for older than 3.3.5

See merge request fdroid/fdroidserver!1462
2024-04-25 11:09:27 +00:00
Hans-Christoph Steiner
be59b38ac1 update: handle ValueError from apkInspector in androguard 4.1
androguard 4.1 uses a new lib called apkInspector instead of zipfile.ZipFile
so that it can handle usable but invalid ZIP files.  It will also throw
ValueError on some things, for example:

Traceback (most recent call last):
  File "/builds/eighthave/fdroidserver/fdroidserver-2.3a0/tests/update.TestCase", line 878, in test_scan_apk_bad_zip
    fdroidserver.update.scan_apk(apkfile)
  File "/builds/eighthave/fdroidserver/fdroidserver-2.3a0/fdroidserver/update.py", line 1586, in scan_apk
    scan_apk_androguard(apk, apk_file)
  File "/builds/eighthave/fdroidserver/fdroidserver-2.3a0/fdroidserver/update.py", line 1725, in scan_apk_androguard
    apkobject = common.get_androguard_APK(apkfile)
  File "/builds/eighthave/fdroidserver/fdroidserver-2.3a0/fdroidserver/common.py", line 2673, in get_androguard_APK
    return APK(apkfile)
  File "/usr/local/lib/python3.10/dist-packages/androguard/core/apk/__init__.py", line 273, in __init__
    self.zip = ZipEntry.parse(filename, False)
  File "/usr/local/lib/python3.10/dist-packages/apkInspector/headers.py", line 410, in parse
    eocd = EndOfCentralDirectoryRecord.parse(apk_file)
  File "/usr/local/lib/python3.10/dist-packages/apkInspector/headers.py", line 59, in parse
    raise ValueError("End of central directory record (EOCD) signature not found")
ValueError: End of central directory record (EOCD) signature not found
2024-04-25 13:00:23 +02:00
Hans-Christoph Steiner
ef4ec74882 some parts of androguard 4.x use loguru instead of logging 2024-04-25 12:39:12 +02:00
Hans-Christoph Steiner
1c84f63247 replace deprecated get_element() which was removed in 4.x
/usr/lib/python3/dist-packages/androguard/core/bytecodes/apk.py:884: DeprecationWarning: This method is deprecated since 3.3.5.

It was added in 3.3.5.  Debian/bullseye and Ubuntu/20.04/focal both include
new enough versions.  Debian/buster's is too old (3.3.3).
2024-04-25 12:39:12 +02:00
Hans-Christoph Steiner
5b7abc0423 single function to tame androguard's verbose default output
# Conflicts:
#	fdroidserver/common.py
2024-04-25 12:39:12 +02:00
Hans-Christoph Steiner
7a144a4762 port to androguard >= 4 and drop support for older than 3.3.3
This also makes androguard a hard requirement, which has been true for a
while anyway.  So the code that handles androguard as an optional
requirement is removed.  androguard from Debian/buster is new enough, so
this does not seem like it will cause any problems.
2024-04-25 12:39:12 +02:00
Hans-Christoph Steiner
cdc7c98707 common.get_androguard_APK() is no longer private to the module 2024-04-25 12:39:12 +02:00
Hans-Christoph Steiner
a742df3758
add CHANGELOG entry for v2.2.2 2024-04-25 12:39:00 +02:00
Hans-Christoph Steiner
e45e37b2df Merge branch 'altstore-index-fix' into 'master'
🐛 index fix: skip altstore when no IPAs present

See merge request fdroid/fdroidserver!1473
2024-04-24 12:05:03 +00:00
Michael Pöhn
005a33732c apply review suggestions 2024-04-24 11:56:07 +00:00
Michael Pöhn
bd6afa4365
🐛 index fix: skip altstore when no IPAs present 2024-04-24 12:45:29 +02:00
Hans-Christoph Steiner
07929ffe66 Merge branch 'black' into 'master'
move fdroidserver/deploy.py to black format

See merge request fdroid/fdroidserver!1472
2024-04-24 08:51:46 +00:00
Hans-Christoph Steiner
79f148167a deploy: automatically convert to black format 2024-04-24 08:42:15 +00:00
Hans-Christoph Steiner
cb04d801d8 deploy: manually move hard cases to black code format 2024-04-24 08:42:15 +00:00
Hans-Christoph Steiner
eacfb8095b Merge branch 'alt-store' into 'master'
iOS metadata + alt-store source support

See merge request fdroid/fdroidserver!1465
2024-04-24 08:39:05 +00:00
Hans-Christoph Steiner
9716b5e1ab index: manual black format 2024-04-24 10:29:50 +02:00
Michael Pöhn
d00a87ed6c
🏏 alt-store index: incorporate review feedback 2024-04-23 17:28:30 +02:00
Michael Pöhn
f2118b35a3
🏟️ fix ci 2024-04-23 16:06:10 +02:00
Michael Pöhn
45efb88f85
🕴️ add test for make_altstore 2024-04-23 16:05:58 +02:00
Michael Pöhn
86db8c93cc
🩹 fix parse_ipa tests 2024-04-23 16:05:47 +02:00
Michael Pöhn
f742799a9d
🏟️ add test for _parse_from_pbxproj
Also fix lint issues
2024-04-23 16:05:34 +02:00
Michael Pöhn
450765490b
🗺️ add test for _get_ipa_ico 2024-04-23 16:05:22 +02:00
Michael Pöhn
a21ed39117
🛻 move alstore index function
Move function for generating altstore index from update.py to index.py
2024-04-23 16:05:10 +02:00
Michael Pöhn
301f0c8273
🍎 altstore: implement ipa entitlement parser
This adds a parser for reading entitlement values from .ipa files.
Entitlement values are stored in files called
'.../embedded.mobileprovision' packed into .ipa files. These are CMS
signed plist files.

https://en.wikipedia.org/wiki/Cryptographic_Message_Syntax

This also ignores the 2 non-optional entitlements, as mentioned in
altstore docs:

https://faq.altstore.io/distribute-your-apps/make-a-source#entitlements-array-of-strings
2024-04-23 16:04:57 +02:00
Michael Pöhn
2658c22933
🖼️ altstore index screenshots and icons 2024-04-23 16:04:44 +02:00
Michael Pöhn
519c3c1fcf
👑 altstore index: add entitlement support 2024-04-23 16:04:31 +02:00
Michael Pöhn
93e7cc9092
📑 better alt-store index 2024-04-23 16:04:19 +02:00
Michael Pöhn
fb33ae58e2
🐑 naive alt-store support
Naive shot at implementing alt store support. Might still be missing important
bits and pices I'm not aware of.
2024-04-23 16:04:07 +02:00
Hans-Christoph Steiner
e24640da85 Merge branch 'weblate' into 'master'
weblate

See merge request fdroid/fdroidserver!1470
2024-04-10 14:03:35 +00:00
Hans-Christoph Steiner
1fa376a9dc CheckUpdates should be called checkupdates
"checkupdates" is an fdroid subcommand, e.g. `fdroid checkupdates`, and it
is always spelled all lower case.

sed -i 's,CheckUpdates,checkupdates,g' fdroidserver/*.py locale/*/LC_MESSAGES/fdroidserver.po
2024-04-10 15:50:26 +02:00
Hans-Christoph Steiner
6ab1fd9945 fix UpdateCheckMode string in lint
sed -i "s/UpdateCheckMode is set but it looks likecheckupdates hasn't been run yet/UpdateCheckMode is set but it looks like checkupdates hasn't been run yet./g" locale/*/LC_MESSAGES/fdroidserver.po
2024-04-10 15:50:26 +02:00
Hans-Christoph Steiner
443973c6f1 Translated using Weblate: Romanian (ro) by Hans-Christoph Steiner <hans@guardianproject.info>
Currently translated at 100.0% (552 of 552 strings)

Translated using Weblate: Hungarian (hu) by Hans-Christoph Steiner <hans@guardianproject.info>

Currently translated at 57.6% (318 of 552 strings)

Translated using Weblate: Korean (ko) by Hans-Christoph Steiner <hans@guardianproject.info>

Currently translated at 32.7% (181 of 552 strings)

Translated using Weblate: French (fr) by Hans-Christoph Steiner <hans@guardianproject.info>

Currently translated at 100.0% (552 of 552 strings)

Translated using Weblate: Tibetan (bo) by Hans-Christoph Steiner <hans@guardianproject.info>

Currently translated at 53.4% (295 of 552 strings)

Translated using Weblate: Chinese (Traditional) (zh_Hant) by Hans-Christoph Steiner <hans@guardianproject.info>

Currently translated at 66.8% (369 of 552 strings)

Co-authored-by: Hans-Christoph Steiner <hans@guardianproject.info>
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/bo/
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/fr/
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/hu/
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/ko/
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/ro/
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/zh_Hant/
Translation: F-Droid/F-Droid Server
2024-04-10 15:50:26 +02:00
VfBFan
954c136506 Translated using Weblate: German (de) by VfBFan <VfBFan@users.noreply.hosted.weblate.org>
Currently translated at 100.0% (552 of 552 strings)

Translation: F-Droid/F-Droid Server
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/de/
2024-04-10 15:50:26 +02:00
Alexander Ivanov
4e491830cc Translated using Weblate: Russian (ru) by Alexander Ivanov <saiv46.dev@gmail.com>
Currently translated at 100.0% (552 of 552 strings)

Translation: F-Droid/F-Droid Server
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/ru/
2024-04-10 15:50:26 +02:00
Besnik Bleta
a90191949d Translated using Weblate: Albanian (sq) by Besnik Bleta <besnik@programeshqip.org>
Currently translated at 97.1% (536 of 552 strings)

Translation: F-Droid/F-Droid Server
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/sq/
2024-04-10 15:50:26 +02:00
Besnik Bleta
e8a980ea9c Translated using Weblate: Albanian (sq) by Besnik Bleta <besnik@programeshqip.org>
Currently translated at 94.5% (522 of 552 strings)

Translation: F-Droid/F-Droid Server
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/sq/
2024-04-10 15:50:26 +02:00
Simona Iacob
0d12b5ffba Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>
Currently translated at 100.0% (552 of 552 strings)

Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>

Currently translated at 99.6% (550 of 552 strings)

Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>

Currently translated at 99.0% (547 of 552 strings)

Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>

Currently translated at 98.5% (544 of 552 strings)

Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>

Currently translated at 98.3% (543 of 552 strings)

Translated using Weblate: Romanian (ro) by Simona Iacob <s@zp1.net>

Currently translated at 97.2% (537 of 552 strings)

Co-authored-by: Simona Iacob <s@zp1.net>
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/ro/
Translation: F-Droid/F-Droid Server
2024-04-10 15:50:10 +02:00
Licaon Kter
b08ae68706 Translated using Weblate: Romanian (ro) by Licaon Kter <licaon.kter@protonmail.com>
Currently translated at 96.7% (534 of 552 strings)

Co-authored-by: Licaon Kter <licaon.kter@protonmail.com>
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/ro/
Translation: F-Droid/F-Droid Server
2024-04-10 15:50:10 +02:00
linsui
44f4317ff8 Translated using Weblate: Chinese (Simplified) (zh_Hans) by linsui <linsui@inbox.lv>
Currently translated at 80.4% (444 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by linsui <linsui@inbox.lv>

Currently translated at 80.4% (444 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by linsui <linsui@inbox.lv>

Currently translated at 80.2% (443 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by linsui <linsui@inbox.lv>

Currently translated at 80.0% (442 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by linsui <linsui@inbox.lv>

Currently translated at 79.8% (441 of 552 strings)

Co-authored-by: linsui <linsui@inbox.lv>
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/zh_Hans/
Translation: F-Droid/F-Droid Server
2024-04-10 15:47:54 +02:00
David Jiang
98d880fe1c Translated using Weblate: Chinese (Simplified) (zh_Hans) by David Jiang <david.jiang2024@gmail.com>
Currently translated at 80.4% (444 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by David Jiang <david.jiang2024@gmail.com>

Currently translated at 80.2% (443 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by David Jiang <david.jiang2024@gmail.com>

Currently translated at 80.0% (442 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by David Jiang <david.jiang2024@gmail.com>

Currently translated at 79.8% (441 of 552 strings)

Translated using Weblate: Chinese (Simplified) (zh_Hans) by David Jiang <david.jiang2024@gmail.com>

Currently translated at 79.7% (440 of 552 strings)

Co-authored-by: David Jiang <david.jiang2024@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/f-droid/fdroidserver/zh_Hans/
Translation: F-Droid/F-Droid Server
2024-04-10 15:47:54 +02:00