IronPython 2.6.1 Released
There have been three "IronPython relevant" releases in the last twenty four hours with another one to come.
.NET 4.0 is the version of the .NET framework (and C# language) that includes support for the dynamic keyword - allowing for dynamic typing in C# and easier interoperation between C# and dynamic languages.
IronPython 2.6.1 is the latest stable release of IronPython. Despite being a minor point release there are some very nice improvements and new features. Headline features include faster importing and startup, bugfixes in ctypes, *much* better Python Unicode compatibility and ssl module compatibility:
- IronPython 2.6.1 (for .NET 2 and .NET 4)
- .NET 4.0
- Visual Studio 2010
.NET 4.0 is the version of the .NET framework (and C# language) that includes support for the dynamic keyword - allowing for dynamic typing in C# and easier interoperation between C# and dynamic languages.
IronPython 2.6.1 is the latest stable release of IronPython. Despite being a minor point release there are some very nice improvements and new features. Headline features include faster importing and startup, bugfixes in ctypes, *much* better Python Unicode compatibility and ssl module compatibility:
We’re pleased to announce the final release of IronPython 2.6.1. This version of IronPython makes great strides in stability and compatibility, including a considerable number of targeted bugfixes. This is our largest servicing release to date, and with your help both before and during the RC phase, along with the simultaneous release of .NET 4.0, this has become a very exciting release for all of us..NET 4.0 includes a new version of the Common Language Runtime and to use the new features you need to use a version of IronPython compiled against .NET 4. This is why IronPython for .NET 4 is a separate download. Surprisingly, this version of IronPython is much faster than IronPython for .NET 2. Dave Fugate blogs about this (and other improvements for working with IronPython under .NET 4):
The IronPython 2.6.1 RC included fixes for well over 50 bugs, large and small. Ctypes has had a number of significant updates, including union support, variant_bool, and wintypes. Another focus has been on sys.settrace, making debugging more reliable. For example, sys.settrace now returns the correct frame, supports tracing through modules, and no longer interferes with “import os”. Other notable fixes include thread-safe importing, and the missing error code in _winreg exception.
In addition, we’ve made a substantial improvement in import time. Not only does this reduce startup time, but it can speed up the importing of large, definition-heavy modules by up to 50%.
Since the RC, we have fixed numerous other issues, as well as adding CPython’s ssl.py to our distribution. We’ve also made some major unicode-related changes in response to your feedback on the mailing list, changes that improve compatibility with certain third-party applications including Django. In particular, invoking unicode() or using unicode string formatting will now call __unicode__() first if it is present on the object. Finally, we’ve included a new code sample that shows how to use __clrtype__ to create custom CLR classes from IronPython. This sample is a sneak preview of what we expect will become a fully supported IronPython module, so we encourage anyone who is so inclined to try it out and let us know how it goes.
Where exactly is this improvement coming from? Well we don't know quite yet. Our first bona fide .NET 2.0 SP1 versus .NET 4.0 IronPython perf suite run occurred less than two weeks ago! An educated guess is that at least a small portion of this improvement stems from the fact that Microsoft.Scripting.Core.dll is actually part of the .NET 4.0 framework. Any ways, you can see more of the performance characteristics of IronPython running under both these .NET releases here.
Hi,
ReplyDeleteI used to be able to simply drop custom DLLs in the Lib sub-directory of the IronPython installed directory and make calls to clr.AddReferenceToFile("some dll") and it would load without any problems. With this latest release for .NET 4.0, the loading fails with message:
IOError: System.IO.IOException: Could not add reference to assembly MarklogicXcc
.dll
at Microsoft.Scripting.Actions.Calls.MethodCandidate.Caller.Call(Object[] arg
s, Boolean& shouldOptimize)
at IronPython.Runtime.Types.BuiltinFunction.BuiltinFunctionCaller`2.Call1(Cal
lSite site, CodeContext context, TFuncType func, T0 arg0)
at System.Dynamic.UpdateDelegates.UpdateAndExecute3[T0,T1,T2,TRet](CallSite s
ite, T0 arg0, T1 arg1, T2 arg2)
at IronPython.Runtime.PythonFunction.FunctionCaller`1.Call1(CallSite site, Co
deContext context, Object func, T0 arg0)
at IronPython.Compiler.Ast.CallExpression.Invoke1Instruction.Run(InterpretedF
rame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0)
at IronPython.Compiler.RuntimeScriptCode.InvokeTarget(Scope scope)
at IronPython.Compiler.RuntimeScriptCode.Run(Scope scope)
at IronPython.Hosting.PythonCommandLine.RunFileWorker(String fileName)
at IronPython.Hosting.PythonCommandLine.RunFile(String fileName)
I have created the IRONPYTHONPATH system variable with the path to the LIb subdirectory but that did not help either.
Thoughts?