Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Status Error : 'list' object has no attribute 'items' #4

Open
walidmujahid opened this issue Sep 24, 2021 · 0 comments
Open

Status Error : 'list' object has no attribute 'items' #4

walidmujahid opened this issue Sep 24, 2021 · 0 comments

Comments

@walidmujahid
Copy link

``Running the uploader, I kept getting the error:

Status Error : 'list' object has no attribute 'items'

This here seems to be outdated code, though, I am not sure what exactly changed since 2018, though I suspect possibly an issue with the PYBRY wrapper:

def check_lbry_status(self):
try:
response = self.lbry.call("status")
if response[0].get('is_running'):
return True
except Exception as e:
self.logger.error('Status Error : ' + str(e))
return False

This quick workaround worked for me:

Changed the following lines

response = self.lbry.call("status")
if response[0].get('is_running'):

To:

if self.lbry.status()[0]['is_running']:
    return True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant