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

Re: [Cheetahtemplate-discuss] Error message with missing #end def

Expand Messages
  • Tavis Rudd
    All directives have to be closed explicitly now. It s been this way for at least a year. I ve just improved the error message: def
    Message 1 of 2 , Jan 1, 2006
    • 0 Attachment
      All directives have to be closed explicitly now. It's been this way for at
      least a year. I've just improved the error message:

      def assertEmptyIndentStack(self):
      if self._indentStack:
      errorMsg = (
      "Some #directives are missing their corresponding #end ___
      tag: %s" %(
      ', '.join(self._indentStack)))
      raise ParseError(self, msg=errorMsg)

      On Saturday 31 December 2005 2:31 pm, Mike Orr wrote:
      > I'm not sure if this is a bug or just a cryptic error message. I had
      > a child template with a #def covering most of the content, but
      > accidentally deleted the '#end def'. The error message pointed to the
      > last character in the template and said:
      >
      >
      > Cheetah.Parser.ParseError:
      >
      > Parsing claims it's done, items remaining on stack: def at line 46,
      > column 34 in file [FILENAME]
      >
      > Perhaps it could say, "Missing '#end def'?"
      >
      > I'm a fan of always closing directives explicitly, but I thought
      > Cheetah implicitly closed directives at the end of the template or end
      > of a #def.
      >
      > --
      > Mike Orr <sluggoster@...>
      > (mso@... address is semi-reliable)
      >
      >
      > -------------------------------------------------------
      > This SF.net email is sponsored by: Splunk Inc. Do you grep through log
      > files for problems? Stop! Download the new AJAX search engine that makes
      > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
      > http://ads.osdn.com/?ad_idv37&alloc_id865&op=Click
      > _______________________________________________
      > Cheetahtemplate-discuss mailing list
      > Cheetahtemplate-discuss@...
      > https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss


      -------------------------------------------------------
      This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
      for problems? Stop! Download the new AJAX search engine that makes
      searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
      http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
      _______________________________________________
      Cheetahtemplate-discuss mailing list
      Cheetahtemplate-discuss@...
      https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
    Your message has been successfully submitted and would be delivered to recipients shortly.