Sort order of results in OCLC AssignFAST/fastsuggest API
Bibliographic Wilderness
by jrochkind
1M ago
We have long used the free OCLC AssignFAST API to power an auto-suggest/auto-complete in some of our staff metadata entry forms. (Note: While OCLC calls this service “AssignFAST” in docs, the base URL instead includes the term fastsuggest as in http://fast.oclc.org/searchfast/fastsuggest?, which may be confusing for some!) Recently our staff reported they thought the sort ..read more
Visit website
Cloudfront in front of S3 using response-content-disposition
Bibliographic Wilderness
by jrochkind
3M ago
At the Science History Institute Digital Collections, we have a public collection of digitized historical materials (mostly photographic images of pages). We store these digitized assets — originals as well as various resizes and thumbnails used on our web pages — in AWS S3. Currently, we provide access to these assets directly from S3. For some of our deliveries, we also use the S3 feature of a response-content-disposition query parameter in a signed expiring S3 url, to have the response include an HTTP Content-Disposition header with a filename and often attachment disposition, so when the e ..read more
Visit website
Run your Rails gem CI on rails main branch
Bibliographic Wilderness
by jrochkind
3M ago
attr_json is basically an ActiveRecord extension. It works with multiple versions of Rails, so definitely runs CI on each version it supports. But a while ago on attr_json, i set up CI to run on Rails main unreleased branch. I already was using appraisal to test under multiple Rails versions. (which I recommend; sure it seems easy enough to do this ‘manually’ with conditionals in your Gemspec or separate Gemfiles and BUNDLE_GEMFILE — but as soon as you start needing things like different extra dependencies (version of rspec-rails anyone?) for different Rails versions… stop reinventing the whee ..read more
Visit website
Consider a small donation to rubyland.news?
Bibliographic Wilderness
by jrochkind
10M ago
I started rubyland.news a few years ago because it was a thing I wanted to see for the Ruby community. I had been feeling a shrinking of the ruby open source collaborative community, it felt like the room was emptying out. If you find value in Rubyland News, just a few dollars contribution on my Github Sponsors page would be so appreciated. I wanted to make people writing about ruby and what they were doing with it visible to each other and to the community, in order to try to (re)build/preserve/strengthen a self-conception as a community, connect people to each other, provide entry to newcome ..read more
Visit website
Beware sinatra, rails 7.1, rack 3, resque bundler dependency resolution
Bibliographic Wilderness
by jrochkind
10M ago
tldr practical advice for google: If you use resque 3.6.0 or less, and Rails 7.1, and are getting an error: cannot load such file -- rack/showexceptions — you probably need to add rack "~> 2.0" to your Gemfile! The latest version of the ruby gem sinatra, as I write this, is 3.1.0, and it does not yet support the recently released rack 3. It correctly specifies that in it’s gemspec, with gem "rack", "~> 2.2", ">= 2.2.4” [And as of this writing, that is true in sinatra github main branch too, no work has been done to allow rack 3.x] The new Rails 7.1 does work with and allow Rack 3.x ..read more
Visit website
S3 CORS headers proxied by CloudFront require HEAD not just GET?
Bibliographic Wilderness
by jrochkind
1y ago
I’m not totally sure what happened, but the tldr is that at the end of last week, our video.js-played HLS videos served from an S3 bucket — via CloudFront — appears to have started requiring us to list “HEAD” in the “AllowedMethods” for CORS configuraton, in addition to pre-existing “GET”. I’m curious if anyone else has any insight into what’s going on there… I have some vague guesses at the end, but still don’t really have a handle on it. Our setup: HLS video from S3 buckets We use the open-source video.js to display some video, in the HLS format. Which involves linking to a .m3u8 manifest fi ..read more
Visit website
Investigating OCR and Text PDFs from Digital Collections
Bibliographic Wilderness
by jrochkind
1y ago
At the Science History Institute Digital Collections, we have a fairly small collection compared to some peers (~70,000 images) of historical materials. Many of those images are of text: Books, pamphlets, advertisements, memos, etc. We haven’t previously done any OCR (Optical Character Recognition), but started thinking about doing that. In addition to using captured text for the site-wide search, it made sense to us to look to providing: “search inside the book/work”, with results highlighted on in-browser page images, such as provided by this example from Internet Archive using their own vi ..read more
Visit website
Escaping/encoding URI components in ruby 3.2
Bibliographic Wilderness
by jrochkind
1y ago
Thanks to zverok_kha’s awesome writeup of Ruby changes, I noticed a new method released in ruby 3.2: CGI.escapeURIComponent This is the right thing to use if you have an arbitrary string that might include characters not legal in a URI/URL, and you want to include it as a path component or part of the query string: require 'cgi' url = "https://example.com/some/#{ CGI.escapeURIComponent path_component }" + "?#{CGI.escapeURIComponent my_key}=#{CGI.escapeURIComponent my_value}" The docs helpfully refer us to RFC3986, a rare citation in the wild world of confusing and vaguely-described imp ..read more
Visit website
Attr_json 2.0 release: ActiveRecord attributes backed by JSON column
Bibliographic Wilderness
by jrochkind
1y ago
attr_json is a gem to provide attributes in ActiveRecord that are serialized to a JSON column, usually postgres jsonb, multiple attributes in a json hash. In a way that can be treated as much as possible like any other “ordinary” (database column) ActiveRecord. It supports arrays and nested models as hashes, and the embedded nested models can also be treated much as an ordinary “associated” record — for instance CI build tests with cocoon , and I’ve had a report that it works well with stimulus nested forms, but I don’t currently know how to use those. (PR welcome for a test in build?) An exam ..read more
Visit website
A tiny donation to rubyland.news would mean a lot
Bibliographic Wilderness
by jrochkind
1y ago
I started rubyland.news in 2016 because it was I thing I wanted to see for the ruby community. I had been feeling a shrinking of the ruby open source collaborative community, it felt like the room was emptying out. If you find value in Rubyland News, just a few dollars contribution on my Github Sponsors page would be so appreciated. I wanted to make people writing about ruby and what they were doing with it visible to each other and to the community, in order to try to (re)build/preserve/strengthen a self-conception as a community, connect people to each other, provide entry to newcomers, and ..read more
Visit website

Follow Bibliographic Wilderness on FeedSpot

Continue with Google
Continue with Apple
OR