[Ironruby-core] Issue with ActionMailer that appears to run deep

James Thompson james at plainprograms.com
Wed Oct 28 08:59:54 EDT 2009


I'm compiling from source.

Sent from my iPhone

On Oct 28, 2009, at 1:31 AM, Shri Borde <Shri.Borde at microsoft.com>  
wrote:

> It’s a simple bug in the utc implementation. Time.utc (http://www.ruby-doc.org/core/classes/Time.html#M0002 
> 52) gets passed in a number of arguments which are all ints except f 
> or the second one. The Time.utc implementation tries to convert all  
> to an int, and fails when it gets a string for the second argument.  
> The simple snippet below works with MRI but fails with IronRuby.
>
>
>
> Time.utc(2000,"jan",1,20,15,1)
>
>
>
> Are you able to build from source as described at http://wiki.github.com/ironruby/ironruby? 
>  If so, we can fix this and push the patch to github for you to pick  
> up?
>
>
>
> If not, you can workaround it by monkey-patching Time.utc with  
> something like this:
>
>
>
> class Time
>
>   class << self
>
>     @@months = ["jan", "feb", "mar", "apr", "may",
>
>        "jun", "jul", "aug", "sep", "oct", "nov", "dec"]
>
>     alias :old_utc :utc
>
>     def utc(*args)
>
>       if args.size >= 2
>
>         if args[1].kind_of? String
>
>           args[1] = @@months.index(args[1]) + 1
>
>         end
>
>       end
>
>       old_utc(*args)
>
>     end
>
>   end
>
> end
>
>
>
> From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core- 
> bounces at rubyforge.org] On Behalf Of James Thompson
> Sent: Tuesday, October 27, 2009 10:03 AM
> To: ironruby-core at rubyforge.org
> Subject: [Ironruby-core] Issue with ActionMailer that appears to run  
> deep
>
>
>
> I just posted an issue: http://ironruby.codeplex.com/WorkItem/View.aspx?WorkItemId=2946
>
> It looks like something is going odd between the UTC method defined  
> in TimeOps.cs and the RACC parser. Anyone who understands the  
> internals better than I want to take a look at the stack trace I  
> attached and tell me if I may be missing something?
>
> This is blocking my deployment of a Rails app because using  
> ActionMailer is giving me this.
>
>
> Thanks!
>
> James Thompson
> Plain Programs
> New Orleans, LA
>
> P: (502) 619.0353
> E: james at plainprograms.com
> W: www.plainprograms.com
>
> _______________________________________________
> Ironruby-core mailing list
> Ironruby-core at rubyforge.org
> http://rubyforge.org/mailman/listinfo/ironruby-core
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20091028/cfab1a10/attachment.html>


More information about the Ironruby-core mailing list