-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HTML parsing library for visualizations messes up divs #97
Comments
Per https://about.validator.nu/htmlparser/ we're on the latest released version (though they note they're behind on actual releases). |
A long-term solution would be to use an actual web browser, but as we recently learned this is blocked on Google App Engine (which runs Tiltyard) supporting Java 8. (Unless we split up GGP-Base into separate projects/jars as suggested in #91, in which case UI code could use Java 8 and core library code Java 7.) In lieu of that I'm trying out Jsoup as a replacement library. |
Jsoup seems to work, though there's more stuff involved in getting an input for Flying Saucer. I'll port this back from Alloy to GGP-Base at some point. |
Another possible solution: JxBrowser allows for embedding a web browser, and does not require Java 8 like the JavaFX browser approach. However, it is a very large and heavyweight dependency; it basically runs Chromium within the application. Another approach would be to run a servlet and (within the Java app) just provide a link to the actual visualization(s), which would be shown in a user's browser. |
In preparing games for the coming competition, I'm seeing several cases where visualization code like
turns into
This wreaks havoc with visualizations (I believe Hex is an example).
Debugging indicates this error is introduced by the "new HtmlDocumentBuilder().parse(is)" call in GameStateRenderer#renderImagefromGameXML. The input "xhtml" string is correct, the created dom object is incorrect.
The text was updated successfully, but these errors were encountered: