First:
While looking for a better JSON editor - I installed this plugin:- Eclipse JSON Editor Plugin
- It appears that when this plugin is installed - JSON Schema Validation (i.e. after registering the file pattern and schema URL via Window > Preferences > JSON > JSON Catalog) no longer works.
- I repeated this test several times, by uninstalling the plugin - confirming that Schema Validation worked - and then re-installing the plugin and confirming that Schema Validation no longer worked.
- I did not see any errors being logged to the Eclipse log file.
- Tested with Java JDK 12, on a Windows 10 laptop
"Blocks JSON Schema Validation in Eclipse v4.11 (release 2019-03)"
Second:
While experimenting with the JSON Schema Validation capabilities of the latest Eclipse release (v4.11, 2019-03) - I noted an error in the log (see my stackoverflow submission) - even though validation appeared to be working.- relequestual replied soon after: "JSON Schema core dev here. Yeah this looks fine in terms of JSON Schema. No idea why an error is being throw"
- "UnsupportedOperationException: Not a string: {"type":"string","format":"uri-reference"} thrown by JsonValue.java"
- https://bugs.eclipse.org/bugs/show_bug.cgi?id=546541
- (see my follow-up bug comments for additional information I found)
Subsequently:
- By changing the @schema string value from
- "$schema": "http://json-schema.org/draft-07/schema#",
- To:
- "$schema": "http://json-schema.org/draft-04/schema#",
- It appears that the exception is no longer thrown.
- However, when I change the string to either of the following:
- "$schema": "http://json-schema.org/draft-05/schema#",
- or
- "$schema": "http://json-schema.org/draft-06/schema#",
- ....a different error messages shows in the log - with a different exception is thrown.
References:
- http://www.eclipse.org/webtools/
- http://git.eclipse.org/c/?q=webtools
- http://git.eclipse.org/c/sourceediting/webtools.sourceediting.git/
- http://git.eclipse.org/c/sourceediting/webtools.sourceediting.git/tree/
- https://git.eclipse.org/c/sourceediting/webtools.sourceediting.git/tree/json/bundles/org.eclipse.json/src/org/eclipse/json/provisonnal/com/eclipsesource/json
- https://git.eclipse.org/c/sourceediting/webtools.sourceediting.git/tree/json/bundles/org.eclipse.json/src/org/eclipse/json/provisonnal/com/eclipsesource/json/JsonValue.java
Observation:
There are quite a few open bugs within the Eclipse WTP Source Editing and wst.json component - that have not been addressed in years...
No comments:
Post a Comment