[Patches] [ python-Patches-566999 ] unicode in sys.path
noreply@sourceforge.net
noreply@sourceforge.net
Mon, 17 Jun 2002 01:41:37 -0700
Patches item #566999, was opened at 2002-06-10 20:19
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=566999&group_id=5470
Category: Core (C code)
Group: None
Status: Open
Resolution: Accepted
Priority: 5
Submitted By: Walter Dörwald (doerwalter)
Assigned to: Walter Dörwald (doerwalter)
Summary: unicode in sys.path
Initial Comment:
This patch enhances Python/import.c/find_module() so
that unicode objects found in sys.path will be treated
as legal directory names (The current code ignores
anything that is not a str). The unicode name is
converted to str using the Py_FileSystemDefaultEncoding.
----------------------------------------------------------------------
>Comment By: Martin v. Löwis (loewis)
Date: 2002-06-17 10:41
Message:
Logged In: YES
user_id=21627
Not that I know of. You should consider this a bugfix; it is
unusual to point out that a bug has been fixed in the "main"
documentation.
----------------------------------------------------------------------
Comment By: Walter Dörwald (doerwalter)
Date: 2002-06-16 01:16
Message:
Logged In: YES
user_id=89016
OK, I'll check in the patch on Monday (together with a short
note in Misc/News). Is there any documentation that must be
updated?
----------------------------------------------------------------------
Comment By: Martin v. Löwis (loewis)
Date: 2002-06-14 18:25
Message:
Logged In: YES
user_id=21627
This makes reading the patch harder; I always prefer to read
patches that only contain the essential (non-whitespace)
changes. White-space adjustments are fine when committing
changes.
Anyway, the essential parts of the patch look fine, so
please commit that change.
----------------------------------------------------------------------
Comment By: Walter Dörwald (doerwalter)
Date: 2002-06-14 16:12
Message:
Logged In: YES
user_id=89016
It's a "whitespace adaptation change"! ;)
The comments
/* it exists */
/* it's a directory */
/* it has __init__.py */
/* and case matches */
were aligned and I had to add a { at the end of the
"if (stat(..." line, so I fixed the alignment.
----------------------------------------------------------------------
Comment By: Martin v. Löwis (loewis)
Date: 2002-06-14 15:18
Message:
Logged In: YES
user_id=21627
It appears to me that
-
if (stat(buf, &statbuf) == 0 && /* it exists */
+
if (stat(buf, &statbuf) == 0 && /* it exists */
is a white-space only change, no?
----------------------------------------------------------------------
Comment By: Walter Dörwald (doerwalter)
Date: 2002-06-14 13:24
Message:
Logged In: YES
user_id=89016
diff2.txt includes the "#ifdef Py_USING_UNICODE" section.
Which "whitespace-only changes" do you mean? I readded two
blank lines, anything else?
----------------------------------------------------------------------
Comment By: Martin v. Löwis (loewis)
Date: 2002-06-13 21:49
Message:
Logged In: YES
user_id=21627
The patch must be adjusted to work with --disable-unicode. I
would also appreciated if it did not contain pure
whitespace-only changes.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=566999&group_id=5470