On Tue, Mar 11, 2008 at 6:51 AM, Sean Allen <[EMAIL PROTECTED]> wrote:
> > On Mar 10, 2008, at 9:05 PM, Sean McAfee wrote: > > On Mon, Mar 10, 2008 at 5:29 PM, Sean Allen <[EMAIL PROTECTED]> wrote: > > > We are getting ready to embark on porting a bunch of old code ( and > > several hundred TT templates ) to Python and plan on using template- > > python to ease everything along. Anyone else but in any serious work > > with the python version of TT? If yes, do you have any gotchas to > > share that we should be aware of ahead of time? > > > > As the implementor of template-python, I'm probably the person with most > serious work under my belt--the most that I know of, anyway. While I > haven't yet attempted to convert any sizeable Perl-TT project to Python, I > did document every potential gotcha I could think of in the file > README.python, located at the top of the Python source distribution. I'd > encourage you to read that file carefully. Other than that, all of the > inline POD documentation from the Perl source code has been carried over > into the Python source code, suitably translated into the Python paradigm. > It can be read either by browsing the source code, or (as noted in > README.python) by the built-in help feature of the interactive Python > interpreter. For example: > > >>> import template.stash > >>> help(template.stash.Stash) > ... documentation for the Stash class ... > > If you come across any problems I didn't foresee, I'd be happy to help you > resolve them. You can contact me privately, or--more preferably--bring up > any issues here on the mailing list. > > > Thanks Sean, > > I did read the README.python and it was very thorough and informative, I > always just like to check. > When this part rolls around in 6-12 weeks, if we hit any snags, I'll be > back. > > I guess we get to be a trial case on this. > If it's any comfort, all of the unit tests from the original Perl implementation (except for a few that test features with no counterpart in Python-land) have been translated, and all pass. Oh, actually, that's another possible source of help: the unit tests. If you happen to get unexpected behavior related to some directive or feature, check the associated unit test to see what might be different. --Sean
_______________________________________________ templates mailing list templates@template-toolkit.org http://mail.template-toolkit.org/mailman/listinfo/templates