This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Python crashes when __init__.py is a directory.
Type: Stage:
Components: None Versions: Python 2.3
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: theller Nosy List: nnorwitz, theller, warkid
Priority: normal Keywords:

Created on 2003-11-20 13:57 by warkid, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
package_include_error.zip warkid, 2003-11-20 13:57 unpack and run test.py
Messages (3)
msg19047 - (view) Author: Kerim Borchaev (warkid) Date: 2003-11-20 13:57
If package/__init__.py is a directory then this code 
crashes under Windows XP:
###
import sys#or os or maybe something else;-)
import package#package/__init__.py is DIRECTORY!

'\n'.join([])
###

Test case attached.
msg19048 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2003-11-20 22:44
Logged In: YES 
user_id=33168

I can't duplicate this problem on Linux, so I'm assuming
it's Windows specific.
msg19049 - (view) Author: Thomas Heller (theller) * (Python committer) Date: 2004-06-07 15:09
Logged In: YES 
user_id=11105

For me, it crashes in a  debug built (on Windows) after
doing 'import package' with a refcount error.
I don't think it's windows specific.

Fixed in Python/import.c, CVS rev. 2.232 and rev. 2.222.6.3.
History
Date User Action Args
2022-04-11 14:56:01adminsetgithub: 39571
2003-11-20 13:57:15warkidcreate