[New-bugs-announce] [issue3515] refcount gc bug?

Hirokazu Yamamoto report at bugs.python.org
Thu Aug 7 12:54:55 CEST 2008


New submission from Hirokazu Yamamoto <ocean-city at users.sourceforge.net>:

I'm not sure this is bug or not, but shouldn't `io' be collected by
refcount GC? This happens on python2.5 but doesn't happend on python3.0.

import os

def foo():
    io = open("a.txt", "w")
    raise RuntimeError()

try:
    foo()
except:
    pass

os.remove("a.txt") # WindowsError (Error32)
    # Process cannot access to the file.
    # Another process is using it.

----------
messages: 70816
nosy: ocean-city
severity: normal
status: open
title: refcount gc bug?
versions: Python 2.5, Python 2.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3515>
_______________________________________


More information about the New-bugs-announce mailing list