'Fallback for legacy templates - execute config.py'

def execute_template(self, name):

    import os
    location = 'private'
    path = os.path.join(current.request.folder, location, 'templates', name, 'config.py')
    if os.path.exists(path):
        import sys
        print >>sys.stderr, ('%s/config.py:    script    pattern    deprecated.' % name)
        self.base.template_location = location
        from gluon.fileutils import read_file
        from gluon.restricted import restricted
        code = read_file(path)
        restricted(code, layer=path)
    else:
        raise RuntimeError(('Template    not    found:    %s' % name))
