Thanks for tracking that down.  We need to either get the plugin to
work or to provide a reliable alternative...

On Jul 26, 2:06 am, storitel <[email protected]> wrote:
> not sure if it helps, but Adam the author of validates_timeliness has
> this to say
>
> From the stack trace it appears that the plugin parser is not being
> used.
> I think the plugin is not compatible with Hobo for some reason.
> My guess is that Hobo is overriding something in ActiveRecord and
> removing the plugin hooks which is preventing its proper operation.
>
> http://github.com/adzap/validates_timeliness/issues/issue/12/#issue/1...
>
> On Jul 26, 3:03 am, Matt Jones <[email protected]> wrote:
>
>
>
> > On Jul 23, 2010, at 6:20 PM, storitel wrote:
>
> > > I had been using the datepicker, but had to drop it because the format
> > > order wasn't always being picked up properly. once i get the agility/
> > > selenium setup running i will try to replicate that...
>
> > > meantime, i guess this *is* a bug? if it's a problem in rails/
> > > validates_timeliness, it's even more surprising...
>
> > Looks like we either need to borrow the Rails fallback code for this,  
> > or figure out how to get out the attribute parsing business entirely.  
> > Here's how Rails avoids the error:
>
> >                  begin
> >                    values = values_with_empty_parameters.collect do |
> > v| v.nil? ? 1 : v end
> >                    Date.new(*values)
> >                  rescue ArgumentError => ex # if Date.new raises an  
> > exception on an invalid date
> >                    instantiate_time_object(name, values).to_date # we  
> > instantiate Time object and convert it back to a date thus using  
> > Time's logic in handling invalid dates
> >                  end
>
> > I was kind of disappointed when I found this; I was hoping there was a  
> > slightly more glamorous solution than just swallowing the exception  
> > and punting. Apparently not. :)
>
> > Tom, Bryan - do either of you recall why we're manually parsing those  
> > attributes in convert_type_for_mass_assignment? Is it still needed in  
> > 2.3?
>
> > --Matt Jones

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en.

Reply via email to