Conversation
|
Nicely done! Everything works, looks great. 🎉 |
|
@jwo I updated this with tiger. I updated the Heroku site as well. |
theweb.rb
Outdated
There was a problem hiding this comment.
NICE!!!
Each time the page loads, it will need to pick up this file and interpret the yml file.
I'm going to push you a pick on this: Can you think of a way to have these picks be a Ruby class that dont' change?
…every time you visit the page
|
Hey @jperezish --- Check out these lines: https://github.com/jperezish/Episode8/blob/master/db/setup.rb#L10-L11 ActiveRecord::Base.connection.drop_database (connection_details.fetch('database')) rescue nil
ActiveRecord::Base.connection.create_database(connection_details.fetch('database')) rescue nilI bet you're having trouble dropping and creating the DB on heroku (because they don't allow those sorts of things). To try it out, we could remote the Assuming that's the case, what do you think your next move could be? (finally, this shows why rescue nil is evil) |
|
@jwo this is a tough one to sort out. I've been researching the whole topic around heroku and postgres and the best way to set to connect and seed a DB with Sinatra and Active Record. So I removed the So now I'll sort through this bit. |
|
COOL, ok, so your data isn't there -- the pages don't exist. If you do Rails will typically through a 404 here, but you'll need to handle that yourself in Sinatra. |
Here's my Panda level. App deployed to Heroku as well.