You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by "Nathan Bubna (JIRA)" <de...@velocity.apache.org> on 2008/12/09 20:13:44 UTC

[jira] Resolved: (VELOCITY-654) Fix correct template name reporting, enhance error logging information

     [ https://issues.apache.org/jira/browse/VELOCITY-654?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Nathan Bubna resolved VELOCITY-654.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 1.7
                   1.6.1

I went ahead and checked it in, so we can call this fixed.  If it turns out some of those error logs were redundant let me know and i'll drop them.

> Fix correct template name reporting, enhance error logging information
> ----------------------------------------------------------------------
>
>                 Key: VELOCITY-654
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-654
>             Project: Velocity
>          Issue Type: Improvement
>          Components: Engine
>    Affects Versions: 1.6.1
>            Reporter: Byron Foster
>             Fix For: 1.6.1, 1.7
>
>         Attachments: 654.patch, 654_2.patch, patch.txt
>
>
> Fix template name reporting for #include and #parse if an exception occurs.   Error reporting in Velocity tends to use context.getTemplateName() which is intended for scoping information, and does not always provide the template name containing the node or directive that generates an error.  This adds a templateName field to the Directive object and assigns it on creation, if a template name is available.
> Also added template and location info when logging errors thrown from #parse.  This compliments the pseudo-stack trace that is already logged to error for macros.  So, now a complete trace is logged to error of the macro and template layers with template name and location. Yea!

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org