Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby

chris salvi
chris salvi
7,584 Points

Donwloaded ODOT files straight from site and bundled gems, still getting errors on secret yml (help much appreciated)

This has really frustrated me as I have not been able to complete the ODOT app on this site due to this error and I have tried implementing many solutions that seem to not work on my end. I have even resorted to using other educational sites to improve my Ruby knowledge because of this error, so any help would be appreciated 10 fold.

For references I just started the rails partials and helpers, and I dont have the time or stamina to start the entire course from scratch again.

Error: secret yml key does not exist :(

https://github.com/donsalvadori/ODOT

2 Answers

Maciej Czuchnowski
Maciej Czuchnowski
36,441 Points

This error occurs because the code you downloaded did not contain the config/secrets.yml (you will notice it is not tracked by git - it was added to .gitignore file).

So you need to do two things.

1) create the config/secrets.yml file. It should look like this inside:

https://github.com/mczuchnowski/odot/blob/master/config/secrets.yml

2) Run rake secret command twice and copy the results, one for development, one for testing (in place of my own keys). Don't modify the production section - it will get its own secret key when deployed on Heroku etc. Save the file.

Your tests that depend on secrets .yml should pass now.

chris salvi
chris salvi
7,584 Points

i give up I cant get this bloody program to run anymore :(

chris salvi
chris salvi
7,584 Points

thank you so much Maciej, and how are things in Poland?

I must say you are one of the most generous mods on this site, and I have been improving lots since I've taken a bit of a hiatus using this excellent resource, but as a new year emerges I am ready and motivated to take my skills to the next level. Onward and upward as they say!

Maciej Czuchnowski
Maciej Czuchnowski
36,441 Points

Chris,

Things in Poland are stable, thanks ;)

That is exactly the same thing I did at some point - after taking a few months' leave and exploring other resources, I came back to deal with projects I couldn't handle before and that's how my own Odot was created at some point. I know that there aren't many people responding to Ruby/Rails questions on this forum, so I'm doing my best to help to prevent people from resigning or rage-quitting Rails development ;).

chris salvi
chris salvi
7,584 Points

And are you currently working as RoR developer? I am desperate to try to break into the industry here in PDX, but find myself needing probably 6 more months to land a dev role. I've thought about using Treeleaf Academy to hasten my progress because currently this site is focused too much on basic ruby modules. No slight to them, but I need the extra push.

Any tips for me? I have read the michael hartl book on Rails, gone through the Pragmatic Studio classes, etc.