Avoid pushing in currentEntityTuples if it isn't initialized.
The library throws an exception when loading several files generated with DG Nest because it tries to push currentEntityTuples before it is initialized. These files start with type 999 instead of 0.
999
DGNestPlus
999
DXF R12 created from "DG Nest" Tangenta Software www.tangenta-software.com
0
SECTION
...
Avoiding to push if currentEntityTuples is uninitialized solves the problem.
One of the files that gives an error is file 16 downloadable from https://tangenta-software.com/download/dxf-example-files/
The current tuple (non-0) will be discarded. Is that intended? Wouldn't it be better to initialize currentEntityTuples above?
It's intentional, it avoids this kind of error without changing the current behavior. But it may not be the most correct.
As you say, a better solution could be to initialize the variable before. Another possible solution would be to ignore the tuples of type 999, which are comments and not touch the behavior for the other cases.
I will modify the PR with the solution that seems best to you.