summaryrefslogtreecommitdiffstats
path: root/Lib/encodings
Commit message (Collapse)AuthorAgeFilesLines
* Support trailing dots in DNS names. Fixes #782510. Will backport to 2.3.Martin v. Löwis2003-08-051-3/+15
|
* more generic reference to python interpreterSkip Montanaro2003-07-221-1/+1
|
* Remove usage of re module from encodings package search function.Marc-André Lemburg2003-05-161-4/+19
|
* Whitespace normalization.Tim Peters2003-04-243-10/+9
|
* Implement IDNA (Internationalized Domain Names in Applications).Martin v. Löwis2003-04-182-0/+409
|
* Revert Patch #670715: iconv support.Martin v. Löwis2003-04-032-39/+0
|
* Handle iconv initialization erorrsNeal Norwitz2003-02-281-1/+1
|
* Patch #670715: Universal Unicode Codec for POSIX iconv.Martin v. Löwis2003-01-262-0/+40
|
* Whitespace normalization.Tim Peters2002-12-241-1/+1
|
* Add new encoding for Ukrainian CyrillicNeal Norwitz2002-10-171-0/+54
|
* When looking for an alias, first look for the normalized name (whichGuido van Rossum2002-10-041-1/+3
| | | | | still may contain dots), then if that doesn't exist look for the name with dots replaced by underscores. This is a little more forgiving.
* Undo the removal. Guido mentioned that the encoding name is in activeMarc-André Lemburg2002-10-041-0/+1
| | | | by some email headers.
* Remove unneeded alias.Marc-André Lemburg2002-10-041-1/+0
|
* Fix doc-string.Marc-André Lemburg2002-10-041-3/+3
|
* Adapt lookup names to new more general encoding name normalizationMarc-André Lemburg2002-10-041-14/+14
| | | | scheme.
* Extending the encoding name normalization to handle more non-alphanumericMarc-André Lemburg2002-10-041-8/+20
| | | | characters.
* Oops, must convert hyphens to underscores in keys of aliases dict.Guido van Rossum2002-09-261-1/+1
|
* Add yet another alias for ASCII found in the field. Will backport toGuido van Rossum2002-09-251-0/+1
| | | | 2.2.2.
* Whitespace normalization.Tim Peters2002-08-231-1/+1
|
* Patch #505705: Remove eval in pickle and cPickle.Martin v. Löwis2002-08-141-0/+23
|
* Whitespace normalization.Tim Peters2002-08-0873-5769/+5762
|
* Revert #571603 since it is ok to import codecs that are not subdirectoriesMartin v. Löwis2002-07-291-9/+12
| | | | of encodings. Skip modules that don't have a getregentry function.
* Patch #571603: Refer to encodings package explicitly.Martin v. Löwis2002-07-281-1/+1
|
* Palm OS encoding from Sjoerd MullenderMarc-André Lemburg2002-07-121-0/+67
|
* Fix for bug #222395: UTF-16 et al. don't handle .readline().Marc-André Lemburg2002-04-053-2/+9
| | | | They now raise an NotImplementedError to hint to the truth ;-)
* Corrected import behaviour for codecs which live outside the encodingsMarc-André Lemburg2002-02-112-17/+12
| | | | package.
* Add IANA character set aliases to the encodings alias dictionaryMarc-André Lemburg2002-02-102-106/+355
| | | | | | | and make alias lookup lazy. Note that only those IANA character set aliases were added for which we actually have codecs in the encodings package.
* Patch #487275: Add windows-1251 charset alias.Martin v. Löwis2001-12-021-0/+1
|
* Python part of the UTF-7 codec by Brian Quinlan.Marc-André Lemburg2001-09-201-0/+27
|
* Patch #435971: UTF-7 codec by Brian Quinlan.Marc-André Lemburg2001-09-201-0/+4
|
* Patch #462635 by Andrew Kuchling correcting bugs in the newMarc-André Lemburg2001-09-205-11/+21
| | | | | codecs -- the self argument does matter for Python functions (it does not for C functions which most other codecs use).
* Fixed search function error reporting in the encodings packageMarc-André Lemburg2001-09-191-7/+11
| | | | | | | | __init__.py module to raise errors which can be catched as LookupErrors as well as SystemErrors. Modified the error messages to include more information about the failing module.
* Fix typo (PyChecker)Andrew M. Kuchling2001-08-131-1/+1
|
* Expose nl_langinfo through locale where available.Martin v. Löwis2001-08-101-0/+2
|
* This patch by Martin v. Loewis changes the UTF-16 codec to onlyMarc-André Lemburg2001-06-191-3/+33
| | | | | | | | | | | write a BOM at the start of the stream and also to only read it as BOM at the start of a stream. Subsequent reading/writing of BOMs will read/write the BOM as ZWNBSP character. This is in sync with the Unicode specifications. Note that UTF-16 files will now *have* to start with a BOM mark in order to be readable by the codec.
* Patch #429957: Add support for cp1140, which is identical to cp037,Martin v. Löwis2001-06-072-0/+50
| | | | | with the addition of the euro character. Also added a few EDBDIC aliases.
* Add some useful Windows encodings - patch #423221.Mark Hammond2001-06-041-0/+5
|
* Moved the encoding map building logic from the individual mappingMarc-André Lemburg2001-05-1653-159/+53
| | | | | | codec files to codecs.py and added logic so that multi mappings in the decoding maps now result in mappings to None (undefined mapping) in the encoding maps.
* Add quoted-printable codecGuido van Rossum2001-05-152-0/+59
|
* This patch changes the way the string .encode() method works slightlyMarc-André Lemburg2001-05-156-0/+407
| | | | | | | | | | | | | | | | | | | | | | | | | and introduces a new method .decode(). The major change is that strg.encode() will no longer try to convert Unicode returns from the codec into a string, but instead pass along the Unicode object as-is. The same is now true for all other codec return types. The underlying C APIs were changed accordingly. Note that even though this does have the potential of breaking existing code, the chances are low since conversion from Unicode previously took place using the default encoding which is normally set to ASCII rendering this auto-conversion mechanism useless for most Unicode encodings. The good news is that you can now use .encode() and .decode() with much greater ease and that the door was opened for better accessibility of the builtin codecs. As demonstration of the new feature, the patch includes a few new codecs which allow string to string encoding and decoding (rot13, hex, zip, uu, base64). Written by Marc-Andre Lemburg. Copyright assigned to the PSF.
* This patch changes the default behaviour of the builtin charmapMarc-André Lemburg2001-01-0352-267/+359
| | | | | | | | | | | | | | | | codec to not apply Latin-1 mappings for keys which are not found in the mapping dictionaries, but instead treat them as undefined mappings. The patch was originally written by Martin v. Loewis with some additional (cosmetic) changes and an updated test script by Marc-Andre Lemburg. The standard codecs were recreated from the most current files available at the Unicode.org site using the Tools/scripts/gencodec.py tool. This patch closes the bugs #116285 and #119960.
* Changed .getaliases() support to register the new aliases in theMarc-André Lemburg2000-12-121-4/+12
| | | | | | | | | | | encodings package aliases mapping dictionary rather than in the internal cache used by the search function. This enables aliases to take advantage of the full normalization process applied to encoding names which was previously not available. The patch restricts alias registration to new aliases. Existing aliases cannot be overridden anymore.
* Spelling fixes supplied by Rob W. W. Hooft. All these are fixes in eitherThomas Wouters2000-07-161-2/+2
| | | | | | | | | | comments, docstrings or error messages. I fixed two minor things in test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't"). There is a minor style issue involved: Guido seems to have preferred English grammar (behaviour, honour) in a couple places. This patch changes that to American, which is the more prominent style in the source. I prefer English myself, so if English is preferred, I'd be happy to supply a patch myself ;)
* Marc-Andre Lemburg <mal@lemburg.com>:Marc-André Lemburg2000-06-131-2/+2
| | | | | Removed import of string module -- use string methods directly. Thanks to Finn Bock.
* Marc-Andre Lemburg <mal@lemburg.com>:Marc-André Lemburg2000-06-071-0/+22
| | | | | Added some more codec aliases. Some of them are needed by the new locale.py encoding support.
* New codec which always raises an exception when used. ThisMarc-André Lemburg2000-06-071-0/+34
| | | | | codec can be used to effectively switch off string coercion to Unicode.
* Marc-Andre's third try at this bulk patch seems to work (except thatGuido van Rossum2000-04-052-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | his copy of test_contains.py seems to be broken -- the lines he deleted were already absent). Checkin messages: New Unicode support for int(), float(), complex() and long(). - new APIs PyInt_FromUnicode() and PyLong_FromUnicode() - added support for Unicode to PyFloat_FromString() - new encoding API PyUnicode_EncodeDecimal() which converts Unicode to a decimal char* string (used in the above new APIs) - shortcuts for calls like int(<int object>) and float(<float obj>) - tests for all of the above Unicode compares and contains checks: - comparing Unicode and non-string types now works; TypeErrors are masked, all other errors such as ValueError during Unicode coercion are passed through (note that PyUnicode_Compare does not implement the masking -- PyObject_Compare does this) - contains now works for non-string types too; TypeErrors are masked and 0 returned; all other errors are passed through Better testing support for the standard codecs. Misc minor enhancements, such as an alias dbcs for the mbcs codec. Changes: - PyLong_FromString() now applies the same error checks as does PyInt_FromString(): trailing garbage is reported as error and not longer silently ignored. The only characters which may be trailing the digits are 'L' and 'l' -- these are still silently ignored. - string.ato?() now directly interface to int(), long() and float(). The error strings are now a little different, but the type still remains the same. These functions are now ready to get declared obsolete ;-) - PyNumber_Int() now also does a check for embedded NULL chars in the input string; PyNumber_Long() already did this (and still does) Followed by: Looks like I've gone a step too far there... (and test_contains.py seem to have a bug too). I've changed back to reporting all errors in PyUnicode_Contains() and added a few more test cases to test_contains.py (plus corrected the join() NameError).
* Marc-Andre Lemburg: use all lowercase names.Guido van Rossum2000-03-311-8/+8
|
* Marc-Andre Lemburg:Guido van Rossum2000-03-281-1/+0
| | | | | | | | | | | | | | | The attached patch set includes a workaround to get Python with Unicode compile on BSDI 4.x (courtesy Thomas Wouters; the cause is a bug in the BSDI wchar.h header file) and Python interfaces for the MBCS codec donated by Mark Hammond. Also included are some minor corrections w/r to the docs of the new "es" and "es#" parser markers (use PyMem_Free() instead of free(); thanks to Mark Hammond for finding these). The unicodedata tests are now in a separate file (test_unicodedata.py) to avoid problems if the module cannot be found.
* MBCS codecs for Windows. Contributed by Mark Hammond.Guido van Rossum2000-03-281-0/+37
|