BUT, Business.get_ad_network_analytics() will infinite loop to request the last page!!!
Finally,I got response:
Status: 400
Response:
{
"error": {
"message": "(#613) You can have at most 250 queries per minute",
"type": "OAuthException",
"code": 613,
"fbtrace_id": "AXh2zHUPkO8EALtDlsgV1RR"
}
}
I debug the facebook_business code,find the code in facebook_business.api load_next_page() line 835:
if (
'paging' in response and
'cursors' in response['paging'] and
'after' in response['paging']['cursors']
):
self.params['after'] = response['paging']['cursors']['after']
else:
# Indicate if this was the last page
self._finished_iteration = True
if condition always stand up!because response['paging']['cursors']['after'] always true!
thanks for reporting this bug. we will provide a fix in our next release to instead check the existence of 'next' in response['paging'] to decide if it is the last page.
facebook_business.adobjects.business.Business get_ad_network_analytics() ERROR
I‘m get data from https://graph.facebook.com/v18.0/{app_id}/adnetworkanalytics with params:
then,I get the first page response paging like this:
and get the last page response paging like this:
BUT, Business.get_ad_network_analytics() will infinite loop to request the last page!!! Finally,I got response:
I debug the facebook_business code,find the code in facebook_business.api load_next_page() line 835:
if condition always stand up!because response['paging']['cursors']['after'] always true!
Now, what can I do to resolve this problem?