This project is archived and is in readonly mode.
backtrace silencers are removing more lines than they really should
-
Ryan Bigg
I'm interested in seeing what the deal is with this ticket... could you post some information as to go about duplicating this issue?
-
José Valim
Hey Ryan,
I don't remember exactly, but try doing something invalid in your model, like:
class User < ActiveRecord::Base def explode nil.this_method_does_not_exist! end endAnd then in a controller:
class HomeController < ApplicationController def index User.new.explode end endThe last time, the backtrace cleaner was removing all lines, include controllers and models. So it was quite hard to track the issue. You will need Ruby 1.8.7.
-
Ryan Bigg
In the latest edge on 1.8.7 I get this error:
1) Error: test_should_get_index(UsersControllerTest): NoMethodError: undefined method `this_method_does_not_exist!' for nil:NilClass app/models/user.rb:3:in `explode' app/controllers/users_controller.rb:5:in `index'I think this is the correct stack, albeit missing the actual line of the test itself. I'm not a Test::Unit guy so I can't say for sure if that line should be there.
-
José Valim
Yeah, this is exactly the issue. It's missing the test lines (I just tried in Test::Unit and it does include test lines). You can also get the whole backtrace by uncommenting a line in config/initializers/backtrace_silencer.rb.
Thanks for looking into this. :)
-
Ryan Bigg
Here, have a patch.
-
José Valim
- State changed from new to open
- Assigned user set to José Valim
-
Repository
- State changed from open to resolved
(from [efa7e96821a3d335fab9cd9ed1dfa6c6cd6744a2]) It seems the test directory backtrace line is output with a / before it, thereby previously making it not match the regex. Support APP_DIRS that have backtrace lines maybe beginning with /. [#4277 backtrace silencers are removing more lines than they really should state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/efa7e96821a3d335fab9cd9ed1dfa6... -
José Valim
Thanks Ryan!
-
upsale
There is no better way to show your support than with a messi jersey or messi short.
-
herve leger sale
However, high level of consumption in the city was higher than other regions, she left up to a hundred dollars per month without buying nothing. At the same time, when she looked around many students who wore very fashionably in their school, she wanted to imitate them.
But she knew she had no money,herve leger sale, when she is troubled by this issue, one of her classmates suggested that she would apply for deferment to the school, saying that her family was poor and used the school fees firstly. And her friend firmly believed that she would certainly pay off before graduation by doing part-time job. Samuel thought it was a good idea. Then laughed herself that there is no thought of her own.
