Why doesn't insights match the graph? - facebook-graph-api

I have seen many instances where the Likes, Comments, and Shares reported from the Graph API endpoint for a particular post do not match the stats reported by Insights. I.e.:
https://graph.facebook.com/PAGEID_POSTID reports:
likes 1000, comments 450, shares 300
https://graph.facebook.com/PAGEID_POSTID/insights/post_stories_by_action_type reports:
likes 725, comments 375, shares, 200
Or something like that. I do realize that sometimes, insights will show higher numbers because Insights tracks stories that are generated off of a shared copy of the original post (very cool), but these are cases where Insights reports numbers lower than what the Graph API endpoint shows.
Is this because after 28 days, Facebook Insights stops updating for individual post stats?
Any ideas?
I've filed a bug here: https://developers.facebook.com/bugs/400094966692945

The unfortunate reality is that Facebook Insights is horribly buggy, and in general fixing api bugs does not seem to be much of a priority for Facebook.
If you visit your Insights page frequently you will see this. Days where the count of app removals spikes by 1000%, followed two days later by user installs spiking 1000%. Days where there are zero comments on your app's posts where you have recorded thousands in your database. The list goes on...
Even when they "fix" Insights bugs, they don't always fix the history, leaving the inaccurate data in place and only correcting it on a go-forward basis.
This is the kiss of death for any reporting or analytics system. Once you start seeing the bugs over and over where you know from your own independent data that the reporting system has bugs, you start to question everything it shows you: is this reality or is it a bug? How can I make any decisions based on this data if I cannot trust the data? Folks with enterprise experience know this, but the kids who run Facebook...not so much.

Related

Autocomplete Per-Character Usage

I had a few questions related to the changes to the Google Maps/Routes/Places that happened a couple weeks ago
My app calls places.PlacesService.GetAutocompletePredictions and, at the moment, in the Google Cloud Platform, I can see my "request" usage. However the billing switched to "per-character" and I could not find my usage by that metric. Any idea how to view it?
Is there a way to see my usage for the past few months?
How does this "per-character" thing work? Is it the number of characters of the prediction that I pick or the number of characters predicted at the end of my pre-filled phrase? Google doesn't seem to want to make their pricing particularly clear

Since vs updated_time vs created_time

I'm writing an app to collect facebook posts matching a certain search term, and I'm trying to fetch only new or updated posts since the graph.facebook.com/search endpoint. I've concluded from debugging that this particular endpoint uses time-based pagination (since, until), so here's my process:
fetch new posts using the most recent 'since' time (default to now - 5 mins at start)
update my 'since' time to the most recent created_time or updated_time from the list of return posts
sleep X seconds, repeat
However, I can't even see my own newly created posts. I do get some results, but they seem random in terms of why they match my search and not my own. For testing purposes, I'm using a user-level access token generated using the FB developer tools, so I should definitely not have any permissions issues restricting me from seeing my own content.
What gives?
Edit: More testing reveals that I can randomly receive SOME of my own posts, but there appears to be no rhyme or reason why one post shows up and the others don't. For example, I just posted 3 posts and received the second one via my app. The first and third are nowhere to be found.
I think what you are seeing here is an artefact of the consistency model Facebook is using. You can see another example of this when you look at your feed from two different devices. If I look at my feed from my smartphone and then go and check out my feed on my PC, sometimes I see the same items and sometimes there are items I saw on one device, that I didn't see on the other. This is because Facebook uses Eventual consistency.
In simple terms this means that given enough time, all data clusters will be consistent, but this is not guaranteed at any given time point. The bad news is: there is not much you can do about this. It's just a fact-of-life when working with very large distributed systems (and Facebook is one of the largest in the world). At this scale it is just not practical, where technology is today, to keep all copies of the data completely in sync at all times. What I think you are seeing is two requests serviced by two clusters which are currently not 100% in sync.
Here is an interesting read on the subject.
And here is something from Facebook. You can skip to the Consistancy section of the page (Although, I would recommend reading the entire post. It is a very interesting overview of Facebook architecture).

Workaround for - graph api bug

