[IronPython] Inspect Module

Michael Foord fuzzyman at voidspace.org.uk
Tue May 19 17:26:52 CEST 2009


Davy,

What you might find helpful is to use a similar technique for 
compilation that we do for Resolver One.

All our libraries are compiled with Pyc but not our main executable.

The main executable is in C# and it is a thin wrapper over the 
IronPython hosting API. It basically has a small snippet of Python code 
embedded in it that starts the application.

This allows you to set engine options (you'll need to setup sys.argv 
yourself and possibly set the search path - which sets up sys.path) and 
also have an icon etc.

We then have an automated build which compiled the main executable and 
also compiles the Python packages with Pyc (we have a version of Pyc 
which we can use as a library rather than calling it as a script).

As well as being flexible this overcomes some of the reported 
limitations / defects in Pyc.

All the best,

Michael

Dino Viehland wrote:
> Good question!  There's currently no way to set the options but we can certainly
> add one.
>
> I've created a work item: http://ironpython.codeplex.com/WorkItem/View.aspx?WorkItemId=22475
>
>
> -----Original Message-----
> From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Davy Mitchell
> Sent: Tuesday, May 19, 2009 4:05 AM
> To: Discussion of IronPython
> Subject: Re: [IronPython] Inspect Module
>
> On Wed, May 13, 2009 at 10:23 PM, Dino Viehland <dinov at microsoft.com> wrote:
>   
>> This will should be fixed in tomorrow's source drop.  I have a check-in which removes sys._getframe unless the
>> -X:Frames or -X:FullFrames options are passed.
>>     
>
> Thanks Dino - sounds good. One question, (how) can the -X options be
> used in a pyc compiled EXE?
>
>   
>> I don't think we have a module status page yet.
>>     
>
> Would be nice to have module changes in the read me :-)
>
> Take care,
> Davy Mitchell
>
> --
>   Davy Stuff  - http://daftspaniel.blogspot.com
>   Geeky Stuff  - http://daftpython.blogspot.com
>   Davy's Ironpython Editor - http://code.google.com/p/davysironpythoneditor/
> _______________________________________________
> Users mailing list
> 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/




More information about the Ironpython-users mailing list