Really weird issues happening randomly #3945

Closed
jerefrer opened this Issue Dec 12, 2011 · 12 comments

Projects

None yet

4 participants

@jerefrer

It's been a while now that I sometimes get really weird errors when starting my local server (does not depend on the server, tried WEBRick and Unicorn).

I explained everything in details in this StackOverflow post

In essence I get undefined method randomly on objects, but only after server startup.
Sometimes I can trick around by lauching a pry or a debugger just before the buggy line, call manually the failing method and notice that it's working (...), then exit the debugger and see everything is working just fine.
Sometimes I can't get around the error (as I am now) and nothing seems to do the trick.

I've been working with Rails for a while now and I never encountered such issue so I hope someone would find a solution ...

The project is Rails 3.1 with 1.8.7 on RVM.

A huge kiss to my future hero ;)

@baroquebobcat

do you only get this running in development? Or does it happen in test and production as well?

@jerefrer
This seems to be only happening in my local environment.
I never encountered such an issue after deploying to production nor when running specs.

As told in the linked post ;)

@drogus
Ruby on Rails member

@jerefrer can you try extracting it to a simple app so you can check if you see that this behavior is reproducible?

@arunagw
Ruby on Rails member

@jerefrer have you got any thing working here? Can we close this issue?

@jerefrer

Mmmmh actually the issue is still there even after upgrading to Rails 3.2.

But there was more since my last reply. I realized this is obviously a file loading order issue since I don't really have to do any pry/debugger thing but just modify the file (add a empty space for example) and save it, then reload the page and the error is gone.

I don't have much time now to track down the error and isolate it, maybe next month. I don't know if you may close the issue or not since I don't know if it is really Rails related or just my code that is messy in some way.

Maybe you have some starting point for me to look at ?

Cheers !

@arunagw
Ruby on Rails member

@jerefrer how about posting a sample app ?

@jerefrer

@arunagw That would just be what I meant by "tracking down the error and isolate it" and truly I can't afford the time to do that right now I'm sorry. But I definitly have to solve this so I will do it I think next month and let you know.

@arunagw
Ruby on Rails member

@jerefrer ok thanks!

@arunagw
Ruby on Rails member

@jerefrer did you get some time to track this issue more??

@jerefrer

Haha c'mon it's not a month yet :)
Our product launch will be at the beginning of April and I plan to do just that after the launch and the early feedbacks/tweaks.

@arunagw
Ruby on Rails member

@jerefrer how about now?

@arunagw
Ruby on Rails member

Closing this for now. I will keep track on this. Please reopen this when you got something :-)

Cheers,
Arun

@arunagw arunagw closed this May 17, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment