Hi, I ran into a pretty weird issue, I tried to use some of the .NET ORM''s with IronRuby. I haven''t investigated with the debugger turned on yet but here''s what I observed I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. Linq2Sql doesn''t have a problem. What the first 3 ORM''s have in common is that I can use the types in the actual ORM library. All of those ORM''s require you to have a generic base class. If I include other types in the assembly (non generic base classes) then I can just use those classes. When I create a type with a generic base class that is defined in the same assembly I can use that class in IronRuby For SubSonic a Customer class could look like: *public class Customer : ActiveRecord<Customer>{ // model code here }* The output from the console session that shows the behavior. I tried a lot of different approaches but it always boils down to the same error. *IronRuby 0.1 on .NET 2.0.50727.1434 Copyright (c) Microsoft Corporation. All rights reserved. Note that local variables do not work today in the console. As a workaround, use globals instead (eg $x = 42 instead of x = 42).>>> require ''mscorlib''=> true>>> require Dir.getwd + ''/SubSonic.dll''=> true>>> require Dir.getwd + ''/DataAccess.SubSonic.dll''=> true>>> include DataAccess::SubSonic=> Object>>> Customer.newIronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant Object::Customer (NameError) from :0:in `main'' from :0:in `##16''>>> exit*Is this a bug or is it a case of me missing something? Cheers Ivan -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/ironruby-core/attachments/20080219/1efe70ca/attachment.html
Where is the assembly that contains Customer? Is that " DataAccess.SubSonic.dll"? BTW: ActiveRecord (from Castle) does not require you to inherit ActiveRecordBase. You can just mark up your classes with attributes and use ActiveRecordMediator for all the CRUD. -Eric On Feb 18, 2008 3:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote:> Hi, > > I ran into a pretty weird issue, I tried to use some of the .NET ORM''s > with IronRuby. > I haven''t investigated with the debugger turned on yet but here''s what I > observed > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > Linq2Sql doesn''t have a problem. > > What the first 3 ORM''s have in common is that I can use the types in the > actual ORM library. All of those ORM''s require you to have a generic base > class. > If I include other types in the assembly (non generic base classes) then I > can just use those classes. > When I create a type with a generic base class that is defined in the same > assembly I can use that class in IronRuby > > For SubSonic a Customer class could look like: > > *public class Customer : ActiveRecord<Customer>{ > // model code here > }* > > The output from the console session that shows the behavior. I tried a lot > of different approaches but it always boils down to the same error. > > *IronRuby 0.1 on .NET 2.0.50727.1434 > Copyright (c) Microsoft Corporation. All rights reserved. > > Note that local variables do not work today in the console. > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > >>> require ''mscorlib'' > => true > >>> require Dir.getwd + ''/SubSonic.dll'' > => true > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > => true > >>> include DataAccess::SubSonic > => Object > >>> Customer.new > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > Object::Customer (NameError) > from :0:in `main'' > from :0:in `##16'' > >>> exit* > > Is this a bug or is it a case of me missing something? > > Cheers > Ivan > > _______________________________________________ > 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/20080218/d6fd779d/attachment-0001.html
So, the Customer class was generated by SubSonic and is contained in DataAccess.Subsonic.dll? Do you get the same results by leaving out the include and saying DataAccess::SubSonic::Customer.new instead? On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote:> Hi, > > I ran into a pretty weird issue, I tried to use some of the .NET ORM''s > with IronRuby. > I haven''t investigated with the debugger turned on yet but here''s what I > observed > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > Linq2Sql doesn''t have a problem. > > What the first 3 ORM''s have in common is that I can use the types in the > actual ORM library. All of those ORM''s require you to have a generic base > class. > If I include other types in the assembly (non generic base classes) then I > can just use those classes. > When I create a type with a generic base class that is defined in the same > assembly I can use that class in IronRuby > > For SubSonic a Customer class could look like: > > *public class Customer : ActiveRecord<Customer>{ > // model code here > }* > > The output from the console session that shows the behavior. I tried a lot > of different approaches but it always boils down to the same error. > > *IronRuby 0.1 on .NET 2.0.50727.1434 > Copyright (c) Microsoft Corporation. All rights reserved. > > Note that local variables do not work today in the console. > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > >>> require ''mscorlib'' > => true > >>> require Dir.getwd + ''/SubSonic.dll'' > => true > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > => true > >>> include DataAccess::SubSonic > => Object > >>> Customer.new > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > Object::Customer (NameError) > from :0:in `main'' > from :0:in `##16'' > >>> exit* > > Is this a bug or is it a case of me missing something? > > Cheers > Ivan > > _______________________________________________ > 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/20080218/50ea5dc5/attachment.html
Yep On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote:> So, the Customer class was generated by SubSonic and is contained in > DataAccess.Subsonic.dll? Do you get the same results by leaving out the > include and saying > > DataAccess::SubSonic::Customer.new > > instead? > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote: > > > Hi, > > > > I ran into a pretty weird issue, I tried to use some of the .NET ORM''s > > with IronRuby. > > I haven''t investigated with the debugger turned on yet but here''s what I > > observed > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > Linq2Sql doesn''t have a problem. > > > > What the first 3 ORM''s have in common is that I can use the types in the > > actual ORM library. All of those ORM''s require you to have a generic base > > class. > > If I include other types in the assembly (non generic base classes) then > > I can just use those classes. > > When I create a type with a generic base class that is defined in the > > same assembly I can use that class in IronRuby > > > > For SubSonic a Customer class could look like: > > > > *public class Customer : ActiveRecord<Customer>{ > > // model code here > > }* > > > > The output from the console session that shows the behavior. I tried a > > lot of different approaches but it always boils down to the same error. > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > Note that local variables do not work today in the console. > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > >>> require ''mscorlib'' > > => true > > >>> require Dir.getwd + ''/SubSonic.dll'' > > => true > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > => true > > >>> include DataAccess::SubSonic > > => Object > > >>> Customer.new > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > Object::Customer (NameError) > > from :0:in `main'' > > from :0:in `##16'' > > >>> exit* > > > > Is this a bug or is it a case of me missing something? > > > > Cheers > > Ivan > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080219/3a488d33/attachment.html
Yep the same thing happens, and i can elaborate on that If it''s an assembly which only contains ie. ActiveRecord types then i can''t even execute include DataAccess::SubSonic I tried many variations on the theme. Tried with signed assemblies vs unsigned ones, tried different syntax structures, tried it in the console and in a file. On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote:> So, the Customer class was generated by SubSonic and is contained in > DataAccess.Subsonic.dll? Do you get the same results by leaving out the > include and saying > > DataAccess::SubSonic::Customer.new > > instead? > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote: > > > Hi, > > > > I ran into a pretty weird issue, I tried to use some of the .NET ORM''s > > with IronRuby. > > I haven''t investigated with the debugger turned on yet but here''s what I > > observed > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > Linq2Sql doesn''t have a problem. > > > > What the first 3 ORM''s have in common is that I can use the types in the > > actual ORM library. All of those ORM''s require you to have a generic base > > class. > > If I include other types in the assembly (non generic base classes) then > > I can just use those classes. > > When I create a type with a generic base class that is defined in the > > same assembly I can use that class in IronRuby > > > > For SubSonic a Customer class could look like: > > > > *public class Customer : ActiveRecord<Customer>{ > > // model code here > > }* > > > > The output from the console session that shows the behavior. I tried a > > lot of different approaches but it always boils down to the same error. > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > Note that local variables do not work today in the console. > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > >>> require ''mscorlib'' > > => true > > >>> require Dir.getwd + ''/SubSonic.dll'' > > => true > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > => true > > >>> include DataAccess::SubSonic > > => Object > > >>> Customer.new > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > Object::Customer (NameError) > > from :0:in `main'' > > from :0:in `##16'' > > >>> exit* > > > > Is this a bug or is it a case of me missing something? > > > > Cheers > > Ivan > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080219/c7156a7d/attachment-0001.html
I got basically the same result when trying to use a SubSonic-generated DLL from IronPython. The Assembly.GetTypes function wasn''t able to resolve the generated classes because "Could not load file or assembly ''SubSonic, Version=2.0.3.0, Culture=neutral, PublicKeyToken=eadb47849839a332'' or one of its dependencies" The problem went away when I copied the SubSonic DLLs into the same directory as the executable. On Feb 18, 2008 6:19 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote:> Yep > > > On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote: > > > So, the Customer class was generated by SubSonic and is contained in > > DataAccess.Subsonic.dll? Do you get the same results by leaving out the > > include and saying > > > > DataAccess::SubSonic::Customer.new > > > > instead? > > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> > > wrote: > > > > > Hi, > > > > > > I ran into a pretty weird issue, I tried to use some of the .NET ORM''s > > > with IronRuby. > > > I haven''t investigated with the debugger turned on yet but here''s what > > > I observed > > > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > > Linq2Sql doesn''t have a problem. > > > > > > What the first 3 ORM''s have in common is that I can use the types in > > > the actual ORM library. All of those ORM''s require you to have a generic > > > base class. > > > If I include other types in the assembly (non generic base classes) > > > then I can just use those classes. > > > When I create a type with a generic base class that is defined in the > > > same assembly I can use that class in IronRuby > > > > > > For SubSonic a Customer class could look like: > > > > > > *public class Customer : ActiveRecord<Customer>{ > > > // model code here > > > }* > > > > > > The output from the console session that shows the behavior. I tried a > > > lot of different approaches but it always boils down to the same error. > > > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > > > Note that local variables do not work today in the console. > > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > > > >>> require ''mscorlib'' > > > => true > > > >>> require Dir.getwd + ''/SubSonic.dll'' > > > => true > > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > > => true > > > >>> include DataAccess::SubSonic > > > => Object > > > >>> Customer.new > > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > > Object::Customer (NameError) > > > from :0:in `main'' > > > from :0:in `##16'' > > > >>> exit* > > > > > > Is this a bug or is it a case of me missing something? > > > > > > Cheers > > > Ivan > > > > > > _______________________________________________ > > > Ironruby-core mailing list > > > Ironruby-core at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080218/e1288b23/attachment.html
ah k I''ll try that thanks On Feb 19, 2008 4:34 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote:> I got basically the same result when trying to use a SubSonic-generated > DLL from IronPython. The Assembly.GetTypes function wasn''t able to > resolve the generated classes because "Could not load file or assembly > ''SubSonic, Version=2.0.3.0, Culture=neutral, > PublicKeyToken=eadb47849839a332'' or one of its dependencies" > The problem went away when I copied the SubSonic DLLs into the same > directory as the executable. > On Feb 18, 2008 6:19 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote: > > > Yep > > > > > > On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote: > > > > > So, the Customer class was generated by SubSonic and is contained in > > > DataAccess.Subsonic.dll? Do you get the same results by leaving out > > > the include and saying > > > > > > DataAccess::SubSonic::Customer.new > > > > > > instead? > > > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> > > > wrote: > > > > > > > Hi, > > > > > > > > I ran into a pretty weird issue, I tried to use some of the .NET > > > > ORM''s with IronRuby. > > > > I haven''t investigated with the debugger turned on yet but here''s > > > > what I observed > > > > > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > > > Linq2Sql doesn''t have a problem. > > > > > > > > What the first 3 ORM''s have in common is that I can use the types in > > > > the actual ORM library. All of those ORM''s require you to have a generic > > > > base class. > > > > If I include other types in the assembly (non generic base classes) > > > > then I can just use those classes. > > > > When I create a type with a generic base class that is defined in > > > > the same assembly I can use that class in IronRuby > > > > > > > > For SubSonic a Customer class could look like: > > > > > > > > *public class Customer : ActiveRecord<Customer>{ > > > > // model code here > > > > }* > > > > > > > > The output from the console session that shows the behavior. I tried > > > > a lot of different approaches but it always boils down to the same error. > > > > > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > > > > > Note that local variables do not work today in the console. > > > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > > > > > >>> require ''mscorlib'' > > > > => true > > > > >>> require Dir.getwd + ''/SubSonic.dll'' > > > > => true > > > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > > > => true > > > > >>> include DataAccess::SubSonic > > > > => Object > > > > >>> Customer.new > > > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > > > Object::Customer (NameError) > > > > from :0:in `main'' > > > > from :0:in `##16'' > > > > >>> exit* > > > > > > > > Is this a bug or is it a case of me missing something? > > > > > > > > Cheers > > > > Ivan > > > > > > > > _______________________________________________ > > > > Ironruby-core mailing list > > > > Ironruby-core at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > > > > > _______________________________________________ > > > Ironruby-core mailing list > > > Ironruby-core at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080219/e9050b8d/attachment.html
Thanks a lot that works :) On Feb 19, 2008 4:34 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote:> I got basically the same result when trying to use a SubSonic-generated > DLL from IronPython. The Assembly.GetTypes function wasn''t able to > resolve the generated classes because "Could not load file or assembly > ''SubSonic, Version=2.0.3.0, Culture=neutral, > PublicKeyToken=eadb47849839a332'' or one of its dependencies" > The problem went away when I copied the SubSonic DLLs into the same > directory as the executable. > On Feb 18, 2008 6:19 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote: > > > Yep > > > > > > On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote: > > > > > So, the Customer class was generated by SubSonic and is contained in > > > DataAccess.Subsonic.dll? Do you get the same results by leaving out > > > the include and saying > > > > > > DataAccess::SubSonic::Customer.new > > > > > > instead? > > > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> > > > wrote: > > > > > > > Hi, > > > > > > > > I ran into a pretty weird issue, I tried to use some of the .NET > > > > ORM''s with IronRuby. > > > > I haven''t investigated with the debugger turned on yet but here''s > > > > what I observed > > > > > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > > > Linq2Sql doesn''t have a problem. > > > > > > > > What the first 3 ORM''s have in common is that I can use the types in > > > > the actual ORM library. All of those ORM''s require you to have a generic > > > > base class. > > > > If I include other types in the assembly (non generic base classes) > > > > then I can just use those classes. > > > > When I create a type with a generic base class that is defined in > > > > the same assembly I can use that class in IronRuby > > > > > > > > For SubSonic a Customer class could look like: > > > > > > > > *public class Customer : ActiveRecord<Customer>{ > > > > // model code here > > > > }* > > > > > > > > The output from the console session that shows the behavior. I tried > > > > a lot of different approaches but it always boils down to the same error. > > > > > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > > > > > Note that local variables do not work today in the console. > > > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > > > > > >>> require ''mscorlib'' > > > > => true > > > > >>> require Dir.getwd + ''/SubSonic.dll'' > > > > => true > > > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > > > => true > > > > >>> include DataAccess::SubSonic > > > > => Object > > > > >>> Customer.new > > > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > > > Object::Customer (NameError) > > > > from :0:in `main'' > > > > from :0:in `##16'' > > > > >>> exit* > > > > > > > > Is this a bug or is it a case of me missing something? > > > > > > > > Cheers > > > > Ivan > > > > > > > > _______________________________________________ > > > > Ironruby-core mailing list > > > > Ironruby-core at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > > > > > _______________________________________________ > > > Ironruby-core mailing list > > > Ironruby-core at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080219/e1c209c7/attachment-0001.html
You also have to create an rbx.config file otherwise it doesn''t know how to find the config file. On Feb 19, 2008 4:34 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote:> I got basically the same result when trying to use a SubSonic-generated > DLL from IronPython. The Assembly.GetTypes function wasn''t able to > resolve the generated classes because "Could not load file or assembly > ''SubSonic, Version=2.0.3.0, Culture=neutral, > PublicKeyToken=eadb47849839a332'' or one of its dependencies" > The problem went away when I copied the SubSonic DLLs into the same > directory as the executable. > On Feb 18, 2008 6:19 PM, Ivan Porto Carrero <ivan at flanders.co.nz> wrote: > > > Yep > > > > > > On Feb 19, 2008 1:37 PM, Curt Hagenlocher <curt at hagenlocher.org> wrote: > > > > > So, the Customer class was generated by SubSonic and is contained in > > > DataAccess.Subsonic.dll? Do you get the same results by leaving out > > > the include and saying > > > > > > DataAccess::SubSonic::Customer.new > > > > > > instead? > > > On Feb 18, 2008 12:30 PM, Ivan Porto Carrero <ivan at flanders.co.nz> > > > wrote: > > > > > > > Hi, > > > > > > > > I ran into a pretty weird issue, I tried to use some of the .NET > > > > ORM''s with IronRuby. > > > > I haven''t investigated with the debugger turned on yet but here''s > > > > what I observed > > > > > > > > I tried this with ActiveRecord from Castle, SubSonic and LightSpeed. > > > > Linq2Sql doesn''t have a problem. > > > > > > > > What the first 3 ORM''s have in common is that I can use the types in > > > > the actual ORM library. All of those ORM''s require you to have a generic > > > > base class. > > > > If I include other types in the assembly (non generic base classes) > > > > then I can just use those classes. > > > > When I create a type with a generic base class that is defined in > > > > the same assembly I can use that class in IronRuby > > > > > > > > For SubSonic a Customer class could look like: > > > > > > > > *public class Customer : ActiveRecord<Customer>{ > > > > // model code here > > > > }* > > > > > > > > The output from the console session that shows the behavior. I tried > > > > a lot of different approaches but it always boils down to the same error. > > > > > > > > *IronRuby 0.1 on .NET 2.0.50727.1434 > > > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > > > > > Note that local variables do not work today in the console. > > > > As a workaround, use globals instead (eg $x = 42 instead of x = 42). > > > > > > > > >>> require ''mscorlib'' > > > > => true > > > > >>> require Dir.getwd + ''/SubSonic.dll'' > > > > => true > > > > >>> require Dir.getwd + ''/DataAccess.SubSonic.dll'' > > > > => true > > > > >>> include DataAccess::SubSonic > > > > => Object > > > > >>> Customer.new > > > > IronRuby.Libraries:0:in `ConstantMissing'': uninitialized constant > > > > Object::Customer (NameError) > > > > from :0:in `main'' > > > > from :0:in `##16'' > > > > >>> exit* > > > > > > > > Is this a bug or is it a case of me missing something? > > > > > > > > Cheers > > > > Ivan > > > > > > > > _______________________________________________ > > > > Ironruby-core mailing list > > > > Ironruby-core at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > > > > > _______________________________________________ > > > Ironruby-core mailing list > > > Ironruby-core at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > > > > > _______________________________________________ > > Ironruby-core mailing list > > Ironruby-core at rubyforge.org > > http://rubyforge.org/mailman/listinfo/ironruby-core > > > > > > _______________________________________________ > 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/20080219/483d31fe/attachment.html