﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc
328,Template file name namespace,carsten.klein@…,cmlenz,"It occurs to me that, actually, all template file names must be unique, regardless of whether they are provided from different locations in the filesystem.

Perhaps this should be revised so, that the system can also disambiguate ambigously named templates?

Example

$OS_PATH/trac/ticket/templates/milestone.html
$OS_PATH/my_plugin/templates/milestone.html

It deems to me, that whatever registered first for being a template provider (see trac) will win the race and thus become the governing template provider.

The only solution I would see here is to provide a uuid upon template registration in order to make the ambigously named templates unique, i.e.

trac.ticket registers its milestone template with
  UUID-A=milestone.html

and my_plugin would register the same name template using
  UUID-B=milestone.html

Thus, when passing things over to genshi's template loader,
the loader would get the uuid from the registered file name
and would lookup the path associated with that uuid

Another, more simple, solution would be, of course, to always include the path with the template ;)

The most easiest approach, ruling out same name templates in
the api documentation, seems to be rather tricky in that all
template authors must first come up with rather unique names
for their templates. Having stated this, one could always also
use uuids as the file names for the templates...

What is your opinion on this?
",enhancement,new,minor,0.9,General,0.5.1,,,
