Saturday, April 27, 2013

And now, a bit MORE Heroku confusion!

   Yes, I wrote earlier on how to have a lack of confusion on Heroku.  But sometimes, things can still be a little confusing.  I recently decided to play with Ruby 2, Rails 4, and a new app idea, all at the same time, via Heroku, launching Pull Request Roulette.

   All went well in development mode, trying it out on my own box.  Likewise in test mode, where I was trying to follow fairly strict BDD and TDD.  In production mode, though, and only in production mode (where it was most embarrassing and troublesome, of course), the "Take" feature, whereby someone commits to review a Github "pull request", wasn't working.  It was acting like I was trying to view the record of the pull request, which (at this stage) consists only of the URL.  It's all the worse because there are only two basic features, Submit and Take.

   Production mode on my own machine... showed the same symptoms.  Aha!, I thought, at least it's not Heroku-specific.  Tracking down Heroku problems can be a pain, due to the layer of indirection.  The logs (more easily accessible on my own machine) pointed to an asset problem.  Heroku precompiles on upload (unless disabled of course), so that wasn't it.  What could it possibly be?

   I Googled a gaggle, and it didn't bring me much giggles, especially after spending enough hours to develop late-night-goggles.  Finally I stumbled across a post on StackOverflow that referenced Heroku's documentation about Getting Started with Rails 4.x on Heroku.  I could have sworn that I had read that, and followed all its advice when setting up Pull Request Roulette initially... but the referenced Heroku's instructions to include some gems that didn't sound familiar.

   Sure enough, when I opened up the Gemfile, they were nowhere to be seen.  Adding them fixed the problem.

   So now, if you want to have someone review a pull request you've put together for an open-source project on Github, someone can now commit to review it.  For now, though, you won't know who it was, and there will be no record.  Want to add that feature to the project?  Fork it and create a pull request... and you can submit that one to Pull Request Roulette.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.