# Error when executing bundle install

**URL:** <https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822>\
**Category:** Help\
**Created:** [January 7, 2024, 1:29am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822 "2024-01-07T01:29:22Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![dani5](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/dani5/32/5703_2.png) [@dani5](https://talk.jekyllrb.com/u/dani5)\
**Post date:** [January 7, 2024, 1:29am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/1 "2024-01-07T01:29:22Z")

</div>

```auto
C:\Users\Dani\jekyll-klise>bundle exec jekyll serve
jekyll 4.1.1 | Error: undefined method `[]' for nil
C:/Ruby33-x64/lib/ruby/3.3.0/logger.rb:384:in `level': undefined method `[]' for nil (NoMethodError)

    @level_override[Fiber.current] || @level
                   ^^^^^^^^^^^^^^^
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/lib/jekyll/log_adapter.rb:45:in `adjust_verbosity'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/lib/jekyll/configuration.rb:143:in `config_files'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/lib/jekyll.rb:118:in `configuration'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/lib/jekyll/command.rb:44:in `configuration_from_options'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/lib/jekyll/commands/serve.rb:83:in `block (2 levels) in init_with_program'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `block in execute'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `each'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `execute'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.4.0/lib/mercenary/program.rb:44:in `go'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.4.0/lib/mercenary.rb:21:in `program'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-4.1.1/exe/jekyll:15:in `<top (required)>'
        from C:/Ruby33-x64/bin/jekyll:25:in `load'
        from C:/Ruby33-x64/bin/jekyll:25:in `<main>'

C:\Users\Dani\jekyll-klise>

```

---

<div class="post-metadata">

**Author:** ![panchtatvam](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/panchtatvam/32/5512_2.png) [@panchtatvam](https://talk.jekyllrb.com/u/panchtatvam)\
**Post date:** [January 7, 2024, 5:24am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/2 "2024-01-07T05:24:01Z")

</div>

can you share the repo ?

---

<div class="post-metadata">

**Author:** ![hhniao](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/hhniao/32/5708_2.png) [@hhniao](https://talk.jekyllrb.com/u/hhniao)\
**Post date:** [January 8, 2024, 8:08am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/3 "2024-01-08T08:08:51Z")

</div>

> **[GitHub - rails/website](https://github.com/rails/website)**
>
> Contribute to rails/website development by creating an account on GitHub.

try to run this repo, show me some error.

```auto
jekyll 4.3.3
ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [x64-mingw-ucrt]
Bundler version 2.5.4
gem 3.5.3
window 10

D:\ruby\website>bundle exec jekyll serve -l
jekyll 3.9.3 | Error: undefined method `[]' for nil
C:/Ruby33-x64/lib/ruby/3.3.0/logger.rb:384:in `level': undefined method `[]' for nil (NoMethodError)

    @level_override[Fiber.current] || @level
                   ^^^^^^^^^^^^^^^
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll/log_adapter.rb:43:in `adjust_verbosity'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll/configuration.rb:157:in `config_files'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll.rb:113:in `configuration'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll/command.rb:43:in `configuration_from_options'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll/commands/serve.rb:89:in `start'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/lib/jekyll/commands/serve.rb:75:in `block (2 levels) in init_with_program'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `block in execute'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `each'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `execute'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.3.6/lib/mercenary/program.rb:42:in `go'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/mercenary-0.3.6/lib/mercenary.rb:19:in `program'
        from C:/Ruby33-x64/lib/ruby/gems/3.3.0/gems/jekyll-3.9.3/exe/jekyll:15:in `<top (required)>'
        from C:/Ruby33-x64/bin/jekyll:32:in `load'
        from C:/Ruby33-x64/bin/jekyll:32:in `<main>'

```

---

<div class="post-metadata">

**Author:** ![nchammas](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/nchammas/32/2076_2.png) [@nchammas](https://talk.jekyllrb.com/u/nchammas)\
**Post date:** [January 8, 2024, 2:54pm UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/4 "2024-01-08T14:54:46Z")

</div>

I hit a similar error and downgrading from Ruby 3.3.0 to Ruby 3.2.2 fixed the problem for me.

I’m running Jekyll 4.3.2.

If you can, upgrade to [Jekyll 4.3.3](https://github.com/jekyll/jekyll/releases/tag/v4.3.3) and try again with Ruby 3.3.0. The release notes suggest your problem should be fixed there.

---

<div class="post-metadata">

**Author:** ![razzius](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/razzius/32/5726_2.png) [@razzius](https://talk.jekyllrb.com/u/razzius)\
**Post date:** [January 18, 2024, 3:56am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/5 "2024-01-18T03:56:59Z")

</div>

I had this same issue and upgrading to Jekyll 4.3.3 fixed it. Thanks!

---

<div class="post-metadata">

**Author:** ![rnag](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rnag/32/5750_2.png) [@rnag](https://talk.jekyllrb.com/u/rnag)\
**Post date:** [January 28, 2024, 11:57pm UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/6 "2024-01-28T23:57:00Z")

</div>

I also had this issue, and after banging my head against a wall for _\>1 hour_, I realized that downgrading to Ruby 3.2.3 fixed it. But weirdly I had some issue when re-installing ruby with `brew`, and I ran in some strange errors in terminal when running `bundle`.

I decided to use `chruby` instead to manage ruby version, going ahead. I published a [post on medium](https://medium.com/@ritviknag/ruby-versioning-trouble-with-jekyll-github-pages-fd2748bf4e1d) that go into more detail, if anyone’s curious. This is what ended up working for me.

---

<div class="post-metadata">

**Author:** ![rdyar](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rdyar/32/710_2.png) [@rdyar](https://talk.jekyllrb.com/u/rdyar)\
**Post date:** [January 29, 2024, 5:07am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/7 "2024-01-29T05:07:45Z")

</div>

> [@rnag](#):
>
> Ruby 2.3.2

is that right?? I think you mean 3.3.2?

---

<div class="post-metadata">

**Author:** ![rnag](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rnag/32/5750_2.png) [@rnag](https://talk.jekyllrb.com/u/rnag)\
**Post date:** [January 29, 2024, 7:10am UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/8 "2024-01-29T07:10:17Z")

</div>

Crap yeah, good catch. I meant 3.2.3. Sometimes the numbers are very easy to confuse.

_Edit_: fixed it, thanks.

---

<div class="post-metadata">

**Author:** ![mindaslab](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/mindaslab/32/6054_2.png) [@mindaslab](https://talk.jekyllrb.com/u/mindaslab)\
**Post date:** [August 20, 2024, 2:00pm UTC](https://talk.jekyllrb.com/t/error-when-executing-bundle-install/8822/9 "2024-08-20T14:00:49Z")

</div>

Worked for me with Jekyll 4.3.3 and Ruby 3.3.3. 👍
