title: brew services start mongodb-community@4.0 fails - uninitialized constant
body: <p>I've followed the directions on the <a href="https://docs.mongodb.com/manual/tutorial/install-mongodb-on-os-x/" rel="noreferrer">MongoDB docs</a> to install MongoDB on Mac using homebrew:</p>
  
  <pre><code>brew tap mongodb/brew
  brew install mongodb-community@4.0
  </code></pre>
  
  <p>Then I can run it in the foreground using:</p>
  
  <pre><code>mongod --config /usr/local/etc/mongod.conf
  </code></pre>
  
  <p>But, when trying to start it as a service using:</p>
  
  <pre><code>brew services start mongodb-community@4.0
  </code></pre>
  
  <p>I get this error:</p>
  
  <pre><code>Error: mongodb-community: uninitialized constant #&lt;Class:0x00007ff189061008&gt;::Gem
  </code></pre>
  
  <p>I also get this error when running <code>brew doctor</code>:</p>
  
  <pre><code>Warning: Some installed formulae are not readable:
    mongodb-community: uninitialized constant #&lt;Class:0x00007ffd903152a0&gt;::Gem
  </code></pre>
  
  <p>Why this is happening? How do I fix it?</p>
  
  <p>Thank you!</p>