awis icon indicating copy to clipboard operation
awis copied to clipboard

NotImplementedError: .OwnedDomain contains a list we don't know how to flatten.

Open lameei opened this issue 8 years ago • 0 comments

For some domains like yahoo.com and amazon.com I'm getting the following error:

Traceback (most recent call last):
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 134, in flatten
    items = value.items()
AttributeError: 'list' object has no attribute 'items'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/telegram/ext/dispatcher.py", line 270, in process_update
    handler.handle_update(update, self)
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/telegram/ext/messagehandler.py", line 169, in handle_update
    return self.callback(dispatcher.bot, update, **optional_args)
  File "rankcheckbot.py", line 101, in instantrank
    data = flatten_urlinfo(urlinfo)
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 163, in flatten_urlinfo
    flatten(info["aws:UrlInfoResponse"]["Response"]["UrlInfoResult"]["Alexa"])
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 159, in flatten
    flatten(v, ".".join([prefix, k]))
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 159, in flatten
    flatten(v, ".".join([prefix, k]))
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 159, in flatten
    flatten(v, ".".join([prefix, k]))
  File "/Users/mostafalameei/Sites/rankcheckbot/lib/python3.6/site-packages/myawis/__init__.py", line 156, in flatten
    raise NotImplementedError(msg)
NotImplementedError: .OwnedDomain contains a list we don't know how to flatten.

lameei avatar Dec 02 '17 07:12 lameei