rubygems / rubygems

Library packaging and distribution for Ruby.
https://rubygems.org/
Other
3.67k stars 1.74k forks source link

libruby.so.3.2 cannot open shared object file No such file or directory - /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.so #7523

Closed stephenson closed 6 months ago

stephenson commented 7 months ago

Totaly vanlilla rails app, have suddanly started to fail deply to Render.

LoadError: libruby.so.3.2: cannot open shared object file: No such file or directory - /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.so
  <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
  <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
  /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.rb:13:in `<top (required)>'
  <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
  <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems.rb:609:in `load_yaml'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:556:in `read_checksums'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:618:in `block (2 levels) in verify'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/tar_reader.rb:23:in `new'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:617:in `block in verify'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/file_source.rb:30:in `open'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/file_source.rb:30:in `with_read_io'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:616:in `verify'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:597:in `spec'
  /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/installer.rb:288:in `spec'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/rubygems_gem_installer.rb:97:in `spec'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/source/rubygems.rb:186:in `install'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/installer/gem_installer.rb:54:in `install'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/installer/gem_installer.rb:16:in `install_from_spec'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/installer/parallel_installer.rb:130:in `do_install'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/installer/parallel_installer.rb:121:in `block in worker_pool'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/worker.rb:62:in `apply_func'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/worker.rb:57:in `block in process_queue'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/worker.rb:54:in `loop'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/worker.rb:54:in `process_queue'
  /opt/render/project/.gems/gems/bundler-2.4.21/lib/bundler/worker.rb:90:in `block (2 levels) in create_threads'

Environment

Bundler       2.4.21
  Platforms   ruby, x86_64-linux
Ruby          3.2.2p53 (2023-03-30 revision e51014f9c05aa65cbf203442d37fef7c12390015) [x86_64-linux]
  Full Path   /opt/render/project/rubies/ruby-3.2.2/bin/ruby
  Config Dir  /opt/render/project/rubies/ruby-3.2.2/etc
RubyGems      3.4.22
  Gem Home    /opt/render/project/.gems/ruby/3.2.0
  Gem Path    /opt/render/project/.gems/ruby/3.2.0
  User Home   /opt/render
  User Path   /opt/render/.local/share/gem/ruby/3.2.0
  Bin Dir     /opt/render/project/.gems/ruby/3.2.0/bin
OpenSSL       
  Compiled    OpenSSL 1.1.1n  15 Mar 2022
  Loaded      OpenSSL 1.1.1n  15 Mar 2022
  Cert File   /usr/lib/ssl/cert.pem
  Cert Dir    /usr/lib/ssl/certs
Tools         
  Git         2.20.1
  RVM         not installed
  rbenv       not installed
  chruby      not installed

Bundler Build Metadata

Built At          2023-10-17
Git SHA           d10b46bd15
Released Version  true

Bundler settings

app_config
  Set via BUNDLE_APP_CONFIG: "/opt/render/project/.gems"
bin
  Set via BUNDLE_BIN: "/opt/render/project/.gems/bin"
deployment
  Set via BUNDLE_DEPLOYMENT: true
path
  Set via BUNDLE_PATH: "/opt/render/project/.gems"
silence_root_warning
  Set via BUNDLE_SILENCE_ROOT_WARNING: true
system_bindir
  Set via BUNDLE_SYSTEM_BINDIR: "/opt/render/project/.gems/bin"
without
  Set via BUNDLE_WITHOUT: [:development, :test]

Gemfile

Gemfile

source "https://rubygems.org"
ruby "3.2.2"
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
gem "rails", "~> 7.1.3"
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
gem "sprockets-rails"
# Use the Puma web server [https://github.com/puma/puma]
gem "puma", ">= 5.0"
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
gem "importmap-rails"
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
gem "turbo-rails"
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
gem "stimulus-rails"
# Use Tailwind CSS [https://github.com/rails/tailwindcss-rails]
gem "tailwindcss-rails"
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
gem "jbuilder"
# Use Redis adapter to run Action Cable in production
# gem "redis", ">= 4.0.1"
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
# gem "kredis"
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
# gem "bcrypt", "~> 3.1.7"
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem "tzinfo-data", platforms: %i[ windows jruby ]
# Reduces boot times through caching; required in config/boot.rb
gem "bootsnap", require: false
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
# gem "image_processing", "~> 1.2"
group :development, :test do
  # See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
  gem "debug", platforms: %i[ mri windows ]
  # Use sqlite3 as the database for Active Record
gem "sqlite3", "~> 1.4"
end
group :development do
  # Use console on exceptions pages [https://github.com/rails/web-console]
  gem "web-console"
  # Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
  # gem "rack-mini-profiler"
  # Speed up commands on slow machines / big apps [https://github.com/rails/spring]
  # gem "spring"
end
group :test do
  # Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
  gem "capybara"
  gem "selenium-webdriver"
end
group :production do
  gem "pg"
end

Gemfile.lock

GEM
  remote: https://rubygems.org/
  specs:
    actioncable (7.1.3.2)
      actionpack (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      nio4r (~> 2.0)
      websocket-driver (>= 0.6.1)
      zeitwerk (~> 2.6)
    actionmailbox (7.1.3.2)
      actionpack (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      mail (>= 2.7.1)
      net-imap
      net-pop
      net-smtp
    actionmailer (7.1.3.2)
      actionpack (= 7.1.3.2)
      actionview (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      mail (~> 2.5, >= 2.5.4)
      net-imap
      net-pop
      net-smtp
      rails-dom-testing (~> 2.2)
    actionpack (7.1.3.2)
      actionview (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      nokogiri (>= 1.8.5)
      racc
      rack (>= 2.2.4)
      rack-session (>= 1.0.1)
      rack-test (>= 0.6.3)
      rails-dom-testing (~> 2.2)
      rails-html-sanitizer (~> 1.6)
    actiontext (7.1.3.2)
      actionpack (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      globalid (>= 0.6.0)
      nokogiri (>= 1.8.5)
    actionview (7.1.3.2)
      activesupport (= 7.1.3.2)
      builder (~> 3.1)
      erubi (~> 1.11)
      rails-dom-testing (~> 2.2)
      rails-html-sanitizer (~> 1.6)
    activejob (7.1.3.2)
      activesupport (= 7.1.3.2)
      globalid (>= 0.3.6)
    activemodel (7.1.3.2)
      activesupport (= 7.1.3.2)
    activerecord (7.1.3.2)
      activemodel (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      timeout (>= 0.4.0)
    activestorage (7.1.3.2)
      actionpack (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      marcel (~> 1.0)
    activesupport (7.1.3.2)
      base64
      bigdecimal
      concurrent-ruby (~> 1.0, >= 1.0.2)
      connection_pool (>= 2.2.5)
      drb
      i18n (>= 1.6, < 2)
      minitest (>= 5.1)
      mutex_m
      tzinfo (~> 2.0)
    addressable (2.8.6)
      public_suffix (>= 2.0.2, < 6.0)
    base64 (0.2.0)
    bigdecimal (3.1.7)
    bindex (0.8.1)
    bootsnap (1.18.3)
      msgpack (~> 1.2)
    builder (3.2.4)
    capybara (3.40.0)
      addressable
      matrix
      mini_mime (>= 0.1.3)
      nokogiri (~> 1.11)
      rack (>= 1.6.0)
      rack-test (>= 0.6.3)
      regexp_parser (>= 1.5, < 3.0)
      xpath (~> 3.2)
    concurrent-ruby (1.2.3)
    connection_pool (2.4.1)
    crass (1.0.6)
    date (3.3.4)
    debug (1.9.1)
      irb (~> 1.10)
      reline (>= 0.3.8)
    drb (2.2.1)
    erubi (1.12.0)
    globalid (1.2.1)
      activesupport (>= 6.1)
    i18n (1.14.4)
      concurrent-ruby (~> 1.0)
    importmap-rails (2.0.1)
      actionpack (>= 6.0.0)
      activesupport (>= 6.0.0)
      railties (>= 6.0.0)
    io-console (0.7.2)
    irb (1.12.0)
      rdoc
      reline (>= 0.4.2)
    jbuilder (2.11.5)
      actionview (>= 5.0.0)
      activesupport (>= 5.0.0)
    loofah (2.22.0)
      crass (~> 1.0.2)
      nokogiri (>= 1.12.0)
    mail (2.8.1)
      mini_mime (>= 0.1.1)
      net-imap
      net-pop
      net-smtp
    marcel (1.0.4)
    matrix (0.4.2)
    mini_mime (1.1.5)
    minitest (5.22.3)
    msgpack (1.7.2)
    mutex_m (0.2.0)
    net-imap (0.4.10)
      date
      net-protocol
    net-pop (0.1.2)
      net-protocol
    net-protocol (0.2.2)
      timeout
    net-smtp (0.4.0.1)
      net-protocol
    nio4r (2.7.0)
    nokogiri (1.16.3-aarch64-linux)
      racc (~> 1.4)
    nokogiri (1.16.3-arm64-darwin)
      racc (~> 1.4)
    nokogiri (1.16.3-x86_64-linux)
      racc (~> 1.4)
    pg (1.5.6)
    psych (5.1.2)
      stringio
    public_suffix (5.0.4)
    puma (6.4.2)
      nio4r (~> 2.0)
    racc (1.7.3)
    rack (3.0.9.1)
    rack-session (2.0.0)
      rack (>= 3.0.0)
    rack-test (2.1.0)
      rack (>= 1.3)
    rackup (2.1.0)
      rack (>= 3)
      webrick (~> 1.8)
    rails (7.1.3.2)
      actioncable (= 7.1.3.2)
      actionmailbox (= 7.1.3.2)
      actionmailer (= 7.1.3.2)
      actionpack (= 7.1.3.2)
      actiontext (= 7.1.3.2)
      actionview (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activemodel (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      bundler (>= 1.15.0)
      railties (= 7.1.3.2)
    rails-dom-testing (2.2.0)
      activesupport (>= 5.0.0)
      minitest
      nokogiri (>= 1.6)
    rails-html-sanitizer (1.6.0)
      loofah (~> 2.21)
      nokogiri (~> 1.14)
    railties (7.1.3.2)
      actionpack (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      irb
      rackup (>= 1.0.0)
      rake (>= 12.2)
      thor (~> 1.0, >= 1.2.2)
      zeitwerk (~> 2.6)
    rake (13.1.0)
    rdoc (6.6.2)
      psych (>= 4.0.0)
    regexp_parser (2.9.0)
    reline (0.4.3)
      io-console (~> 0.5)
    rexml (3.2.6)
    rubyzip (2.3.2)
    selenium-webdriver (4.18.1)
      base64 (~> 0.2)
      rexml (~> 3.2, >= 3.2.5)
      rubyzip (>= 1.2.2, < 3.0)
      websocket (~> 1.0)
    sprockets (4.2.1)
      concurrent-ruby (~> 1.0)
      rack (>= 2.2.4, < 4)
    sprockets-rails (3.4.2)
      actionpack (>= 5.2)
      activesupport (>= 5.2)
      sprockets (>= 3.0.0)
    sqlite3 (1.7.3-aarch64-linux)
    sqlite3 (1.7.3-arm64-darwin)
    sqlite3 (1.7.3-x86_64-linux)
    stimulus-rails (1.3.3)
      railties (>= 6.0.0)
    stringio (3.1.0)
    tailwindcss-rails (2.3.0-aarch64-linux)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-arm64-darwin)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-x86_64-linux)
      railties (>= 6.0.0)
    thor (1.3.1)
    timeout (0.4.1)
    turbo-rails (2.0.5)
      actionpack (>= 6.0.0)
      activejob (>= 6.0.0)
      railties (>= 6.0.0)
    tzinfo (2.0.6)
      concurrent-ruby (~> 1.0)
    web-console (4.2.1)
      actionview (>= 6.0.0)
      activemodel (>= 6.0.0)
      bindex (>= 0.4.0)
      railties (>= 6.0.0)
    webrick (1.8.1)
    websocket (1.2.10)
    websocket-driver (0.7.6)
      websocket-extensions (>= 0.1.0)
    websocket-extensions (0.1.5)
    xpath (3.2.0)
      nokogiri (~> 1.8)
    zeitwerk (2.6.13)
PLATFORMS
  aarch64-linux
  arm64-darwin-22
  x86_64-linux
DEPENDENCIES
  bootsnap
  capybara
  debug
  importmap-rails
  jbuilder
  pg
  puma (>= 5.0)
  rails (~> 7.1.3)
  selenium-webdriver
  sprockets-rails
  sqlite3 (~> 1.4)
  stimulus-rails
  tailwindcss-rails
  turbo-rails
  tzinfo-data
  web-console
RUBY VERSION
   ruby 3.2.2p53
BUNDLED WITH
   2.4.21
jmitchell238 commented 7 months ago

Also experiencing this.

alchemist-guy commented 7 months ago

I dont know what happened it was working fine 2 days ago and now when I redeploy it fails

antonioeloi commented 7 months ago

It also happens to me in Ruby 3.2.2.

To give more context, this is the output with the flag verbose:

[...]
Using rackup 2.1.0
10:  rackup (2.1.0) from /opt/render/project/.gems/ruby/3.2.0/specifications/rackup-2.1.0.gemspec
15:  drb (2.2.0) from /opt/render/project/.gems/ruby/3.2.0/specifications/drb-2.2.0.gemspec
Using net-pop 0.1.2
Using net-smtp 0.4.0.1
3:  net-pop (0.1.2) from /opt/render/project/.gems/ruby/3.2.0/specifications/net-pop-0.1.2.gemspec
7:  net-smtp (0.4.0.1) from /opt/render/project/.gems/ruby/3.2.0/specifications/net-smtp-0.4.0.1.gemspec
Ignoring psych-5.1.2 because its extensions are not built. Try: gem pristine psych --version 5.1.2
Ignoring stringio-3.1.0 because its extensions are not built. Try: gem pristine stringio --version 3.1.0
--- ERROR REPORT TEMPLATE -------------------------------------------------------
LoadError: libruby.so.3.2: cannot open shared object file: No such file or directory - /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.so
[...]
AurelienDevGames commented 7 months ago

Same deal here, also with ruby 3.2.2

Fetching gem metadata from https://rubygems.org/........
Ignoring erb-4.0.4 because its extensions are not built. Try: gem pristine erb --version 4.0.4
Ignoring psych-5.1.2 because its extensions are not built. Try: gem pristine psych --version 5.1.2
Ignoring stringio-3.1.0 because its extensions are not built. Try: gem pristine stringio --version 3.1.0
--- ERROR REPORT TEMPLATE -------------------------------------------------------
LoadError: libruby.so.3.2: cannot open shared object file: No such file or directory - /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.so
  <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
          <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
          /opt/render/project/.gems/ruby/3.2.0/gems/psych-5.1.2/lib/psych.rb:13:in `<top (required)>'
          <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
          <internal:/opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:149:in `require'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems.rb:609:in `load_yaml'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:556:in `read_checksums'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:618:in `block (2 levels) in verify'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/tar_reader.rb:23:in `new'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:617:in `block in verify'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/file_source.rb:30:in `open'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package/file_source.rb:30:in `with_read_io'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:616:in `verify'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/package.rb:597:in `spec'
          /opt/render/project/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/installer.rb:288:in `spec'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/rubygems_gem_installer.rb:101:in `spec'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/source/rubygems.rb:186:in `install'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/installer/gem_installer.rb:54:in `install'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/installer/gem_installer.rb:16:in `install_from_spec'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/installer/parallel_installer.rb:132:in `do_install'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/installer/parallel_installer.rb:123:in `block in worker_pool'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/worker.rb:62:in `apply_func'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/worker.rb:57:in `block in process_queue'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/worker.rb:54:in `loop'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/worker.rb:54:in `process_queue'
          /opt/render/project/.gems/gems/bundler-2.5.5/lib/bundler/worker.rb:90:in `block (2 levels) in create_threads'

Environment

Bundler       2.5.5
  Platforms   ruby, x86_64-linux
Ruby          3.2.2p53 (2023-03-30 revision e51014f9c05aa65cbf203442d37fef7c12390015) [x86_64-linux]
  Full Path   /opt/render/project/rubies/ruby-3.2.2/bin/ruby
  Config Dir  /opt/render/project/rubies/ruby-3.2.2/etc
RubyGems      3.4.22
  Gem Home    /opt/render/project/.gems/ruby/3.2.0
  Gem Path    /opt/render/project/.gems/ruby/3.2.0
  User Home   /opt/render
  User Path   /opt/render/.local/share/gem/ruby/3.2.0
  Bin Dir     /opt/render/project/.gems/ruby/3.2.0/bin
OpenSSL       
  Compiled    OpenSSL 1.1.1n  15 Mar 2022
  Loaded      OpenSSL 1.1.1n  15 Mar 2022
  Cert File   /usr/lib/ssl/cert.pem
  Cert Dir    /usr/lib/ssl/certs
Tools         
  Git         2.20.1
  RVM         not installed
  rbenv       not installed
  chruby      not installed

Bundler Build Metadata

Built At          2024-01-18
Git SHA           2efa8cec93
Released Version  true

Bundler settings

app_config
  Set via BUNDLE_APP_CONFIG: "/opt/render/project/.gems"
bin
  Set via BUNDLE_BIN: "/opt/render/project/.gems/bin"
deployment
  Set via BUNDLE_DEPLOYMENT: true
path
  Set via BUNDLE_PATH: "/opt/render/project/.gems"
silence_root_warning
  Set via BUNDLE_SILENCE_ROOT_WARNING: true
system_bindir
  Set via BUNDLE_SYSTEM_BINDIR: "/opt/render/project/.gems/bin"
without
  Set via BUNDLE_WITHOUT: [:development, :test]

Gemfile

Gemfile

source 'https://rubygems.org'
ruby '3.2.2'
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
gem 'rails', '~> 7.1.2'
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
gem 'sprockets-rails'
# Use pg as the database for Active Record
gem 'pg', '~> 1.1'
# Use the Puma web server [https://github.com/puma/puma]
gem 'puma', '>= 5.0'
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
gem 'importmap-rails'
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
gem 'turbo-rails'
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
gem 'stimulus-rails'
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
gem 'jbuilder'
# Use Redis adapter to run Action Cable in production
# gem "redis", ">= 4.0.1"
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
# gem "kredis"
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
# gem "bcrypt", "~> 3.1.7"
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: %i[windows jruby]
# Reduces boot times through caching; required in config/boot.rb
gem 'bootsnap', require: false
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
# gem "image_processing", "~> 1.2"
gem 'faker'
group :development, :test do
  # See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
  gem 'debug', platforms: %i[mri windows]
  gem 'dotenv'
end
group :development do
  # Use console on exceptions pages [https://github.com/rails/web-console]
  gem 'web-console'
  # Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
  # gem "rack-mini-profiler"
  # Speed up commands on slow machines / big apps [https://github.com/rails/spring]
  # gem "spring"
end
group :test do
  # Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
  gem 'capybara'
  gem 'selenium-webdriver'
end
gem 'stripe'
gem 'tailwindcss-rails', '~> 2.3'
gem 'honeybadger', '~> 5.4'
gem 'devise', '~> 4.9'
gem "icalendar", "~> 2.10"
gem "phlex-rails", "~> 1.1"
gem "good_job", "~> 3.25"
gem "sendgrid-ruby", "~> 6.7"
gem "twilio-ruby", "~> 6.12"
gem "youtube_rails", "~> 1.3"

Gemfile.lock

GEM
  remote: https://rubygems.org/
  specs:
    actioncable (7.1.3.2)
      actionpack (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      nio4r (~> 2.0)
      websocket-driver (>= 0.6.1)
      zeitwerk (~> 2.6)
    actionmailbox (7.1.3.2)
      actionpack (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      mail (>= 2.7.1)
      net-imap
      net-pop
      net-smtp
    actionmailer (7.1.3.2)
      actionpack (= 7.1.3.2)
      actionview (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      mail (~> 2.5, >= 2.5.4)
      net-imap
      net-pop
      net-smtp
      rails-dom-testing (~> 2.2)
    actionpack (7.1.3.2)
      actionview (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      nokogiri (>= 1.8.5)
      racc
      rack (>= 2.2.4)
      rack-session (>= 1.0.1)
      rack-test (>= 0.6.3)
      rails-dom-testing (~> 2.2)
      rails-html-sanitizer (~> 1.6)
    actiontext (7.1.3.2)
      actionpack (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      globalid (>= 0.6.0)
      nokogiri (>= 1.8.5)
    actionview (7.1.3.2)
      activesupport (= 7.1.3.2)
      builder (~> 3.1)
      erubi (~> 1.11)
      rails-dom-testing (~> 2.2)
      rails-html-sanitizer (~> 1.6)
    activejob (7.1.3.2)
      activesupport (= 7.1.3.2)
      globalid (>= 0.3.6)
    activemodel (7.1.3.2)
      activesupport (= 7.1.3.2)
    activerecord (7.1.3.2)
      activemodel (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      timeout (>= 0.4.0)
    activestorage (7.1.3.2)
      actionpack (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      marcel (~> 1.0)
    activesupport (7.1.3.2)
      base64
      bigdecimal
      concurrent-ruby (~> 1.0, >= 1.0.2)
      connection_pool (>= 2.2.5)
      drb
      i18n (>= 1.6, < 2)
      minitest (>= 5.1)
      mutex_m
      tzinfo (~> 2.0)
    addressable (2.8.6)
      public_suffix (>= 2.0.2, < 6.0)
    base64 (0.2.0)
    bcrypt (3.1.20)
    bigdecimal (3.1.7)
    bindex (0.8.1)
    bootsnap (1.18.3)
      msgpack (~> 1.2)
    builder (3.2.4)
    capybara (3.40.0)
      addressable
      matrix
      mini_mime (>= 0.1.3)
      nokogiri (~> 1.11)
      rack (>= 1.6.0)
      rack-test (>= 0.6.3)
      regexp_parser (>= 1.5, < 3.0)
      xpath (~> 3.2)
    cgi (0.4.1)
    concurrent-ruby (1.2.3)
    connection_pool (2.4.1)
    crass (1.0.6)
    date (3.3.4)
    debug (1.9.1)
      irb (~> 1.10)
      reline (>= 0.3.8)
    devise (4.9.3)
      bcrypt (~> 3.0)
      orm_adapter (~> 0.1)
      railties (>= 4.1.0)
      responders
      warden (~> 1.2.3)
    dotenv (3.1.0)
    drb (2.2.1)
    erb (4.0.4)
      cgi (>= 0.3.3)
    erubi (1.12.0)
    et-orbi (1.2.9)
      tzinfo
    faker (3.2.3)
      i18n (>= 1.8.11, < 2)
    faraday (2.9.0)
      faraday-net_http (>= 2.0, < 3.2)
    faraday-net_http (3.1.0)
      net-http
    fugit (1.10.1)
      et-orbi (~> 1, >= 1.2.7)
      raabro (~> 1.4)
    globalid (1.2.1)
      activesupport (>= 6.1)
    good_job (3.26.2)
      activejob (>= 6.0.0)
      activerecord (>= 6.0.0)
      concurrent-ruby (>= 1.0.2)
      fugit (>= 1.1)
      railties (>= 6.0.0)
      thor (>= 0.14.1)
    honeybadger (5.7.0)
    i18n (1.14.4)
      concurrent-ruby (~> 1.0)
    icalendar (2.10.1)
      ice_cube (~> 0.16)
    ice_cube (0.16.4)
    importmap-rails (2.0.1)
      actionpack (>= 6.0.0)
      activesupport (>= 6.0.0)
      railties (>= 6.0.0)
    io-console (0.7.2)
    irb (1.12.0)
      rdoc
      reline (>= 0.4.2)
    jbuilder (2.11.5)
      actionview (>= 5.0.0)
      activesupport (>= 5.0.0)
    jwt (2.8.1)
      base64
    loofah (2.22.0)
      crass (~> 1.0.2)
      nokogiri (>= 1.12.0)
    mail (2.8.1)
      mini_mime (>= 0.1.1)
      net-imap
      net-pop
      net-smtp
    marcel (1.0.4)
    matrix (0.4.2)
    mini_mime (1.1.5)
    minitest (5.22.3)
    msgpack (1.7.2)
    mutex_m (0.2.0)
    net-http (0.4.1)
      uri
    net-imap (0.4.10)
      date
      net-protocol
    net-pop (0.1.2)
      net-protocol
    net-protocol (0.2.2)
      timeout
    net-smtp (0.4.0.1)
      net-protocol
    nio4r (2.7.0)
    nokogiri (1.16.2-aarch64-linux)
      racc (~> 1.4)
    nokogiri (1.16.2-arm-linux)
      racc (~> 1.4)
    nokogiri (1.16.2-arm64-darwin)
      racc (~> 1.4)
    nokogiri (1.16.2-x86-linux)
      racc (~> 1.4)
    nokogiri (1.16.2-x86_64-darwin)
      racc (~> 1.4)
    nokogiri (1.16.2-x86_64-linux)
      racc (~> 1.4)
    orm_adapter (0.5.0)
    pg (1.5.6)
    phlex (1.9.1)
      concurrent-ruby (~> 1.2)
      erb (>= 4)
      zeitwerk (~> 2.6)
    phlex-rails (1.1.1)
      phlex (~> 1.9)
      railties (>= 6.1, < 8)
      zeitwerk (~> 2.6)
    psych (5.1.2)
      stringio
    public_suffix (5.0.4)
    puma (6.4.2)
      nio4r (~> 2.0)
    raabro (1.4.0)
    racc (1.7.3)
    rack (3.0.9.1)
    rack-session (2.0.0)
      rack (>= 3.0.0)
    rack-test (2.1.0)
      rack (>= 1.3)
    rackup (2.1.0)
      rack (>= 3)
      webrick (~> 1.8)
    rails (7.1.3.2)
      actioncable (= 7.1.3.2)
      actionmailbox (= 7.1.3.2)
      actionmailer (= 7.1.3.2)
      actionpack (= 7.1.3.2)
      actiontext (= 7.1.3.2)
      actionview (= 7.1.3.2)
      activejob (= 7.1.3.2)
      activemodel (= 7.1.3.2)
      activerecord (= 7.1.3.2)
      activestorage (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      bundler (>= 1.15.0)
      railties (= 7.1.3.2)
    rails-dom-testing (2.2.0)
      activesupport (>= 5.0.0)
      minitest
      nokogiri (>= 1.6)
    rails-html-sanitizer (1.6.0)
      loofah (~> 2.21)
      nokogiri (~> 1.14)
    railties (7.1.3.2)
      actionpack (= 7.1.3.2)
      activesupport (= 7.1.3.2)
      irb
      rackup (>= 1.0.0)
      rake (>= 12.2)
      thor (~> 1.0, >= 1.2.2)
      zeitwerk (~> 2.6)
    rake (13.1.0)
    rdoc (6.6.2)
      psych (>= 4.0.0)
    regexp_parser (2.9.0)
    reline (0.4.3)
      io-console (~> 0.5)
    responders (3.1.1)
      actionpack (>= 5.2)
      railties (>= 5.2)
    rexml (3.2.6)
    ruby_http_client (3.5.5)
    rubyzip (2.3.2)
    selenium-webdriver (4.18.1)
      base64 (~> 0.2)
      rexml (~> 3.2, >= 3.2.5)
      rubyzip (>= 1.2.2, < 3.0)
      websocket (~> 1.0)
    sendgrid-ruby (6.7.0)
      ruby_http_client (~> 3.4)
    sprockets (4.2.1)
      concurrent-ruby (~> 1.0)
      rack (>= 2.2.4, < 4)
    sprockets-rails (3.4.2)
      actionpack (>= 5.2)
      activesupport (>= 5.2)
      sprockets (>= 3.0.0)
    stimulus-rails (1.3.3)
      railties (>= 6.0.0)
    stringio (3.1.0)
    stripe (10.12.0)
    tailwindcss-rails (2.3.0)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-aarch64-linux)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-arm-linux)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-arm64-darwin)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-x86_64-darwin)
      railties (>= 6.0.0)
    tailwindcss-rails (2.3.0-x86_64-linux)
      railties (>= 6.0.0)
    thor (1.3.1)
    timeout (0.4.1)
    turbo-rails (2.0.5)
      actionpack (>= 6.0.0)
      activejob (>= 6.0.0)
      railties (>= 6.0.0)
    twilio-ruby (6.12.1)
      faraday (>= 0.9, < 3.0)
      jwt (>= 1.5, < 3.0)
      nokogiri (>= 1.6, < 2.0)
    tzinfo (2.0.6)
      concurrent-ruby (~> 1.0)
    uri (0.13.0)
    warden (1.2.9)
      rack (>= 2.0.9)
    web-console (4.2.1)
      actionview (>= 6.0.0)
      activemodel (>= 6.0.0)
      bindex (>= 0.4.0)
      railties (>= 6.0.0)
    webrick (1.8.1)
    websocket (1.2.10)
    websocket-driver (0.7.6)
      websocket-extensions (>= 0.1.0)
    websocket-extensions (0.1.5)
    xpath (3.2.0)
      nokogiri (~> 1.8)
    youtube_rails (1.3.0)
    zeitwerk (2.6.13)
PLATFORMS
  aarch64-linux
  arm-linux
  arm64-darwin
  x86-linux
  x86_64-darwin
  x86_64-linux
DEPENDENCIES
  bootsnap
  capybara
  debug
  devise (~> 4.9)
  dotenv
  faker
  good_job (~> 3.25)
  honeybadger (~> 5.4)
  icalendar (~> 2.10)
  importmap-rails
  jbuilder
  pg (~> 1.1)
  phlex-rails (~> 1.1)
  puma (>= 5.0)
  rails (~> 7.1.2)
  selenium-webdriver
  sendgrid-ruby (~> 6.7)
  sprockets-rails
  stimulus-rails
  stripe
  tailwindcss-rails (~> 2.3)
  turbo-rails
  twilio-ruby (~> 6.12)
  tzinfo-data
  web-console
  youtube_rails (~> 1.3)
RUBY VERSION
   ruby 3.2.2p53
BUNDLED WITH
   2.5.5
--- TEMPLATE END ----------------------------------------------------------------
Unfortunately, an unexpected error occurred, and Bundler cannot continue.
timhaines commented 7 months ago

On render, if you trigger a manual deploy, and choose "clear build cache & deploy" in the manual deploy dropdown, it deploys without hitting this error. Seems Render updated Rubygems, which was the catalyst for this.

AurelienDevGames commented 7 months ago

@timhaines solution fixed it on my side thank you :+1:

antonioeloi commented 7 months ago

@timhaines, I confirm it's working after following your suggestion. Furthermore, all automatic and pipeline deployments have resumed working correctly! Thank you 👍🏻

deivid-rodriguez commented 7 months ago

Hi. Yeah, this does seem like some issue in the render Ruby environment, where the psych gem was not properly built. Not sure what might've changed in the render side. I'll leave this issue opened so that the solution proposed is more discoverable.

deivid-rodriguez commented 7 months ago

I guess the upgrade of the default ruby version 2 days ago caused some trouble: https://docs.render.com/ruby-version#history-of-default-ruby-versions.

alchemist-guy commented 7 months ago

On render, if you trigger a manual deploy, and choose "clear build cache & deploy" in the manual deploy dropdown, it deploys without hitting this error. Seems Render updated Rubygems, which was the catalyst for this.

not working on my side

chalizards commented 7 months ago

I fixed this error in my local (I'm using docker) doing the following: (I ended up with this solution based on this discussion)

Replace /path/ with your local path. You can find the right paths with whereis ruby

Hope this helps!

deivid-rodriguez commented 6 months ago

Hei @chalizards, can you reproduce this error locally, outside of the render environment? Just wondering if we can do better at detecting the problem and maybe giving a better error.

deivid-rodriguez commented 6 months ago

In any case, I see no more :+1: in this issue for a few days, so I'm closing this since it's not an issue in Bundler or RubyGems. Error message remains searchable in any case, so hopefully we don't get duplicate tickets about this!

In any case, happy to try improve the error message here if we're able to simulate this locally.

bentremblay commented 6 months ago

For anyone ending up here after a Google search, this got answered on Render's forum: https://community.render.com/t/bundler-install-no-such-file-or-directory/20343

This issue occurs after running a build that updates the RubyGems gem. You will need to push a manual deployment with a clear build cache. I guess that for some reason, the psych gem’s native bindings haven’t been previously built. The update to RubyGems is now causing this to be used/checked, and you get this error. Clearing the build cache forces the native binding to be built as the gem is reinstalled.

Clear build cache and deploy did the trick for me from Render's interface (manual deploy).

noway commented 1 month ago

If you're using Docker, follow @chalizards's instructions inside the Docker container. Worked for me 🙌🎉