gunyarakun / python-shogi

A pure Python shogi library with move generation and validation and handling of common formats.
GNU General Public License v3.0
179 stars 43 forks source link

fix: added OrderedDict implementation for older python versions in KIF file (Issue #39) #40

Closed DerAndereJohannes closed 3 years ago

DerAndereJohannes commented 3 years ago

You are correct! Python versions lower than 3.7 are not guaranteed to be sorted by insertion. This was previously handled by the OrderedDict object. In this pull request, I have proposed a solution to interchange the implementation depending on the python version number. ie. Python 3.6 and lower to use the OrderedDict while the newer versions use the normal guaranteed dict implementation. This means that all versions will produce the same output.

Thank you for your patience. Have a nice Golden Week! :-)

coveralls commented 3 years ago

Coverage Status

Coverage increased (+0.1%) to 83.408% when pulling b83420df42f36e171ee6884834ea8c4986575373 on DerAndereJohannes:dict_fix into f607f6230dd002fee3ea2f04954d629ceb90ef38 on gunyarakun:master.

gunyarakun commented 3 years ago

I appreciate your continuous work!

Haha, "Golden Week" has been known all over the world.

gunyarakun commented 3 years ago

https://travis-ci.org/github/gunyarakun/python-shogi/builds/769191406 🎉