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

Unable get ad accounts #65

Closed
hongphi opened this issue Jun 8, 2015 · 2 comments
Closed

Unable get ad accounts #65

hongphi opened this issue Jun 8, 2015 · 2 comments

Comments

@hongphi
Copy link

hongphi commented Jun 8, 2015

When I get my ad accounts, it throw a exceptions "AttributeError: 'unicode' object has no attribute 'get'".

File "/app/services/ads/facebook.py", line 1016, in
FacebookAPI = FacebookAds(my_app_id, my_app_secret, my_access_token)
File "/app/services/ads/facebook.py", line 51, in init
self.my_accounts = list(me.get_ad_accounts())
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/objects.py", line 797, in get_ad_accounts
return self.iterate_edge(AdAccount, fields, params)
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/objects.py", line 745, in iterate_edge
params=params
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/objects.py", line 94, in init
self.load_next_page()
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/objects.py", line 137, in load_next_page
params=self._params,
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/api.py", line 307, in call
raise fb_response.error()
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/api.py", line 117, in error
self.body()
File "/app/.heroku/python/lib/python2.7/site-packages/facebookads/exceptions.py", line 76, in init
if self._error.get('error_data', {}).get('blame_field_specs'):
AttributeError: 'unicode' object has no attribute 'get'

@m-vdb
Copy link

m-vdb commented Aug 18, 2015

try to use a pdb and check the error you have. You're getting this because you cannot get the account, I guess missing params

@rituparnamukherjee
Copy link
Contributor

If you are still facing this issue, please feel free to reopen this one. Also, in that case, pl add the steps for repro.

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

3 participants