Antoine Pitrou pit...@free.fr added the comment:
Is it still reproduceable with 2.7, 3.1 or 3.2?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3362
___
Ned Deily n...@acm.org added the comment:
This was fixed by the changes for Issue6202: 2.7 (r73270) and 3.1 (r73268).
They removed the use of the obsolete MacOS encoding APIs and now use standard
POSIX detection.
--
nosy: +ned.deily
resolution: - duplicate
status: open - closed
Changes by Terry J. Reedy tjre...@udel.edu:
--
versions: +Python 2.7, Python 3.1, Python 3.2 -Python 2.5, Python 2.6, Python
3.0
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3362
___
Changes by Ronald Oussoren ronaldousso...@mac.com:
--
assignee: - ronaldoussoren
components: +Macintosh -None
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3362
___
Changes by Antoine Pitrou pit...@free.fr:
--
nosy: +janssen, ronaldoussoren
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3362
___
___
cfr [EMAIL PROTECTED] added the comment:
It returns 27.
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3362
___
___
Python-bugs-list mailing list
Unsubscribe:
cfr [EMAIL PROTECTED] added the comment:
I noticed there is an issue (http://bugs.python.org/issue1276) with
Japanese Python users on Macs because the relevant codec is removed in
Tools/unicode/Makefile. That file also removes a number of other codecs,
including Mac Celtic. I just wondered if
Martin v. Löwis [EMAIL PROTECTED] added the comment:
Ok, now that we have established that the user's encoding is supposed to
be mac-celtic, I think I understand the problem: there simply isn't any
IANA charset name for the mac-celtic encoding, so
CFStringConvertEncodingToIANACharSetName doesn't
cfr [EMAIL PROTECTED] added the comment:
Do you happen to know why it is returning 27? Is that correct or should
it be returning something else (e.g. 39)?
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3362
Martin v. Löwis [EMAIL PROTECTED] added the comment:
0x27==39. It's all fine.
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3362
___
___
Python-bugs-list
Martin v. Löwis [EMAIL PROTECTED] added the comment:
Lists of possible string encodings are here:
http://developer.apple.com/documentation/CoreFoundation/Reference/CFStringRef/Reference/reference.html#//apple_ref/c/tdef/CFStringBuiltInEncodings
and
cfr [EMAIL PROTECTED] added the comment:
Interesting. At least the 39 makes sense. I don't understand the
documentation well enough to know what the 79 is about.
I'm sorry but I can't work out what I should do with:
printf(Encoding is %x\n, enc);
Am I meant to use this in python, a standard
cfr [EMAIL PROTECTED] added the comment:
Just realised what I'm meant to do with it. Sorry - it is late (early,
actually). Will report back when I get a chance to recompile.
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3362
cfr [EMAIL PROTECTED] added the comment:
I admit to not understanding the code involved, but I *thought* that the
problem involved cases where there *is* a preferred encoding in the
environment but it is not one of those covered by:
case kCFStringEncodingMacRoman: return mac-roman;
case
Antoine Pitrou [EMAIL PROTECTED] added the comment:
locale.getpreferredencoding() should certainly not crash but the
question remains of what should be the outcome. I can see several
possibilities:
(1) return the empty string
(2) return None
(3) return ascii (!!)
(4) raise an exception (which
Changes by Antoine Pitrou [EMAIL PROTECTED]:
--
versions: +Python 2.6, Python 3.0
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3362
___
___
Martin v. Löwis [EMAIL PROTECTED] added the comment:
No, getpreferredencoding should always produce an encoding name. If the
application had an idea what to use, it wouldn't have to ask. So I favor
(3), or, perhaps given that OSX uses UTF-8 in many places,
(5) return UTF-8
cfr [EMAIL PROTECTED] added the comment:
Altering ~/.CFUserTextEncoding so it has the contents 0:0 and then
rebooting seems to prevent the crash for GUI applications, too.
Would like to know how to fix this properly, of course, since I suspect
that the value on my machine was probably not 0:0
cfr [EMAIL PROTECTED] added the comment:
A work-around when using python from a shell environment (e.g. from a
bash shell in Terminal) is to issue
export __CF_USER_TEXT_ENCODING=0x1F5:0:0
before starting python. I haven't yet worked out how to apply this to
GUI apps. I tried editing
cfr [EMAIL PROTECTED] added the comment:
Thanks.
I couldn't get anything from gdb which wasn't already in the crash log -
likely because I don't know how to elicit the information correctly.
Output from a build with the augmented _localemodule.c:
./python.exe
Python 2.5.2 (r252:60911, Jul 16
cfr [EMAIL PROTECTED] added the comment:
On the off chance this might be helpful:
I get the same error with python 2.4.3.
Python 2.4.3 (#1, Apr 7 2006, 10:54:33)
[GCC 4.0.1 (Apple Computer, Inc. build 5250)] on darwin
Type help, copyright, credits or license for more information.
import os,
New submission from cfr [EMAIL PROTECTED]:
Darwin Kernel Version 8.11.0: Wed Oct 10 18:26:00 PDT 2007;
root:xnu-792.24.17~1/RELEASE_PPC
Python 2.5.2 (r252:60911, Feb 22 2008, 07:57:53)
[GCC 4.0.1 (Apple Computer, Inc. build 5363)] on darwin
Type help, copyright, credits or license for more
Changes by cfr [EMAIL PROTECTED]:
--
title: python version incorrectly reported in crash reports on Mac OS X 10.4.11
PPC - locale.getpreferredencoding() gives bus error on Mac OS X 10.4.11 PPC
type: behavior - crash
___
Python tracker [EMAIL
cfr [EMAIL PROTECTED] added the comment:
Please ignore the second message. I thought I was creating a second bug
report and cannot figure out anyway to edit it now I realise my error.
I've just copied that to a second report with an appropriate header as I
am assuming the two issues I'm seeing
Martin v. Löwis [EMAIL PROTECTED] added the comment:
It would be good to find out what the code inside
PyLocale_getdefaultlocale precisely is doing. I.e. what is the value of
name at that point, and is that perhaps an illegal parameter for
CFStringGetCStringPtr somehow? If the debugger can't
cfr [EMAIL PROTECTED] added the comment:
I downloaded the current source (2.5.2) and confirmed that (1) python
will build as a framework (for me) and (2) that the problem occurs for
my build, too. I did not build it as a universal binary just in case
that helped but mostly to speed things up.
I
26 matches
Mail list logo