I keep getting: AttributeError: 'NoneType' object has no attribute 'is_downloaded'. I am trying to integrate pyupdater with an executable. My amazon folder contains: pyu_test-win-1.0.zip and versions.gz which I upload.
Error:
{}
{}
nothing new
Traceback (most recent call last):
File "C:/Users/D1/Desktop/31/pyu_test.py", line 25, in <module>
if app_update.is_downloaded():
AttributeError: 'NoneType' object has no attribute 'is_downloaded'
Process finished with exit code 1
I'm getting also unresolved reference client_config as well as ClientConfig is underlined when I hover.
This is for: pyu_test.py
from pyupdater.client import Client
from client_config import ClientConfig
APP_NAME = 'pyu_test'
APP_VERSION = '1.0'
def print_status_info(info):
total = info.get(u'total')
downloaded = info.get(u'downloaded')
status = info.get(u'status')
print (downloaded, total, status)
client = Client(ClientConfig(), refresh=True,
progress_hooks=[print_status_info])
app_update = client.update_check(APP_NAME, APP_VERSION)
if app_update is not None:
app_update.download()
else:
print("nothing new")
if app_update.is_downloaded():
app_update.extract_overwrite()
client_config
class ClientConfig(object):
PUBLIC_KEY = '+WDWADADAWDADDWDW'
APP_NAME = 'pyu_test'
COMPANY_NAME = 'pyu_test'
UPDATE_URLS = ['https://console.aws.amazon.com/s3/buckets/xWAXWED/?region=us-east-2&tab=overview']
MAX_DOWNLOAD_RETRIES = 3
Any ideas how I can address this. Cheers.