Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 550167
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T11:15:36+00:00 2026-05-13T11:15:36+00:00

I’m doing a little rails app for a prototype. I started off using a

  • 0

I’m doing a little rails app for a prototype. I started off using a starterapp called basejumper

After a quick start, I stumbled upon a very annoying problem. In development mode, rails crashes after the second request, i.e the first time I load a page, it works fine, a reload of the pages crashes with

"You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.include?"

The issue occurs when trying to access a user object through an belongs_to association. In a view, I do something like, it is the comment.user.login that crashes the view:

<% @article.comment_threads.each do |comment| %>
  <div class="comment">
     <%=h comment.body %> | Posted <%=time_ago_in_words(comment.created_at)%>ago
        by <%= comment.user.login %>.</div>
<% end%>

My classes:

class User < ActiveRecord::Base
  acts_as_authentic
  has_many :articles
  has_many :comments

class Comment < ActiveRecord::Base
  acts_as_nested_set :scope => [:commentable_id, :commentable_type] 
  belongs_to :user

class Article < ActiveRecord::Base
  belongs_to :user
  belongs_to :innovation_target
  acts_as_commentable

When in my development.rb config file, I put

config.cache_classes = false

the issue disappears, but leaves me with a server I need to restart after each change, which basically is not workable. I’m using rails 2.3.4.

So my question is, can I somehow force rails to reload some/all gems and plugins in development mode, so that this issue goes away? Or do you see other possibilities? I am using many different plugins and gems, including among others acts_as_commentable_with_threading, awesome_nested_set and others.

Thanks for your help.

ps. I did already have a look at articles like http://www.williambharding.com/blog/rails/automatically-reload-modules-on-change-in-rails/ and http://nhw.pl/wp/2009/01/07/reloading-your-plugin-in-development-mode but those don’t seem the trick (or I’m doing something wrong.)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T11:15:36+00:00Added an answer on May 13, 2026 at 11:15 am

    After much googling and examining the stack trace, I managed to fix this issue:
    In an article http://209.85.129.132/search?q=cache:82jRiVpdYGcJ:www.theirishpenguin.com/2009/01/22/bug-of-the-day-nilinclude-error-with-create_time_zone_conversion_attribute/+create_time_zone_conversion_attribute%3F&cd=1&hl=nl&ct=clnk&gl=be&client=firefox-a (have to use google cache, page is not loading for the moment), a similar issue is described. In the comments, user stef suggests to change in the configuration.rb file

    config.time_zone = ‘UTC’
    to:
    config.active_record.default_timezone = :utc
    

    There is actually a documented rails issue in lighthouse describing this: https://rails.lighthouseapp.com/projects/8994/tickets/1339-arbase-should-not-be-nuking-its-children-just-because-it-lost-interest

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 493k
  • Answers 493k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I think Grzenio's answer is correct, but I don't think… May 16, 2026 at 10:52 am
  • Editorial Team
    Editorial Team added an answer iostreams is designed to detect errors and enter an error… May 16, 2026 at 10:52 am
  • Editorial Team
    Editorial Team added an answer No, but private fields used by static method do. What… May 16, 2026 at 10:51 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I am currently running into a problem where an element is coming back from
I am trying to understand how to use SyndicationItem to display feed which is
Seemingly simple, but I cannot find anything relevant on the web. What is the
Does anyone know how can I replace this 2 symbol below from the string
this is what i have right now Drawing an RSS feed into the php,
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.