1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-19 03:05:22 +02:00

Extend waiting time from 3 min to 15 min

As per Mozilla blog post:
- https://blog.mozilla.org/addons/2019/11/11/security-improvements-in-amo-upload-tools/

> For custom scripts that use the AMO upload API:
> make sure your upload scripts account for
> potentially longer delays before the signed file
> is available. We recommend allowing up to 15
> minutes.
This commit is contained in:
Raymond Hill 2019-11-20 06:12:57 -05:00
parent 0d20ee9ab0
commit 182889d0df
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -202,11 +202,14 @@ with open(unsigned_xpi_filepath, 'rb') as f:
# Wait for signed package to be ready
signing_check_url = signing_request_response['url']
# TODO: use real time instead
countdown = 180 / 5
# https://blog.mozilla.org/addons/2019/11/11/security-improvements-in-amo-upload-tools/
# "We recommend allowing up to 15 minutes."
interval = 30 # check every 30 seconds
countdown = 15 * 60 / interval # for at most 15 minutes
while True:
sys.stdout.write('.')
sys.stdout.flush()
time.sleep(5)
time.sleep(interval)
countdown -= 1
if countdown <= 0:
print('Error: AMO signing timed out')