Re: [TurboGears] Templating Default Question

16 views
Skip to first unread message
Message has been deleted

Alessandro Molina

unread,
Nov 19, 2015, 3:56:33 AM11/19/15
to TurboGears
I wan't involved with the project at the time but I can suppose it was because:

 - Kajiki didn't exist at the time, so it wasn't a candidate
- TurboGears always had the feature of a validated template engine able to detect errors at compile time (since version 1), so  Mako and Jinja were not candidates as they do not they validate template structure nor provide i18n for tags content.
 - TG1 was born on Kid, Genshi was meant as a successor to Kid, so it was the best candidate for TG2 ( http://genshi.edgewall.org/wiki/GenshiFaq#SothenwhynotjustuseKid )
 

On Thu, Nov 19, 2015 at 3:35 AM, Robert James Liguori <glies...@gmail.com> wrote:
Hi there,

Another question...

'just curious, why was Genshi chosen as the default templating tool over Jinaj2, Mako and Kajiki?

Thanks,
Robert

--
You received this message because you are subscribed to the Google Groups "TurboGears" group.
To unsubscribe from this group and stop receiving emails from it, send an email to turbogears+...@googlegroups.com.
To post to this group, send email to turbo...@googlegroups.com.
Visit this group at http://groups.google.com/group/turbogears.
For more options, visit https://groups.google.com/d/optout.

Christoph Zwerschke

unread,
Nov 19, 2015, 3:58:36 AM11/19/15
to turbo...@googlegroups.com
Am 19.11.2015 um 03:35 schrieb Robert James Liguori:
> Another question...
>
> 'just curious, why was Genshi chosen as the default templating tool over
> Jinaj2, Mako and Kajiki?

Historical reasons. At the time when TurboGears was created, templating
languages that were based on XML and operated via XML namespaces were a
concept that fitted very well with the trend to use XHTML at that time.
Now that HTML5 has become the standard and XML is not the hype any more,
such templating languages have become less interesting. But still, XML
based templating languages have some benefits, and using them was one of
the original ideas of TurboGears, which started with Kid. I think the
first such templating language was TAL (used by Zope), then came Kid
which was very cool at the time when TurboGears was created, then Kid
was abandoned and we had Genshi, now Genshi has also been abandoned and
TurboGears will probably switch to Kajiki. Jinja2 and Mako are not XML
based. Jinja2 is pretty popular because it's similar to the Django
templating language. Mako was even earlier I think and was added in
TurboGears2.

-- Christoph
Message has been deleted
Message has been deleted

Alessandro Molina

unread,
Nov 19, 2015, 6:50:39 AM11/19/15
to TurboGears
http://pythonhosted.org/Kajiki/ is considered to be the homepage.

We are still investigating future template engine developments, Genshi recently moved to GitHub and recovered development ( https://github.com/edgewall/genshi ) so we might consider staying on Genshi if they can guarantee a stable future roadmap and Python3.5 compatibility. 

We are currently trying to support Kajiki as a major template engine to guarantee it can be a viable fallback for the future in case Genshi development is abandoned. There is already a quick migration path from Genshi to Kajiki documented ( http://turbogears.readthedocs.org/en/latest/turbogears/genshi-xml-templates.html#converting-genshi-templates-to-kajiki ) which works without manual code changes for most projects, but there has been no decision yet on switching to Kajiki so far as we are waiting to see what Genshi future will be.

So you can currently keep developing using Genshi as in case of a future switch we will do our best to to achieve a migration path which doesn't require any major code rewrites.

On Thu, Nov 19, 2015 at 12:43 PM, Robert James Liguori <glies...@gmail.com> wrote:
Is that a high likelihood that Kijiki will be the default?  If so what TG2 build is this targerted for?

Reply all
Reply to author
Forward
0 new messages