[IronPython] The bug about Tuple (and globals and generators)

Jim Hugunin jimhug at exchange.microsoft.com
Thu Jan 5 18:20:07 CET 2006


There are a number of serious bugs that people have encountered using the interactive console in IronPython 1.0beta1.  These bugs are caused by major changes that we (actually I) made to the way the interactive console works for this release.  These changes removed a long-standing memory leak that was present in all previous releases where every line typed at the console would consume several K of memory which would never be released until the console was closed.  Obviously, this was unacceptable and needed to be fixed before 1.0.

Unfortunately, I didn't anticipate how complicated this change was and missed a fairly large number of cases that needed to be changed - hence the bugs with tuple parameters to functions, some uses of globals and any generators.  The good news here is that these bugs should only show up when running from the interactive console.  The workaround for now is to put any troublesome constructs in a .py file and import them.

Moving forward, we're modifying the IronPython test suite so that it runs the majority of tests both in standard import mode and in a mode that simulates interactive console use.  This should greatly reduce these errors in the future.  All of these bugs should be fixed in the next couple of weeks in beta 2.

Sorry for the partially broken console in this release - Jim


-----Original Message-----
From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Michael Tan
Sent: Thursday, January 05, 2006 7:23 AM
To: users at lists.ironpython.com
Subject: [IronPython] The bug about Tuple

Dear All,
    I find these codes that run OK in IP 0.96 throw exception in IP 1.0. 
Here are the codes:
    >>> def A(*args):
    ...     print args
    
    >>> def B(*args):
    ...     A(*args)
   
    B(1,2,3)
System.NullReferenceException: Object reference not set to an instance of 
an object.




More information about the Ironpython-users mailing list