Before, I was having trouble with my application because it generates a weird error that has something to do with the rails hash params. the controller is sometimes missing as well as the action. As far as I know this two are always present (Correct me if I'm wrong). So as to make the story short, I posted a question on a rails forum.

Now after three days of Google searching, it seems that this is the first time it ever happened. I tried to open the files that was stated on the log file and I found out one thing. Under the ActionController module on CGIRequests I found a strange line:

raw_post.force_encoding(Encoding::BINARY) if raw_post.respond_to?(:force_encoding)

If you will read the log, it says something about the Encoding constant missing. Also I found an article somewhere where this line is not present. I tried to comment out this line and as of now the app seems to work smoothly..

This can be found on vendor/rails/action/pack/lib/action_controller/cgi_process.rb around line 68 if you haven't change this part

I'm still not sure if this is the right solution for this, and what this line does on the application. This could be a cause of Version error.

For updates about this, I posted another issue on railsforum about this error I got.

No comments :

Post a Comment