Quande Ren created SLING-9669:
---------------------------------

             Summary: Should show jsp file  name when jsp has error of as <%@ 
page language="java" import="" errorPage="error.jsp"%>
                 Key: SLING-9669
                 URL: https://issues.apache.org/jira/browse/SLING-9669
             Project: Sling
          Issue Type: Improvement
          Components: Console
    Affects Versions: JSPC Maven Plugin 2.2.2
            Reporter: Quande Ren


I have many jsp files to compile, one of the jsp page has a line like this:

...

<%@ page language="java" import="" errorPage="error.jsp"%>

...

 

the import is supposed to have some value there.

 

when use sling jspc to compile it,  the error message come out like this:

 

org.apache.sling.scripting.jsp.jasper.JasperException: 
java.lang.RuntimeException: 
org.apache.sling.scripting.jsp.jasper.JasperException: Unable to compile class 
for JSP:

An error occurred at line: 6 in the generated java file
Syntax error on token "import", Name expected after this token

 

But it does not tell me which file has the problem.

 

I eventually found the file by going to the directory of target/classes/, open 
all the generated java files one by one and found the problem and fixed it.

 


import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import ;  --> here supposed to have something 
import java.util.*;

 

It will be much better if the sling jspc tells me which file has the problem.

 

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to