oem_gateway icon indicating copy to clipboard operation
oem_gateway copied to clipboard

Port to Python3

Open lafrech opened this issue 10 years ago • 1 comments

The only difficulty, as far as I can tell, is the availability of the configobj module. This module is used to read the config file. It is quite practical. The gateway does not use many of its features, but at least one key feature: the possibility to define subsections.

The configparser module, included in the core, does not provide this.

There has been an attempt to port configobj to python3 but it seems to have been abandoned: http://www.voidspace.org.uk/python/weblog/arch_d7_2010_12_11.shtml https://bitbucket.org/zubin71/configobj-py3/issue/3/release

Maybe this second attempt from March 2013: http://code.google.com/p/configobj/issues/detail?id=17

And we don't see a debian package coming: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=660172

It may be more sensible to adapt the code to configparser. This would have the advantage of using a core module. This is what Pastebinit did: https://bugs.launchpad.net/pastebinit/+bug/665486

FWIW, ConfigObject, a wrapper to configparser, to access sections/options with attribute names (no idea whether this would prove useful in our case): https://pypi.python.org/pypi/ConfigObject/1.2.2

lafrech avatar Sep 03 '13 11:09 lafrech

Perhaps a viable Python3 port of ConfigObj: https://github.com/DiffSK/configobj

lafrech avatar Apr 04 '14 12:04 lafrech