HughP / simal

Automatically exported from code.google.com/p/simal
0 stars 0 forks source link

Vague error message when showing defective project #393

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I created a project using the doapcreator, and it listed ok. But when I clicked 
to the detail page, I got this:

----
WicketMessage: Can't instantiate page using constructor public 
uk.ac.osswatch.simal.wicket.doap.ProjectDetailPage(org.apache.wicket.PageParamet
ers) and argument simalID = "prj111"

Root cause:

com.hp.hpl.jena.rdf.model.ResourceRequiredException: ""
     at com.hp.hpl.jena.rdf.model.impl.StatementBase.mustBeResource(StatementBase.java:137)
     at com.hp.hpl.jena.rdf.model.impl.StatementImpl.getResource(StatementImpl.java:83)
     at uk.ac.osswatch.simal.model.jena.Project.getDocuments(Project.java:261)
     at uk.ac.osswatch.simal.model.jena.Project.getHomepages(Project.java:109)
     at uk.ac.osswatch.simal.wicket.panel.project.EditProjectPanel$EditProjectForm.addLeftColumn(EditProjectPanel.java:205)
....
----

Since I can view other projects ok, I'm guessing that there's something about 
this particular one. But there's nothing in that error message which would help 
me track down what the problem is.

Original issue reported on code.google.com by Stevage on 23 Feb 2011 at 7:43

GoogleCodeExporter commented 9 years ago
In order to debug this we will need to know what data was entered. It looks 
like there is a problem with the Homepage value.

Do you have a copy of the RDF submitted by the form?

Do you know what the homepage value should have been?

Can you please use the SPARQL query tool (under the tools menu) to retrieve the 
RDF for this project and let us have a copy of that).

Original comment by ross.gardler on 23 Feb 2011 at 9:04

GoogleCodeExporter commented 9 years ago
I've done another test, with sensible values, and didn't get the error. So I 
assume that the rubbish values I entered passed the DOAPCreator validation, but 
couldn't be processed by Simal.

I entered this as a bug relating to error reporting because the actual test 
data was not important. I don't have the RDF. I don't speak SPARQL, and wasn't 
able to come up with a query that returned it. (If you're still interested, the 
query would need to return a project with a short name of "aoeu.com".) The 
homepage value was probably aoeu.com - from memory, I used that as the value 
for pretty much every field (and aoeu.com@aoeu.com for the email field).

Perhaps when exceptions like this get thrown, the whole RDF could be included 
in the output?

Original comment by Stevage on 24 Feb 2011 at 2:49

GoogleCodeExporter commented 9 years ago
In terms of figuring out the SPARQL you need to return a specific project 
instance you can make a request for the project detail page and then look in 
the logs - it tells you the SPARQL used.

I don't think it makes sense to dump the RDF when an exception is thrown since 
that's the RDF coming out, not the RDF going in. It doesn't really help us to 
debug things beyond what we get from the logs. Which in this case I can tell 
you the error was probably a null value in the projects home page.

However, without knowing for sure there is little we could do about this (of 
course we could try submitting an RDF with this problem and see what happens).

I'm closing this issue as won't fix since we can't reproduce it with certainty. 
The Logs appear to give plenty of information so I don't agree with the summary 
about "vague error message"

Original comment by ross.gardler on 7 Mar 2011 at 4:06