gwu-libraries/obento — pull request #70 by kerchner (2013-08-13 00:31:42+00:00)
Title: T6 libsitesearch

Please take a close look at the logic around line 301 in views.py. It is a very bad kluge. It breaks under certain circumstances (try a search on "University's"). The issue I have not yet been able to solve is that the Response object in this case contains a utf-8 encoded string essentially of the form: u'\ufeff{"nodes":[{"node":{"title":"Digital Collections","view_node":"40"}}, ... }' . Due to the encoding marker, this itself is not a well-formed JSON object, and it chokes json.loads() (same result if invoked within Response.json()). Right now I am literally hacking off the encoding marker at position 0, which I realize is in incredibly corrupt thing to do. Any ideas would be most welcomed.