Re: [IronPython] Is any one use IronPython in your project?

2006-11-22 Thread Mike Raath
There will be different reasons amongst all developers of Iron Python. For my point of view I needed to be able to use existing Python Libraries in a .Net environment. I could well have rewritten the Python code in .Net classes but then I would have meant 2 separate code bases to maintain. I foun

Re: [IronPython] Is any one use IronPython in your project?

2006-11-22 Thread Sylvain Hellegouarch
Kevien Lee wrote: > Hi, > Now ,Ironpython had release some time,but i want to konw is any one use > IronPython in your project? > As a dynamic language ,what it will bring us some advantage for > project,which the advantage C#,VB.net couldn't have? >From a Python user POV, IP is far from being go

[IronPython] Is any one use IronPython in your project?

2006-11-22 Thread Kevien Lee
Hi, Now ,Ironpython had release some time,but i want to konw is any one use IronPython in your project? As a dynamic language ,what it will bring us some advantage for project,which the advantage C#,VB.net couldn't have? ___ users mailing list users@lis

Re: [IronPython] Very strange problem with ExecuteFile

2006-11-22 Thread Giles Thomas
Thanks, that makes sense. The code we have that was showing the problem is auto-generated, so we should be able to get our generator to split it up into smaller chunks and execute them separately. Regards, Giles Martin Maly wrote: Exactly. In console, each statement is compiled into its ow

Re: [IronPython] Very strange problem with ExecuteFile

2006-11-22 Thread Martin Maly
Exactly. In console, each statement is compiled into its own CLR method so you won't hit this problem. Martin -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Giles Thomas Sent: Wednesday, November 22, 2006 8:12 AM To: Discussion of IronPython Subject: Re

Re: [IronPython] Very strange problem with ExecuteFile

2006-11-22 Thread Giles Thomas
Martin, We don't see the same problem in the IronPython console; is this because it is executing the file somehow differently - perhaps line-by-line, maintaining a context dictionary? Regards, Giles Martin Maly wrote: > I believe in this case the exception is result of what seems to be a

Re: [IronPython] Very strange problem with ExecuteFile

2006-11-22 Thread Martin Maly
I believe in this case the exception is result of what seems to be a CLR limitation. The code (in this case one static method) IronPython needs to generate to handle this input is too big and CLR/Jit then throws invalid program exception. The only workaround I am aware of is to split the code u

[IronPython] Very strange problem with ExecuteFile

2006-11-22 Thread Giles Thomas
When the attached test.py is executed using ExecuteFile (sample .cs file also attached), we get the following exception: System.InvalidProgramException: Common Language Runtime detected an invalid program. The problem does not occur under the IP Console (which I guess doesn't use ExecuteF

Re: [IronPython] How to lock a file like win32file.LockFileEx()?

2006-11-22 Thread Sanghyeon Seo
2006/11/21, Patrick O'Brien <[EMAIL PROTECTED]>: > What would one use in IronPython to get the equivalent of fcntl.flock() or > win32file.LockFileEx()? .NET's FileStream has Lock() and Unlock() methods, but I don't know how to apply these to IronPython file object. Any idea? One could use P/Invok