[Python-Dev] New miniconf module (original) (raw)

Sylvain Fourmanoit syfou at users.sourceforge.net
Thu Jul 27 09:39:39 CEST 2006


An updated version is now available, based to the feedback of Phillip J. Eby and David Hopwood (stand-alone module[1], patch[2]):

But I agree this looks a lot like JSON, since ecmascript syntax for literals looks a lot like the one of Python... For the same reasons there is a need for JSON, I think having something like miniconf in the standard lib would benefit the users. Actually, I would see more reason to include JSON in the standard library, since it's at least something approaching an internet protocol these days.

Having JSON there would indeed be nice: In fact, I recall being initially surprised it was not supported by the standard library.

But is there a need to choose? Why not have both? The miniconf approach has its advantages and differences:

from miniconf import dump file('test.py','w').write(dump({'spam': 1})) import test

I know this in not the best example, but you get the idea...

Anyway, if I had to choose between the two, I would definitively want simplejson part of the standard library well before miniconf, since it can be used in so many different situations, but I wouldn't choose JSON as a configuration format given the choice to use the Python notation employed by miniconf either.

Yours,

-- Sylvain <syfou at users.sourceforge.net>

Nobody said computers were going to be polite.

[1]http://cheeseshop.python.org/pypi?:action=display&name=miniconf&version=1.1.0 [2]http://sourceforge.net/tracker/index.php?func=detail&aid=1527597&group_id=5470&atid=355470



More information about the Python-Dev mailing list