Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

jdwyah's latest activity

Friday, June 25 2010
4964 Validators bleeding from one model into another. was updated in Ruby on Rails
  • jdwyah
    jdwyah commented at 4:58 PM

    Looks like that did it! Rest of my gems aren't happy with edge so can't test the actual failure, but at least the objects aren't sharing validators.

    Yikes. That...

  • jdwyah
    jdwyah commented at 3:27 PM
    (rdb:1) p User._validators == MembershipRequest._validators
    true
    

    Seems like that's the root of the issue. I see that this uses the new class_attribute :_valid...

  • jdwyah
    jdwyah commented at 4:39 AM

    Neeraj, did you try two models, five validations each?

  • jdwyah
    jdwyah commented at 4:33 AM

    validates_presence_of :first_name, :last_name, :address1, :city, :state, :zip_code, :phone_number,

                                :if => Proc.new { |user| user.si...
  • jdwyah
    jdwyah created the ticket at 3:14 AM

    My User model has 11 validations.

    However:
    1) User.validators.count = 42
    2) User.validators.map{|v| v.instance_variable_get('@klass')}
    returns lots of classes t...

Thursday, May 07 2009
497 ActiveRecord#calculate broken for multiple fields in :group option was updated in Ruby on Rails
  • jdwyah
    jdwyah commented at 1:13 PM

    +1 In the meantime, see my ugly hack: poor_mans_group_by.rb http://pastie.org/471055 coalesce deals with nulls and delimitters are chosen to be unicode values u...

Wednesday, October 22 2008
1250 partial of collections with nil elements repeat previous value was created in Ruby on Rails
  • jdwyah
    jdwyah created the ticket at 7:12 PM

    Bumped into this when rendering a collection that had some nils in it.

    On 2.2 Edge

    tester.html.haml: = render :partial => 'test', :collection => [1,nil, 2,3,nil...

Thursday, June 12 2008
330 HTML::Document#initialize Node.parse call missing strict argument was updated in Ruby on Rails
  • jdwyah
    jdwyah commented at 6:51 PM

    +1. Google Website Optimizer script tags break my assert_select calls without this.

Thursday, May 08 2008
140 Chars class doesn't proxy "include?" was updated in Ruby on Rails
  • jdwyah
    jdwyah commented at 1:44 AM

    Yep, I agree that this is the problem. What do you think, is it appropriate to just add an include? method to Chars (or UTF8Handler)? or is there a cleaner fix...

Wednesday, May 07 2008
140 Chars class doesn't proxy "include?" was created in Ruby on Rails
  • jdwyah
    jdwyah created the ticket at 11:17 PM

    The docs state that "Chars objects are perfectly interchangeable with String objects as long as no explicit class checks are made."

    However at least one Strin...