[IronPython] clarification on current state of embedding

Michael Foord fuzzyman at voidspace.org.uk
Thu Jun 18 21:59:51 CEST 2009


Justin Regele wrote:
> This makes sense, although I am still confused as to why problems keep 
> creeping up to me. I am on Vista, though, and so I think my problem is 
> that while I installed 2.0, I cannot instal SP1. The server my code 
> will run on is still on 2.0 until the new system is rolled out, which 
> may be 6 months from now.
>
> I built all my IPy libs for 2.0, but when I added a C# project to wrap 
> the embedded program and targetted 2.0 all the assemblies say they 
> require 3.5. If I add them anyway, the Microsoft scripting assemblies 
> can't be found. No such errors or warning about the IronPython 
> assemblies, although I'm back to 'Python does not exist in the current 
> context', even though I've got the assemblies loaded and using 
> IronPython.Hosting.
>
> After trudging through this weirdness for a bit now, I'm realizing 
> that the issue most likely comes from running a x64 version of Vista, 
> while IronPython is in the x86 program files.

IronPython is pure .NET code. It is independent of 32/64 bitness.

It may be that to get .NET 2 SP1 on vista you actually need to install 
.NET 3.5? Seems odd though.

Michael

>
> I'm going to bulid IronPython from source for 2.0 and see if that 
> fixes the problem.
>
>
> On Thu, Jun 18, 2009 at 7:00 AM, Lepisto, Stephen P 
> <stephen.p.lepisto at intel.com <mailto:stephen.p.lepisto at intel.com>> wrote:
>
>     >From MSDN (http://msdn.microsoft.com/en-us/library/bb383796.aspx):
>
>     "Differences Between .NET Framework Versions
>     All three versions of the .NET Framework are based on version 2.0
>     of the CLR. The versions of the .NET Framework differ from each
>     other in the list of assemblies that each makes available for you
>     to reference in your projects. For example, LINQ is a new
>     technology that is included in Visual Studio 2008. .NET Framework
>     3.5 is the only version of the .NET Framework that has
>     LINQ-related assemblies. Therefore, you cannot use LINQ unless
>     your project specifically targets .NET Framework 3.5. Similarly,
>     Windows Presentation Foundation (WPF) is included in Windows
>     Vista. You cannot build WPF applications unless your project
>     targets .NET Framework 3.0 and later versions of the .NET Framework."
>
>     In addition, .Net 3.0 changed the compiler to add support for
>     lambdas in C#, although the resulting code can still run on .Net
>     2.0 runtime.  The lambdas are converted to anonymous functions by
>     the compiler.  There may be other "syntactic sugar" changes as well.
>
>     In Visual Studio, when you select the target runtime, you are
>     primarily telling Visual Studio (and the underlying .Net compiler
>     tools) to filter out elements from later versions of .Net.  Of
>     course, if you include a reference to a .Net 3.5 assembly, you
>     have to make sure .Net 3.5 is installed on the target system.
>
>
>     -----Original Message-----
>     From: users-bounces at lists.ironpython.com
>     <mailto:users-bounces at lists.ironpython.com>
>     [mailto:users-bounces at lists.ironpython.com
>     <mailto:users-bounces at lists.ironpython.com>] On Behalf Of Michael
>     Foord
>     Sent: Thursday, June 18, 2009 4:49 AM
>     To: Discussion of IronPython
>     Subject: Re: [IronPython] clarification on current state of embedding
>
>     Justin Regele wrote:
>     > This brings up another question I've encountered. My
>     understanding was
>     > that IPy had problems with 3.5, and so I have been targeting
>     2.0. But
>     > when I try to reference the IronPython and Microsoft.Scripting
>     > assemblies, Visual Studio says I need 3.5
>
>
>     I've created many projects in Visual Studio referencing IronPython
>     assemblies and targeting .NET 2.0. Which means I don't know what is
>     wrong, but it *should* work fine... :-)
>
>     Michael Foord
>     >
>     >
>     >
>     > On Wed, Jun 17, 2009 at 6:05 PM, Curt Hagenlocher
>     > <curt at hagenlocher.org <mailto:curt at hagenlocher.org>
>     <mailto:curt at hagenlocher.org <mailto:curt at hagenlocher.org>>> wrote:
>     >
>     >     Good point!
>     >
>     >
>     >     On Wed, Jun 17, 2009 at 5:12 PM, Michael Foord
>     >     <fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>
>     <mailto:fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>>> wrote:
>     >
>     >         Curt Hagenlocher wrote:
>     >
>     >             ...except through the hosting API *and through the
>     new C#
>     >             dynamic functionality in .NET 4.0*.
>     >
>     >
>     >         And how do you get to the classes to use them with the new
>     >         dynamic functionality if it isn't through the hosting API?
>     >
>     >         What you do with them once you get them is your own business
>     >         of course...
>     >
>     >         Michael
>     >
>     >
>     >             On Wed, Jun 17, 2009 at 5:06 PM, Michael Foord
>     >             <fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>
>     >             <mailto:fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>>
>     >             <mailto:fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>
>     >             <mailto:fuzzyman at voidspace.org.uk
>     <mailto:fuzzyman at voidspace.org.uk>>>> wrote:
>     >
>     >                Justin Regele wrote:
>     >
>     >                    What is the status of referencing IPy libraries
>     >             compiled to
>     >                    dlls by other CLR languages? Google turned up
>     that
>     >             as of 1.1
>     >                    you had to use the embedding/hosting api's, since
>     >             the dlls
>     >                    were not compatible with say C# assemblies.
>     There were
>     >                    allusions made to this being changed.
>     >
>     >
>     >                You can't access Python classes except through the
>     >             hosting API.
>     >                There are no (public) plans for this to change
>     anytime
>     >             soon.
>     >
>     >                Michael
>     >
>     >
>     >
>     >
>     >
>     >
>     >
>     >            
>      ------------------------------------------------------------------------
>     >
>     >
>     >
>     >                    _______________________________________________
>     >                    Users mailing list
>     >                    Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>>
>     >
>     >
>     >            
>      http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>     >
>     >
>     >                --    http://www.ironpythoninaction.com/
>     >                http://www.voidspace.org.uk/blog
>     >
>     >
>     >
>     >                _______________________________________________
>     >                Users mailing list
>     >                Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     >             <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>>
>     >
>     >
>     >            
>      http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>     >
>     >            
>     ------------------------------------------------------------------------
>     >
>     >             _______________________________________________
>     >             Users mailing list
>     >             Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>
>     >            
>     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>     >
>     >
>     >
>     >         --
>     >         http://www.ironpythoninaction.com/
>     >         http://www.voidspace.org.uk/blog
>     >
>     >
>     >         _______________________________________________
>     >         Users mailing list
>     >         Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>
>     >        
>     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>     >
>     >
>     >     _______________________________________________
>     >     Users mailing list
>     >     Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>
>     <mailto:Users at lists.ironpython.com
>     <mailto:Users at lists.ironpython.com>>
>     >     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>     >
>     >
>     ------------------------------------------------------------------------
>     >
>     > _______________________________________________
>     > Users mailing list
>     > Users at lists.ironpython.com <mailto:Users at lists.ironpython.com>
>     > http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     >
>
>
>     --
>     http://www.ironpythoninaction.com/
>     http://www.voidspace.org.uk/blog
>
>
>     _______________________________________________
>     Users mailing list
>     Users at lists.ironpython.com <mailto:Users at lists.ironpython.com>
>     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>     _______________________________________________
>     Users mailing list
>     Users at lists.ironpython.com <mailto:Users at lists.ironpython.com>
>     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> Users at lists.ironpython.com
> http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>   


-- 
http://www.ironpythoninaction.com/
http://www.voidspace.org.uk/blog





More information about the Ironpython-users mailing list