title: Cannot render an attribute that is not a string, toString returns: null ERROR in SPRING MVC
body: <p>I am trying to create a generic error handler for my spring mvc project by following this tutorial: <a href="http://www.mkyong.com/spring-mvc/spring-mvc-exceptionhandler-example/" rel="nofollow">http://www.mkyong.com/spring-mvc/spring-mvc-exceptionhandler-example/</a></p>
  
  <p>But In my project, I am using tiles-defs and I am getting this error when I access the error page in the browser:</p>
  
  <pre><code>org.apache.tiles.request.render.CannotRenderException: Cannot render an attribute that is not a string, toString returns: null
  at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:255)
  at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:397)
  at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:238)
  at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:221)
  at org.apache.tiles.renderer.DefinitionRenderer.render(DefinitionRenderer.java:59)
  at org.springframework.web.servlet.view.tiles3.TilesView.renderMergedOutputModel(TilesView.java:114)
  at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:267)
  at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1217)
  at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1005)
  at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:952)
  at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:870)
  at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:961)
  at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:852)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
  at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:837)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
  at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
  </code></pre>
  
  <p>Here is my tiles-defs configuration:</p>
  
  <pre><code>    &lt;definition name="/error/generic_error"&gt;
      &lt;put-attribute name="body" value="/WEB-INF/views/error/generic_error.jsp" /&gt;
      &lt;put-attribute name="browserTitle" value="Error Screen" /&gt;
      &lt;/definition&gt;
  </code></pre>
  
  <p>I can't find the cause nor the solution for this problem so any help would be much appreciated.</p>