WebCuratorTool / webcurator

The root of the webcurator tool project, containing all modules needed to run a fully functional webcurator tool.
Apache License 2.0
2 stars 1 forks source link

Direct not using 'scope' when adding profile leads to errors #91

Open Meneer-de-Bruin opened 1 year ago

Meneer-de-Bruin commented 1 year ago

Adding a new profile and not using the 'Scope' tab leads to 'Could not launch job - Fatal InitializationException' when harvesting.

Problem When adding a new profile a copy of the standard WCT profile is made. The standard WCT profile is not valid as 'Contact URL' is not filled with a valid link, but the text : 'ENTER_AN_HTTP(S)://_URL_WITH_CONTACT_INFO_FOR_WEBMASTERS_AFFECTED_BY_YOUR_CRAWL'

When you do not give a valid http link in the 'Scope' tab the follwing error is given: 'The following validation errors have occured.

Invalid Contact URL'

This is the correct behaviour. However if you only fill in the 'General' tab (name/description) and then click 'save' no error message is given and the profile can be used as normal. However the harvest itself will throw the following error: 'Could not launch job - Fatal InitializationException'. Which is (also) correct, but not expected behaviour as the profile was added without error message.

Also when a profile is added/changed a timestamp is set in the bean 'simpleOverrides'., e.g.: #Tue Jan 17 09:51:56 CET 2023. When directly saving form the 'General' tab this is not done.

Workaround 1-Always use the 'Scope' tab. This will always validate the profile. 2-Make your own valid standard profile (copy to webcurator-webapp.war/WEB-INF/classes/defaultH3Profile.cxml). This is always a valid profile so validation is irrelevant. This workaround does not solve the timestamp issue. However we see this as minor problem.

Possible solution Even if the 'Scope' tab is not used the profile must always be checked on clicking the 'save' tab. The error message must be shown on the tab where the user is. And preferably there must be an indication on which profile tab the error can be resolved.

Also the timestamp should always be set in the bean 'simpleOverrides'.