Can anyone provide a workaround for this bug
Our app is managing a lot pages with many posts, but since 5 days ago we've had huge problems with that bug.
90% of our posts gain the above described error, 10% are working well.
After many hours of testing we know it's something about the "link" parameter.
Without it, we can post without any errors.
We tried to only post our images without the link parameter but after a hour of posting correctly we got a new error.
(#368) The action attempted has been deemed abusive or is otherwise disallowed. Interesting that posting an image without a link parameter is abusive.
We tried to regenerate all user_tokens and page_tokens but no success, the error still exists.
We tried to pause the service for 24 hours and start it again, no effect.
Does anyone have an idea or a workaround for this bug?
It doesn't seem that it was patched on Tuesday. Because of that we need a solution, we can't hold the service down for one more week.
the workaround from "thefreeman" works for me also:
add more admin(s) to the pages
generate tokens for the new admin
juggle the tokens to stay below limit
Limit per account (for me) seems to be about 150 posts per day.
Limit seems to reset at a certain point in time. Midnight at facebook?
(i am managing 60 Pages and posting roughly 200 updates per day.)
certainly not a nice solution, but the bugs in the fb-bugtracker don't seem to get too much attention :(
sometimes i get a new error: "OAuthException (#1500) The url you supplied is invalid".
Trying again later with the same data works though...

What does facebook know about you with the likebox

We were having a beer talk and have something to clear out.
Is the following conclusion correct:
When I put a facebook-like-button-box on my page, does facebook know
every time I'm on that page, even if i'm not logged in.
basically the same as google analytics
if this nis correct, it should be possible to sandbox, the like-button until someone will use it. Then facebook gets only informations when the user actively confirms that.
cheers endo
No, they can't directly track you if you are not logged in and you view an external "like" button. They can, however, set a tracking cookie that identifies you when you sign in, which would allow them to match the tracking data in the current session to you.
One of Facebook's primary revenue streams comes from the analysis and sale of market trend information. They can analyse the likes and comment keywords of certain user clusters (e.g. middle-aged American females, teenagers in college, etc) and use these to produce statistics about market patterns and trends. They can also use keyword analysis to tell a company how many people are talking about something, e.g. "how many people have mentioned my latest blockbuster film?"
You could simply move the image and JavaScript code away from the Facebook servers and host it locally to avoid them from tracking your users.
In pre-emption of the "FACEBOOK = EVIL" arguments:
In the end, though, is it really a big issue? Some people see Facebook as this massive life-infringing uncaring supercorporation, but in reality they're just making a buck through completely anonymous statistics. No human being (or sentient robot) views your preferences, browser tracking data, or personal information. Everything is anonymised and turned into a bunch of numbers relating to a group. Sure, they could screw everyone over and be evil, but why bother when you already make that much money legitimately?

What would be a good Coldfusion-based bug tracking software?

What I am looking for is a tool that easily or automatically sends coldfusion error messages to their system.
Then I can use the web-based interface, to manage priorities, track who fixed what and so forth.
But I want to use this to help us deal with errors better, but also to show the importance of a bug tracking system to my fellow works.
System Requirements: Apache, Windows, Coldfusion 8 Standard, Sql Server 2005.
Financial Requirements: Free or Open Source
Goal Or Purpose: To encourage my fellow workers to want and use a bug tracking system.
Does this re-write make more sense?
Thanks
Craig
Wiki has a list of issue tracking software, maybe this list could help.
http://en.wikipedia.org/wiki/Comparison_of_issue_tracking_systems
You may be able to find a hosted service and use either email or web services to create the ticket using onError. With that said, a simple issue tracking app could be created for your site using the same DB used to drive the content. 2 or 3 tables would take care of the data storage and you're already using CF so the application layer is already there.
HTH.
I have been heavily using this type of a setup for several years by email only, and the last 3 years with a Bug Tracking Software.
I must say, the bug tracking software has made my life so much more peaceful. Nothing is left, forgotten, or slips through the cracks. It's easy to find trends in errors, and remember "all the times" it happened.
Our setup is like this:
1) Coldfusion + Appropriate framework with error reporting - It doesn't matter what you use. I have used Fusebox extensively and am making the transition to ColdBox. Both are very capable, in addition to Mach-II, FW/1, Model-Glue, etc. The key part you have to find in them is their ability to catch "onError", usualy in the application CFC.
2) Custom OnError Script - Wherever an error occurs, you want to capture the maximum amount of information about that error and email it in. What we do is, when an error occurs, we log the user out with a message of "oops, log in again". Before logging them out, the application captures the error and emails it to Fogbugz. Along with it, at the top we include the CGI variables for the IP address, browser being used, etc. Over time you will find the things you need to add.
3) Routing in Fogbugz. A 2 user version of Fogbugz is free, and hosted online. There are two main ways to submit bugs. One is to email one in at a time. So if an error happens 2000 times, you get 2000 emails, and 2000 cases. Not always the best to link them together, etc. They have a feature called BugzScout, which is essentially an HTTP address that you do a form post to with cfform with all of the same information you would have put into the email. There's plenty of documentation on this and something I've always wanted to get around to. I had a scenario of 2000 emails for the first time happen a few weeks ago so I'll be switching over to this.
Hope that helps. Share what you ended up doing and why so we all can learn too!
I'm surprised no one mentioned LighthousePro (http://lighthousepro.riaforge.org). Open source - 100% free - and ColdFusion. As the author I'm a bit biased though. :)
Hard question to answer not knowing what kind of restrictions are there? Do you have any permissions to install anything? Also most bug-tracking systems require some kind of database support.
I have a suggestion. You can put in place a basic bug-tracking system, that just allows people to create tickets, and allows you/someone else to close it.
More Windows based tools are mentioned here
Good open-source bug tracking / issue tracking sofware for Windows
Any reason why coldfusion specifically?
I really like Fogbugz from the makers of Stack Overflow. For one user it's quite reasonably priced. I enter some bugs manually and have others emailed in.
A lot of bug tracking software will expose SOAP methods for entering data into them.
For example, we used Axosoft's OnTime and that exposed some WSDL pages that I consumed in my application. I was told that Jira did as well.
There are few in CF411 list: Bug Tracking/Defect Tracking/Trouble Ticket/Help Desk Tools Written in CFML
We use HopToad. There is another bug-tracking app called LightHouse that integrates with HopToad so you can easily create a [bug] ticket from an incoming exception. HopToad has an API of which there are many clients, you want the CF based one:
http://github.com/timblair/coldfusion-hoptoad-notifier
Even if you dont use HopToad and you end up using a different service or roll your own, if you needed to write your own API client you could leverage the code or pattern(s) of the above HopToad client.
A lot of good information from everyone, and I really do appreciate the efforts given. But not the answer i was looking for. Which maybe means, that what i want does not exist, yet.
So i may have to roll my own solution...Or maybe integrate with another existing app...
Thank You all.