prefer Python for new scripts?

Simo Sorce ssorce at redhat.com
Fri Oct 30 10:28:59 EDT 2009


On Thu, 2009-10-29 at 23:32 -0400, Tom Yu wrote:
> I propose that we move toward preferring Python for new scripts in the
> source tree.  Scripts in our tree are written in many languages,
> including Python, Perl, Tcl/Expect, Bourne shell, and others.
> 
> Anecdotal evidence suggests that it is easier to write maintainable
> Python code than maintainable Perl code, and that newcomers find
> Python an easier language to learn than Perl.
> 
> I'm not suggesting that we rewrite all our scripts in Python, just
> that we prefer it in the future.  Reasons to not choose Python for new
> work would include extending existing scripts, etc. that are written
> in another language.  For example, the Tcl/Expect/Dejagnu testing
> frameworks we have are somewhat cumbersome, and I plan to replace them
> with something more consolidated, but any modifications or extensions
> to them should still be written in the currently used Tcl/Expect
> language.
> 
> I have looked at a Python-based testing framework called QMTest, which
> appears somewhat promising, as a replacement for Dejagnu.  It hasn't
> had a release since 2007, but this is not inherently a bad thing.
> 
> Please provide feedback on these suggestions.  Thanks.

Unfortunately right now python is going through a transition phase.

In theory using 2.6 carefully should allow you to use the code with 3.0
later with minimal or no changes.
Using anything below 2.6 may require to migrate scripts later on.
I guess what will really drive your choice is going to be dependencies
anyway. Btw if someone would go and contribute to enhance krb5 python
bindings that would be awesome :-)

Simo.

-- 
Simo Sorce * Red Hat, Inc * New York




More information about the krbdev mailing list