[ZPT] Re: [qg] FTP upload and DTML syntax errors

Richard Jones rjones@ekit-inc.com
Fri, 18 Jan 2002 09:05:00 +1100


[cross-posted to the Zope Page Templates list]
[ZPT'ers: quanta gold has support for Zope (FTP and DTML... no mention of 
when ZPT support will arrive _yet_)]

On Fri, 18 Jan 2002 01:25, Heiko Stoermer wrote:
> we discovered the following:
> - on editing a DTML document via FTP
> - put in a dtml syntax error
> - save it back with FTP
> - quanta says it has been saved - but it's not !
> This is the case because zope rejected the document as it contains syntax
> errors. The ZMI would give you a nice and clean error message, quanta
> simply fails.

There's not really a lot you can do here - FTP just isn't a good medium for 
this. I believe the FTP error will have a little information in it, but not a 
lot.

IIRC, Page Templates use a different mechanism whereby the upload will always 
succeed, and if there's a parse error the page will be "invalidated" with the 
error message in the start of the source. Attempts to view the page will 
result in an "errors during compilation" message.

I haven't had a chance to look further into it, but in my last job, I 
modified the standard error message so that the compilation error was 
displayed on page view - as long as the server was in debug mode. Haven't 
kept in touch with ZPT in the month between jobs though, so I don't know what 
the current state of ZPT is...


    Richard