Hi Boris - this is actually fixed in my local copy (hope to check it in and make a new release soon, as this will affect anyone using the bootstrap hook in a native CPython).
As a temporary workaround, you can arrange to hold a reference to the globals dictionary someplace before importing the CLR module: import sys sys._hack = globals() # now you can import CLR... import CLR Brian Lloyd [EMAIL PROTECTED] V.P. Engineering 540.361.1716 Zope Corporation http://www.zope.com > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Behalf Of Boris Capitanu > Sent: Thursday, April 14, 2005 2:12 PM > To: [email protected] > Subject: [Python.NET] ActivePython 2.4.1.245 problem > > > Hi, > > I just upgraded my Python to ActiveState's 2.4.1 > version and some thing apparently broke in the bridge. > > Here are some things I was able to do in version 2.4.0 > that now no longer work: > > C:\Python24>python > ActivePython 2.4.1 Build 245 (ActiveState Corp.) based > on > Python 2.4.1 (#65, Mar 30 2005, 09:33:37) [MSC v.1310 > 32 bit (Intel)] on win32 > Type "help", "copyright", "credits" or "license" for > more information. > >>> import CLR > >>> from CLR.System.Reflection import Assembly > Traceback (most recent call last): > File "<stdin>", line 1, in ? > ImportError: __import__ not found > >>> > > > ------------- > > C:\Python24>python > ActivePython 2.4.1 Build 245 (ActiveState Corp.) based > on > Python 2.4.1 (#65, Mar 30 2005, 09:33:37) [MSC v.1310 > 32 bit (Intel)] on win32 > Type "help", "copyright", "credits" or "license" for > more information. > >>> import CLR > >>> import CLR > Traceback (most recent call last): > File "<stdin>", line 1, in ? > ImportError: __import__ not found > >>> > >>> import os > Traceback (most recent call last): > File "<stdin>", line 1, in ? > ImportError: __import__ not found > >>> > ---------------- > > It looks that after you first "import CLR" something > gets screwed up inside CPython's tables because it > can't find any imports anymore. > > Anyone else have the same problem? > > Boris > > > > > __________________________________ > Do you Yahoo!? > Make Yahoo! your home page > http://www.yahoo.com/r/hs > _________________________________________________ > Python.NET mailing list - [email protected] > http://mail.python.org/mailman/listinfo/pythondotnet > _________________________________________________ Python.NET mailing list - [email protected] http://mail.python.org/mailman/listinfo/pythondotnet
