Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Antoine Pitrou
On Fri, 22 Oct 2010 17:37:53 +0200 Stefan Behnel wrote: > > I think the general problem is that "the module" can be a pretty broad > thing, potentially referring to all sorts of stuff such as (usually) > several other modules. I wouldn't think of unloading modules as a general problem. We shou

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Stefan Behnel
Antoine Pitrou, 22.10.2010 16:55: On Fri, 22 Oct 2010 09:41:09 -0500 Benjamin Peterson wrote: 2010/10/22 exarkun: Instances of classes don't refer to the module their class is defined in. It seems more likely that the reason the module is garbage collected is that there really is nothing whic

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Benjamin Peterson
2010/10/22 Antoine Pitrou : > On Fri, 22 Oct 2010 09:41:09 -0500 > Benjamin Peterson wrote: >> 2010/10/22  : >> > Instances of classes don't refer to the module their class is defined in. >> >  It seems more likely that the reason the module is garbage collected is >> > that there really is nothin

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Stefan Behnel
exar...@twistedmatrix.com, 22.10.2010 16:32: Instances of classes don't refer to the module their class is defined in. It seems more likely that the reason the module is garbage collected is that there really is nothing which refers to it anymore. The behavior of setting the attributes of a modu

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Antoine Pitrou
On Fri, 22 Oct 2010 09:41:09 -0500 Benjamin Peterson wrote: > 2010/10/22 : > > Instances of classes don't refer to the module their class is defined in. > >  It seems more likely that the reason the module is garbage collected is > > that there really is nothing which refers to it anymore. > > I

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Benjamin Peterson
2010/10/22 Stefan Behnel : > Benjamin Peterson, 22.10.2010 16:17: >> What about 3.1.0 then? > > The 3.1.2 release was fine, but the current 3.1 SVN branch is not. I assume > you have applied the change there, too? Yes. Unfortunately, this behavior is more "correct" for most cases because it result

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Benjamin Peterson
2010/10/22 : > Instances of classes don't refer to the module their class is defined in. >  It seems more likely that the reason the module is garbage collected is > that there really is nothing which refers to it anymore. Indeed, this is really a Python bug, but there's no good way to deal with

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Stefan Behnel
Benjamin Peterson, 22.10.2010 16:17: 2010/10/22 Stefan Behnel: Benjamin Peterson, 22.10.2010 16:03: 2010/10/22 Stefan Behnel: since SVN rev. 85392, Cython's installation fails on the py3k branch with a weird globals error. I think it is related to some sys.modules magic that we do in order to

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread exarkun
On 02:13 pm, stefan...@behnel.de wrote: Benjamin Peterson, 22.10.2010 16:03: 2010/10/22 Stefan Behnel: since SVN rev. 85392, Cython's installation fails on the py3k branch with a weird globals error. I think it is related to some sys.modules magic that we do in order to support running Cython

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Benjamin Peterson
2010/10/22 Stefan Behnel : > Benjamin Peterson, 22.10.2010 16:03: >> >> 2010/10/22 Stefan Behnel: >>> >>> since SVN rev. 85392, Cython's installation fails on the py3k branch with >>> a >>> weird globals error. I think it is related to some sys.modules magic that >>> we >>> do in order to support r

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Stefan Behnel
Benjamin Peterson, 22.10.2010 16:03: 2010/10/22 Stefan Behnel: since SVN rev. 85392, Cython's installation fails on the py3k branch with a weird globals error. I think it is related to some sys.modules magic that we do in order to support running Cython in Python 3 using lib2to3. Basically, wha

Re: [Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Benjamin Peterson
2010/10/22 Stefan Behnel : > Hi, > > since SVN rev. 85392, Cython's installation fails on the py3k branch with a > weird globals error. I think it is related to some sys.modules magic that we > do in order to support running Cython in Python 3 using lib2to3. > > Basically, what we do is, we import

[Python-Dev] SVN rev. 85392 broke module handling in py3k

2010-10-22 Thread Stefan Behnel
Hi, since SVN rev. 85392, Cython's installation fails on the py3k branch with a weird globals error. I think it is related to some sys.modules magic that we do in order to support running Cython in Python 3 using lib2to3. Basically, what we do is, we import some parts of Cython at the beginni