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 trialAllison Walker
17,137 Pointsundefined local variable or method `singleton_class' for Liquid:Module (NameError)
My previous version of jekyll was version 0.11.0. So, I attempted to upgrade. Now when I check the version, I get this error:
undefined local variable or method `singleton_class' for Liquid:Module (NameError)
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:55:in `gem_original_require'
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:55:in `require'
from /Library/Ruby/Gems/1.8/gems/jekyll-0.11.0/bin/../lib/jekyll.rb:25
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:55:in `gem_original_require'
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:55:in `require'
from /Library/Ruby/Gems/1.8/gems/jekyll-0.11.0/bin/jekyll:20
from /usr/bin/jekyll:19:in `load'
from /usr/bin/jekyll:19
1 Answer
Allison Walker
17,137 PointsI ended up finding the answer to this on Stack Exchange, and I just wanted to share my experience installing Jekyll. Actually, I'd already installed it a few years ago, but it was out of date and I couldn't update the version. The thing to keep in mind is that you need to make sure your system meets the requirements prior to installation. You can visit the Jekyll install site to view them, but they include Ruby, Ruby Gems, Node.js, and Python.
To install Node, I had to uninstall MacPorts and install Homebrew and npm. I also had to install gcc at somepoint before finishing this step. Homebrew was really helpful with the other installs but it all took a really long time. Like a day or two. Installing Python was easier after that, but I'm still a little confused. RubyGems was an easy install/update. To install Ruby, you should install RVM. That will help you with Ruby, but there will likely be some 'profile' issues you will need to deal with using nano.
All in all installing Jekyll took me down this monster rabbit hole. Now my system is up to date, but in case you're having trouble, just know that there's an answer out there.