DEV Community

Allison
Allison

Posted on • Originally published at github.com

1

gemcompat: an open source db of undocumented gem incompatibilities with rails

TLDR: We created an open database of every gem version that’s silently incompatible with Rails. Check it out at https://github.com/infieldai/gemcompat

Our company is built on Rails, and part of our work involves upgrading Rails apps for our customers. In doing this we come across incompatibilities between packages that aren’t captured in gemspecs. Commonly a package will leave an open-ended upper bound in their gemspec (like activerecord >= 6.1) which can cause issues if the next version of Rails comes out and breaks something. I once tracked down an incompatibility between two packages that only surfaced as colors in images embedded in PDFs being inverted. These can waste a lot of time.

Last month we shared a script that checks an application against these kinds of issues for Rails 7.1. It was based on research we did reading a few thousand ruby changelogs looking for messages like “Added support for Rails 7.1.” People found it useful so we thought we’d turn it into a more complete project.

We’ve open sourced all the incompatibilities we know about across Rails 6.1, 7.0, and 7.1 at https://github.com/infieldai/gemcompat/. You can check your own codebase like this:

gem install gemcompat

gemcompat –package rails –target-version 7.1 –lockfile Gemfile.lock

Hope this is useful! We’d love you to try it out and let us know when you come across an incompatibility we don’t have. You can open a Github issue with anything you find and we’ll add it to the DB.

Image of Timescale

🚀 pgai Vectorizer: SQLAlchemy and LiteLLM Make Vector Search Simple

We built pgai Vectorizer to simplify embedding management for AI applications—without needing a separate database or complex infrastructure. Since launch, developers have created over 3,000 vectorizers on Timescale Cloud, with many more self-hosted.

Read full post →

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Discover a treasure trove of wisdom within this insightful piece, highly respected in the nurturing DEV Community enviroment. Developers, whether novice or expert, are encouraged to participate and add to our shared knowledge basin.

A simple "thank you" can illuminate someone's day. Express your appreciation in the comments section!

On DEV, sharing ideas smoothens our journey and strengthens our community ties. Learn something useful? Offering a quick thanks to the author is deeply appreciated.

Okay