tag:help-archives.hannonhill.com,2010-02-09:/discussions/bug-reports/2939-null-pointer-exception-when-submitting-a-templateCascade CMS: Discussion 2017-11-14T22:12:57Ztag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T12:39:09Z2016-06-24T14:31:42ZNull pointer exception when submitting a template<div><p>I currently have a template, on my local instance of hannon
hill. 7.14.2. I just restarted the server this morning, thinking
that might fix the problem but no. We did just recently upgrade
from 7.12.x. I am attaching the log.</p>
<p>Starting this morning, every time I try to submit an edit to a
template, I get the following error:<br>
Error<br>
Jun 24, 2016 8:35 AM<br>
An error occurred: java.lang.NullPointerException<br>
You may choose to retry the operation. If the problem persists,
please contact a system administrator.<br>
The error has been logged to the system console.<br>
Home</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T12:42:12Z2016-06-24T14:31:42ZNull pointer exception when submitting a template<div><p>other assets on the site allow me to submit, and on other sites
as well.</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T14:58:28Z2016-06-24T14:58:28ZNull pointer exception when submitting a template<div><p>Hi,</p>
<p>Thanks for attaching that log file. When you have a moment, can
you attach a file containing the contents of the Template you're
attempting to submit? Also, before you submit this Template, can
you tell me which Advanced Options are currently checked in your
instance (and whether un-checking any of those seem to change the
outcome)?</p>
<p>I'll do some testing locally once I have a copy of your
Template.</p>
<p>Thanks</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T15:08:40Z2016-06-24T15:08:40ZNull pointer exception when submitting a template<div><p>here is the file of the template.</p>
<p>the only option that is checked, is "Broken Links"</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T15:30:33Z2016-06-24T15:30:33ZNull pointer exception when submitting a template<div><p>Thanks for attaching that. It seems like this is tied to
something with the Broken Link check when you submit. Can you
verify that if you disable that check, you're able to submit the
Template?</p>
<p>I'll have to take a closer look at this to see what the
underlying issue is with the link checking that is causing this
NPE.</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T15:52:48Z2016-06-24T15:52:48ZNull pointer exception when submitting a template<div><p>yes, if i uncheck the broken links option I am able to submit
the changes.</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-24T17:06:24Z2016-06-24T17:06:24ZNull pointer exception when submitting a template<div><p>Thanks for confirming. Once I have the chance to debug this I'll
let you know.</p>
<p>It sounds as though you should be OK in the meantime by
un-checking that option any time you need to submit this particular
Template.</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-28T11:57:25Z2016-06-28T11:57:25ZNull pointer exception when submitting a template<div><p>any update on this issue?</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-06-28T14:08:01Z2016-06-28T14:08:01ZNull pointer exception when submitting a template<div><p>Just had a chance to look into this a bit further. I believe the
problem is this link:<br></p>
<pre>
<code><link href="[system-asset:configuration=CSS]/_assets/css/theme?raw[/system-asset:configuration]</code>
</pre>
Can you confirm that the path to this <code>theme</code> page is
correct? So far, I've only been able to replicate this NPE when I
attempt to point to an asset that doesn't exist.
<p>Let me know. Regardless, this does appear to be some sort of bug
with the way the application is handling path rewriting within
these types of tags.</p>
<p>Thanks</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-07-18T22:15:39Z2016-07-18T22:15:39ZNull pointer exception when submitting a template<div><p>Hi,</p>
<p>Just wanted to make sure you saw <a href="http://help.hannonhill.com/discussions/bug-reports/2939-null-pointer-exception-when-submitting-a-template#comment_40212029">
my previous comment</a>. Let me know if what I mentioned appears to
be the case.</p>
<p>Thanks</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-07-19T12:44:52Z2016-07-19T12:44:52ZNull pointer exception when submitting a template<div><p>The theme.css file isn't in that site.</p>
<p>Here's the way this is setup.</p>
<p>Those themes are in a Common site (that shares
themes/formats/etc with multiple properties) called UM Common
Assets.</p>
<p>The sites that actually use those themes are in different
"sites" and they do have that css file present.</p>
<p>Should I just create an empty theme.css in the UM Common Assets
folder to resolve this until the bug is fixed.</p></div>ediegotag:help-archives.hannonhill.com,2010-02-09:Comment/401878602016-07-19T18:31:50Z2016-07-19T18:31:50ZNull pointer exception when submitting a template<div><p>The bug appears to be related to the path rewriting when the
link is surrounded with these particular tags.Since this asset
doesn't exist, rather than prompting you to change it to a valid
link, it's throwing a NPE. Even if this were corrected, you'd still
run into issues here since this particular asset doesn't actually
live in the Site where the Template resides. In terms of the setup,
since you mentioned that the Sites using this Template <em>do</em>
have that file present, what happens if you try using 'asset local'
links?:<br></p>
<pre>
<code><link href="[system-asset:local]/_assets/css/theme?raw[/system-asset:local]</code>
</pre>
One downside here is that I don't know if you'll be able to point
to a specific Output in addition to using the 'asset local'
notation, so this may not work if your theme Page has multiple
outputs.</div>Tim