834 5010 LX sequence # collisions?
Opened this issue · 4 comments
@azoner Hi John - it has been a while - but I am encountering an issue with a new submitter that technically falls into "standards" (834 005010X220A1). I am opening a new issue at this point (related to #42. It is definitely related however to Loop 2700 or LX segment valiation logic.
It seems there is an issue where if LX01 values outside of a LS2700/LE2700 (Loop 2700 wrapper) are the same as LX01 values inside the LS2700/LE2700 (Loop 2700 wrapper) - that we get an issue:
"Segment LS*2700 not found. Started at /ISA_LOOP/GS_LOOP/ST_LOOP/DETAIL///<Loop != 2700>"
See pastebin link for an example file that should be considered valid for 834 005010X220A1 processing.
What should happen is the LX segments where the LX01 value matches an LX01 value in the LS/LE Loop 2700 envelope - should not be colliding. It looks like they are in somehow.
Another possibility - if collision of LX01 values is not the issue - is that the LX01 values are being expected to be 100% sequential and contiguous within the LS/LE Loop 2700, but all that is required is that they be unique and sequential - but not necessarily contiguous.
So basically:
Allow collisions of LX01 values between a unique LX segment outside of Loop 2700 and a unique LX segment inside Loop 2700.
Within Loop 2700 - enforce unique and in sequence but can skip (i.e. 1,2,26,30) - but do not enforce a need for contiguous (i.e. 1,2,3,4.. etc).
@ddw360
I was experiencing a similar issue on pyx12 v2.3.3. For some reason, the Python Package Index (PyPI) has the latest pyx12 set to v2.3.3, but the latest is actually v2.3.4.
Doing a pip install git+https://github.com/azoner/pyx12.git#egg=pyx12
(directly from this repository) fixed the issue for me.
Thanks for spotting that. I will publish the latest version to PyPI.
@ddw360
I was experiencing a similar issue on pyx12 v2.3.3. For some reason, the Python Package Index (PyPI) has the latest pyx12 set to v2.3.3, but the latest is actually v2.3.4.Doing a
pip install git+https://github.com/azoner/pyx12.git#egg=pyx12
(directly from this repository) fixed the issue for me.
Thanks for catching. This resolves it.