Loading ...
Sorry, an error occurred while loading the content.

701[Cheetahtemplate-discuss] NT #import broken and respond() issue

Expand Messages
  • Greg Czajkowski
    Feb 1, 2002
      I filed a bug #511423. Does anyone have any ideas or
      has it been fixed in CVS?

      Also when I pass object instances into Cheetah and
      then try to have to instance interpololated by calling
      __str__ Cheetah instead insists on the instance having
      the respond method, why?

      #def function($instance)
      #end def

      -------Bug Info-----------------------------------
      There's a couple problems on NT with importing:
      packageName = 'Cheetah.Temp.' + dirName.replace
      ('\\', '/').replace('/', '_')

      Causes a creation of a bad package name
      [Dbg]>>> dirName
      [Dbg]>>> packageName

      Further more. Simple #imports of modules in sys.path
      dont work

      File "MyTemplate.py", line 43, in __init__
      Template.__init__(self, template)
      File "C:\pzehr\tchain\packages\Cheetah\Template.py",
      line 187, in __init__
      self.compile(source, file)
      File "C:\pzehr\tchain\packages\Cheetah\Template.py",
      line 218, in compile
      File "C:\pzehr\tchain\packages\Cheetah\Compiler.py",
      line 1063, in compile
      File "C:\pzehr\tchain\packages\Cheetah\Parser.py",
      line 1025, in parse
      File "C:\pzehr\tchain\packages\Cheetah\Parser.py",
      line 1140, in eatDirective
      File "C:\pzehr\tchain\packages\Cheetah\Parser.py",
      line 1399, in eatImport
      mod = self._templateObj._importAsDummyModule
      File "C:\pzehr\tchain\packages\Cheetah\Template.py",
      line 403, in _importAsDummyModule
      packageName = self._makeDummyPackageForDir
      File "C:\pzehr\tchain\packages\Cheetah\Template.py",
      line 392, in _makeDummyPackageForDir
      File "C:\pzehr\tchain\packages\Cheetah\Template.py",
      line 445, in _importModuleFromDirectory
      fp, pathname, stuff = imp.find_module(moduleName,
      NameError: Can't find file for module
      (filename C:\)

      Do You Yahoo!?
      Great stuff seeking new owners in Yahoo! Auctions!

      Cheetahtemplate-discuss mailing list