mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-10-05 18:50:09 +02:00
server: disable extraneous HTTP errors in upload_apk_to_virustotal
This should be in the lowest level so that both the low level call, upload_apk_to_virustotal(), and the next level up, upload_to_virustotal(), both inherit this.
This commit is contained in:
parent
cfa88a5335
commit
77367f1bff
@ -512,9 +512,6 @@ def upload_to_virustotal(repo_section, virustotal_apikey):
|
||||
import requests
|
||||
requests # stop unused import warning
|
||||
|
||||
logging.getLogger("urllib3").setLevel(logging.WARNING)
|
||||
logging.getLogger("requests").setLevel(logging.WARNING)
|
||||
|
||||
if repo_section == 'repo':
|
||||
if not os.path.exists('virustotal'):
|
||||
os.mkdir('virustotal')
|
||||
@ -534,6 +531,9 @@ def upload_apk_to_virustotal(virustotal_apikey, packageName, apkName, hash,
|
||||
versionCode, **kwargs):
|
||||
import requests
|
||||
|
||||
logging.getLogger("urllib3").setLevel(logging.WARNING)
|
||||
logging.getLogger("requests").setLevel(logging.WARNING)
|
||||
|
||||
outputfilename = os.path.join('virustotal',
|
||||
packageName + '_' + str(versionCode)
|
||||
+ '_' + hash + '.json')
|
||||
|
Loading…
Reference in New Issue
Block a user