Hi everyone,
I'm happy to announce the release of Koala 1.6 RC! I'll jump right into what's new (the useful stuff) before digressing on the Facebook API and why this release is so long in coming.
What's new
This release adds some small but useful new features around the edges and fixes some issues that have cropped up in recent months.
- Koala now returns more specific and useful error classes (thanks, archfear!). Note that this slightly changes how error checking and generation inside the library is handled; in the unlikely event that you were working directly with this code, check out the changes.
- RealtimeUpdates#validate_update to validate the signature of a Facebook call (thanks, gaffo!)
- Graph API methods now accepts a post processing block, see readme for examples (thanks, wolframarnold!)
- URL parsing now uses addressable, which can handle FB URLs with characters that break URI.parse (thanks, bnorton and jayeff!)
- Fixed Batch API bug that seems to have broken calls requiring post-processing
- Bump Faraday requirement to 0.8 (thanks, jarthod!)
There are also some internal improvements:
- Cleaned up some test suites (thanks, bnorton!)
- Changelog is now markdown
- Code highlighting in readme (thanks, sfate!)
- Added Graph API explorer link in readme (thanks, jch!)
- Added permissions example for OAuth (thanks, sebastiandeutsch!)
The changelog is
here, and the complete diff since the last release is
here.
Why so long? A digression on the Facebook API
It's been a long time since the last release, and that's largely thanks to the excellent design of the Facebook Graph API. The core of the graph API -- objects and connections -- has proven to be a very logical, extensible, and stable design, and has been able to accommodate (without major changes) everything Facebook's released more or less since the beginning: new connection types, new actions on objects, the Open Graph, and more. That, in turn, has made my life as an SDK developer rather comfortable and easy :) It's been over a year since I've had to make any significant changes to the core of Koala, and to me that's a tribute to the quality of the work done by the Facebook engineering team a few years back.
That said, you'd probably all lynch me if I didn't draw the distinction between design and implementation. We've all felt the pain of those areas where the Graph API isn't well or consistently implemented -- parameters that (undocumentedly) have to be JSON encoded, weird or missing error messages, unexpected behavior. (There are people at Facebook who know about and feel our pain and are trying to get things fixed.) Fortunately (for me) it's something that rarely affects the core of Koala, but it's just as much a part of the Facebook API as the beautiful design it tends to obscure.
Anyway, that's enough from me -- thanks for listening. I've been sketching out a blog post on this…someday soon :)
Installation
As always:
gem "koala", "~> 1.6.0rc1"
gem install koala -- pre
What's next?
Nothing big -- for the reasons described above, there aren't any major development needs. I do have my eye on a big rewrite of the test suite to bring it up to modern standards, but otherwise feel free to suggest anything that Koala is missing or that could be improved.
Have a great week!
Best,
Alex