laserlemon / figaro

Simple Rails app configuration
MIT License
3.76k stars 288 forks source link

Version 1.1.1 did not work for me #241

Open Hasna1 opened 8 years ago

Hasna1 commented 8 years ago

Hey Guys!

I encountered with an issue today with figaro. I have config/application.yml like

development:
  user_name: bloggingwebsite
  password: 'mypassword'

and in Gemfile I had

group :development, :test do
  # Call 'byebug' anywhere in the code to stop execution and get a debugger console
  gem 'byebug'
  gem 'figaro'
end

Then it installed the version 1.1.1. When I tried to access the ENV['user_name'] it returned nil.

To fix this I had to fix my version to 1.0.0 explicitly. Now its fixed..

So could you please find out what the problem is?

Thanks!

laserlemon commented 8 years ago

Are you using Spring? If so, restart Spring and let me know if that works.

tomj commented 7 years ago

Thoughts on me adding this to README.md in a PR? May be helpful for less Rails like peeps like me when they're wondering why the ENV vars are stale on their tests.

Cheers! 😄

thbar commented 7 years ago

Just logging this in case it helps someone else: it's not working either for me today, in a pure ruby app, using latest release (1.1.1). I tried using the v2 branch but go other problems which I hadn't got the time to investigate.