1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

bundle installできない!

Last updated at Posted at 2023-02-14

概要

railsチュートリアルで学ぼうとして、環境を構築している最中に起こったことです。
解決までの道のりを自分なりにまとめていきます。

環境

mac
AWS
cloud9
linux

起こったこと

ターミナル
ec2-user:~/environment/アプリ名 (main) $ bundle _2.3.14_ install                                                                                  
Fetching gem metadata from https://rubygems.org/..........
Resolving dependencies...
Bundler could not find compatible versions for gem "activesupport":
  In snapshot (Gemfile.lock):
    activesupport (= 6.1.7.2)

  In Gemfile:
    jbuilder (= 2.11.5) was resolved to 2.11.5, which depends on
      activesupport (>= 5.0.0)

    rails (= 7.0.4) was resolved to 7.0.4, which depends on
      activesupport (= 7.0.4)

    sprockets-rails (= 3.4.2) was resolved to 3.4.2, which depends on
      activesupport (>= 5.2)

Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.

なんだろう...
Running `bundle update
これだ!

ターミナル
ec2-user:~/environment/アプリ名 (main) $ bundle update
Fetching gem metadata from https://rubygems.org/...........
Resolving dependencies....
〜〜〜
Bundle updated!

できたわ...

railsってアプリ作ったことがある人はわかると思うのですが、エラー分がわかりづらかったり、支離滅裂なことを提案している感があって、あまり参考にしていなかったんです。私の勉強不足ですね...

エラー文をよく読む。これからはそれを意識します...

参考にさせていただいた記事

【Rails】Gemのバージョンエラー「Bundler could not find compatible versions for gem」が出てきたときの対処法

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?