Handle Facebook error when Facebook does not return the expected number of posts
Background
My users are using Facebook groups to sell items auction style. Each week all posts are deleted and new posts added. My app makes a call to Facebook to get posts from their group feed then loops using the paging next
url to get more posts until there is no paging array returned. Essentially it is expecting to get all of the posts on the feed. It processes each post and creates Item
objects that my users can interact with and gives them totals for the auction.
Problem
In most cases this just works, however there are always exceptions and in one particular case so far one of my users got only approximately 150 posts instead of the 700 or so that were on her feed. She tried to run the process two more times and got the same result. The next day she ran the process and got back all of the results (no code changes). She did mention that she re-logged in to my app that second day, but based on the lack of error from Facebook, my log files showing no discrepancies and the fact that she was able to get a number of posts back my only assumption is to treat this as a Facebook glitch that eventually resolves itself.
What I have now
As of now in development I am displaying a total post count to the user during the process so that they can decide if everything was returned or not:
Then, once complete, a simple modal overlay with Yes and No buttons:
Yes brings the user to the results page signalling that all posts were returned.
The No button
The No button when pressed should handle the exception gracefully and display a message explaining the situation and offer some options. Ideally I would like to explain the situation as succinctly as possible.
Options
- Allow the user to rerun the process immediately.
- I'm worried that if I allow the user to rerun the process without limits they could potentially put my app over the Facebook API call limit crippling the app for everyone.
- The user must wait an hour before rerunning the process with an explanation of why and a countdown before the button is enabled again (an hour is required to reset the Facebook API call counter)
- I don't like making them wait but without fully understanding why this exception occurs I don't know how else to handle this
My question then is how should I succinctly display a message to the user explaining the issue, explaining that it is beyond the control of the app and that they will have the opportunity to rerun the process after a lapse in time?
Also please dissect the options I've provided and offer alternatives as I am very open to suggestions at this point and I want to provide my users with a great experience.
Thanks