pray / iso8583py

Automatically exported from code.google.com/p/iso8583py
GNU General Public License v3.0
0 stars 0 forks source link

Data Field 18 has LLL instead of N #13

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
According to the ISO spec, DE 18 should be N -> 4, but your class is setting 
LLL and cause an exception. Fixed it subclassing ISO8583, but would be nice to 
get it patched:

self._BITS_VALUE_TYPE[18] = ['18','Message error indicator','N',4,'n']

Regards,

Original issue reported on code.google.com by robson....@valepresente.com.br on 23 Oct 2014 at 5:23

GoogleCodeExporter commented 8 years ago
Hi, This is a "Copy and Paste" bug.

Will be fixed.

Best regards,

Original comment by igo...@gmail.com on 23 Oct 2014 at 5:51

GoogleCodeExporter commented 8 years ago
Hi,

The Fix Whithout the new lib is using the redefine Method:

Example:

from ISO8583.ISO8583 import ISO8583
#(...)
i2 = ISO8583()
i2.redefineBit(18, '18', i2.getLargeBitName(18), 'N', 4, 'N' )   

Visit the example page to more info: 
https://code.google.com/p/iso8583py/wiki/ExamplesPage 

Best Regards,

Original comment by igo...@gmail.com on 29 Oct 2014 at 12:00

GoogleCodeExporter commented 8 years ago
Actually, I did something different. Subclassed ISO8583 class, redefined the 
bit and added support to EBCDIC, as I'm testing the package using Mastercard 
messages.

Till now, everything is looking good. Would be nice to move this project to 
github and send some pull requests.

BR

Robson

Original comment by robson....@valepresente.com.br on 29 Oct 2014 at 12:08

GoogleCodeExporter commented 8 years ago
Fixed in revire #52 https://code.google.com/p/iso8583py/source/detail?r=52

Original comment by igo...@gmail.com on 29 Oct 2014 at 12:10