Brew install fails on Build-agent version 0.1.1301-dd8e9365 (2019-01-09T17:12:43+0000)

I have a brew install carthage step that worked as of Build-agent version 0.1.1250-22bf9f5d (2018-12-12T11:32:15+0000), but no longer does under Build-agent version 0.1.1301-dd8e9365 (2019-01-09T17:12:43+0000)

Error being:
/usr/local/Homebrew/Library/Homebrew/config.rb:39:in initialize': no implicit conversion of nil into String (TypeError) from /usr/local/Homebrew/Library/Homebrew/config.rb:39:innew’
from /usr/local/Homebrew/Library/Homebrew/config.rb:39:in <top (required)>' from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:inrequire’
from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in require' from /usr/local/Homebrew/Library/Homebrew/global.rb:25:in<top (required)>’
from /usr/local/Homebrew/Library/Homebrew/brew.rb:13:in require_relative' from /usr/local/Homebrew/Library/Homebrew/brew.rb:13:in
Exited with code 1

1 Like

Same here, started happening today, I guess it’s related to Homebrew update (1.9.0).

^D^DUpdating Homebrew...
To restore the stashed changes to /usr/local/Homebrew run:
  'cd /usr/local/Homebrew && git stash pop'
To restore the stashed changes to /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask run:
  'cd /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask && git stash pop'
To restore the stashed changes to /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask-versions run:
  'cd /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask-versions && git stash pop'
To restore the stashed changes to /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core run:
  'cd /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core && git stash pop'
==> Auto-updated Homebrew!
Updated 3 taps (homebrew/cask, homebrew/cask-versions and homebrew/core).
==> Updated Formulae
yarn ✔              chakra              fonttools           sox
alexjs              conan               kitchen-sync        telegraf
amqp-cpp            console_bridge      libphonenumber      urdfdom_headers
aws-sdk-cpp         emscripten          lmod                wtf
bat                 erlang@20           neofetch
brew-php-switcher   exploitdb           nvm

/usr/local/Homebrew/Library/Homebrew/config.rb:39:in `initialize': no implicit conversion of nil into String (TypeError)
	from /usr/local/Homebrew/Library/Homebrew/config.rb:39:in `new'
	from /usr/local/Homebrew/Library/Homebrew/config.rb:39:in `<top (required)>'
	from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /usr/local/Homebrew/Library/Homebrew/global.rb:25:in `<top (required)>'
	from /usr/local/Homebrew/Library/Homebrew/brew.rb:13:in `require_relative'
	from /usr/local/Homebrew/Library/Homebrew/brew.rb:13:in `<main>'
Exited with code 1```

This looks to be related to auto-updates performed by brew install prior to running. Versions of brew on the macOS images may be older and run into issues during auto updates. You can resolve this issue by running brew update prior to your brew install or prevent auto-updates with HOMEBREW_NO_AUTO_UPDATE=1 brew install package-name.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.