Lookup all available registered Codecs at once?

Marcin 'Qrczak' Kowalczyk qrczak at knm.org.pl
Fri Jun 22 18:43:29 CEST 2001


Thu, 14 Jun 2001 19:40:55 GMT, Fredrik Lundh <fredrik at pythonware.com> pisze:

> Something like this might work:

Or might not. This is Python 2.1:

[...]
(<method Codec.encode of Codec instance at 0x8239374>, <method Codec.decode of Codec instance at 0x8239734>, <class encodings.mac_turkish.StreamReader at 0x823f40c>, <class encodings.mac_turkish.StreamWriter at 0x823f374>)
Traceback (most recent call last):
  File "<stdin>", line 5, in ?
  File "/usr/local/lib/python2.1/encodings/__init__.py", line 47, in search_function
    mod = __import__(modname,globals(),locals(),'*')
  File "/usr/local/lib/python2.1/encodings/mbcs.py", line 14, in ?
    class Codec(codecs.Codec):
  File "/usr/local/lib/python2.1/encodings/mbcs.py", line 18, in Codec
    encode = codecs.mbcs_encode
AttributeError: 'codecs' module has no attribute 'mbcs_encode'

-- 
 __("<  Marcin Kowalczyk * qrczak at knm.org.pl http://qrczak.ids.net.pl/
 \__/
  ^^                      SYGNATURA ZASTĘPCZA
QRCZAK



More information about the Python-list mailing list