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.

Author Vladimir Filippov
Recipients Vladimir Filippov, ezio.melotti, serhiy.storchaka, vstinner
Date 2017-06-07.15:45:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1496850317.58.0.853979900235.issue30586@psf.upfronthosting.co.za>
In-reply-to
Content
According to ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/EBCDIC/CP037.TXT symbols [ and ] have other codes (instead of 0xAD and 0xBD):
0xBA	0x005B	#LEFT SQUARE BRACKET
0xBB	0x005D	#RIGHT SQUARE BRACKET

Looks like ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/EBCDIC/CP500.TXT was created based on https://www.ibm.com/support/knowledgecenter/SSZJPZ_11.3.0/com.ibm.swg.im.iis.ds.parjob.adref.doc/topics/r_deeadvrf_ASCII_to_EBCDIC.html
But this information "This translation is not bidirectional. Some EBCDIC characters cannot be translated to ASCII and some conversion irregularities exist in the table. For more information, see Conversion table irregularities." was ignored. Additional, this line from CP500.TXT:
0xBB	0x007C	#VERTICAL LINE
haven't any source in IBM's table.

Example from z/OS mainframe:
-------------------
bash-4.3$ iconv -f 819 -t 1047 -T ascii.txt > ebcdic.txt
bash-4.3$ ls -T *.txt
t ISO8859-1   T=on  ascii.txt
t IBM-1047    T=on  ebcdic.txt
bash-4.3$ cat ascii.txt
![]|bash-4.3$ od -h ascii.txt
0000000000    21  5B  5D  7C
0000000004
bash-4.3$ cat ebcdic.txt
![]|bash-4.3$ od -h ebcdic.txt
0000000000    5A  AD  BD  4F
0000000004
-------------------
History
Date User Action Args
2017-06-07 15:45:17Vladimir Filippovsetrecipients: + Vladimir Filippov, vstinner, ezio.melotti, serhiy.storchaka
2017-06-07 15:45:17Vladimir Filippovsetmessageid: <1496850317.58.0.853979900235.issue30586@psf.upfronthosting.co.za>
2017-06-07 15:45:17Vladimir Filippovlinkissue30586 messages
2017-06-07 15:45:17Vladimir Filippovcreate