[openstreetmap/openstreetmap-website] Prevent the legacy oauth gem from crashing on Ruby >=3.2 (PR #4399)

Tilmann Singer notifications at github.com
Mon Dec 11 16:27:30 UTC 2023


Hi 👋🏾 , openstreetmap newbie here, somewhat familiar with Rails. I wanted to try `openstreetmap-website`  locally and ran into the undefined method `File.exists?` error described [here](https://github.com/openstreetmap/openstreetmap-website/issues/4083) with Ruby 3.2.2.

The installation instructions do not explicitly rule out Ruby 3.2 so I found it a bit surprising. As said in #4083 the only reason this happens is the legacy oauth gem at 0.4.7, which is [going to be removed eventually](https://github.com/openstreetmap/operations/issues/867). Do you think the hack in this PR is an acceptable band-aid to ease the first-time developer experience until the oauth gem is removed? It's a bit ugly I admit, but couldn't think of a better way apart from forking the gem.

You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/4399

-- Commit Summary --

  * Prevent the legacy oauth gem from crashing on Ruby >=3.2

-- File Changes --

    M config/application.rb (1)
    A lib/legacy_oauth_gem_support.rb (4)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/4399.patch
https://github.com/openstreetmap/openstreetmap-website/pull/4399.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/4399
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/4399 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20231211/50ffa840/attachment-0001.htm>


More information about the rails-dev mailing list