berkesokhan / rubydotnetcompiler

Automatically exported from code.google.com/p/rubydotnetcompiler
1 stars 0 forks source link

Unhandled exception in test.rb on Mac OS X (Mono) #45

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When running test.rb, I get a lot of OK's (and a few not OK's that I'm looking 
into), but I also get 
an unhandled exception:

<tt>
ok 37
ok 38
ok 39
system

Unhandled Exception: Ruby.Runtime.RubyException: echo foobar
  at Ruby.Methods.rb_f_backquote.Call1 (Ruby.Class last_class, System.Object recv, 
Ruby.Runtime.Frame caller, Ruby.Proc block, System.Object comArgs) [0x00000] 
  at Ruby.Runtime.Eval.CallPrivate1 (System.Object recv, Ruby.Runtime.Frame caller, 
System.String methodId, Ruby.Proc block, System.Object arg1) [0x00000] 
  at _Internal.SourceFile_test.Load (System.Object recv, Ruby.Runtime.Frame caller) [0x00000] 
  at <Module>.Main (System.String[] args) [0x00000] 
  at <0x00000> <unknown method>
  at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (object,object[])
  at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, 
System.Reflection.Binder binder, System.Object[] parameters, 
System.Globalization.CultureInfo 
culture) [0x00000]
</tt>

Original issue reported on code.google.com by jeremymc...@gmail.com on 13 Oct 2007 at 3:23

GoogleCodeExporter commented 9 years ago
For now it should work if you use the full path to the file (e.g. /bin/echo).

Currently Ruby.NET treats Windows shell commands (e.g. echo) in a special way 
because
they are not real executables; this will need to change in other platforms (a 
way to
detect Windows can be seen in [1]).

[1] http://jira.codehaus.org/browse/BOO-679

Original comment by sason...@gmail.com on 13 Oct 2007 at 7:07

GoogleCodeExporter commented 9 years ago
Note: since Ruby.NET doesn't support .NET 1.x, one can use PlatformID.Unix 
directly
instead of numeric comparison.

Original comment by sanxiyn on 14 Oct 2007 at 1:11

GoogleCodeExporter commented 9 years ago
Should be fixed now.

Original comment by sason...@gmail.com on 14 Oct 2007 at 11:47