mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-05 06:50:10 +01:00
remove unused latestapps.dat code
latestapps.dat was being used for the old-website, it's not used anymore Fixes the following crash in production: ``` 2020-09-13 19:26:59,000 CRITICAL: Unknown exception found! Traceback (most recent call last): File "/home/fbuild/fdroidserver/fdroid", line 22, in <module> fdroidserver.__main__.main() File "/home/fbuild/fdroidserver/fdroidserver/__main__.py", line 230, in main raise e File "/home/fbuild/fdroidserver/fdroidserver/__main__.py", line 211, in main mod.main() File "/home/fbuild/fdroidserver/fdroidserver/update.py", line 2451, in main app = apps[appid] KeyError: '45b464b398a7d9fac5a186bd3d3d8dc1e6a25f7f9cd48c7462619b1e5fba87c2' ```
This commit is contained in:
parent
1f7228d538
commit
36e5fec418
@ -2438,21 +2438,6 @@ def main():
|
||||
# Update known apks info...
|
||||
knownapks.writeifchanged()
|
||||
|
||||
# Generate latest apps data for widget
|
||||
if os.path.exists(os.path.join('stats', 'latestapps.txt')):
|
||||
data = ''
|
||||
with open(os.path.join('stats', 'latestapps.txt'), 'r') as f:
|
||||
for line in f:
|
||||
appid = line.rstrip()
|
||||
data += appid + "\t"
|
||||
app = apps[appid]
|
||||
data += app.Name + "\t"
|
||||
if app.icon is not None:
|
||||
data += app.icon + "\t"
|
||||
data += app.License + "\n"
|
||||
with open(os.path.join(repodirs[0], 'latestapps.dat'), 'w') as f:
|
||||
f.write(data)
|
||||
|
||||
if cachechanged:
|
||||
write_cache(apkcache)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user