I wanted to bump jsoup in bb (which is now built in) and it runs hickory tests as part of CI: those failed. I now tried bumping jsoup directly in hickory, which also fails the tests. Branch here: https://github.com/clj-commons/hickory/tree/bump-jsoup I'll try to do some digging what exactly is the difference.
Woo. Thank you!
Ah good, the author of Jsoup reverted the backward incompatible change :) https://github.com/jhy/jsoup/commit/ed23a9a458bb0674a83f6c63e2bd5b7492fead09
Now wait for 1.19.1 to be released
It seems parsing the doctype is off:
user=> (h/as-hiccup (h/parse "\n\n<a></a>"))
("" "\n\n" [:html {} [:head {}] [:body {} [:a {}]]])This looks ok though:
user=> (h/parse "\n\n<a></a>")
#object[org.jsoup.nodes.Document 0x6b00ad9 "\n<html>\n <head></head>\n <body>\n <a></a>\n </body>\n</html>"]Found the issue.
(.attr doc-type "name")
doesn't return anything anymore. I'll file an issue about thisAlright. I worked together with the author of Jsoup to preserve backward compatibility and I can confirm it worked when bumping Jsoup in hickory. Also tested this hickory change which babashka (with bumped Jsoup), thus confirming stuff works with GraalVM native-image. So I guess it's ready to be merged (and released)
cc @slipset
I’ll look into merging releasing tomorrow?
Sure 👍 thanks 🙏
Mind linking to the PR so I don’t mess up?
yeap
Normally I use the squash feature of Github to make just one merged commit, but if you want me to squash manually or something, just let me know
I normally squash/merge
hi, don’t know if you’ve seen it but I’m getting a reflection warning since bumping hickory to the latest:
Reflection warning, hickory/core.clj:151:3 - call to static method parse on org.jsoup.Jsoup can't be resolved (argument types: unknown).
should it be type-hinted to String or would that cause problems? Of course, I can also ignore 🙂
let's see
The method is polymorphic. I think I now remember why I had extra set warn-on-reflection around this to disable it specifically for this call https://jsoup.org/apidocs/org/jsoup/Jsoup.html
let me add that back. I removed it shortly before submitting the PR
https://github.com/clj-commons/hickory/pull/92 cc @slipset for review + merge
originally there was no warn-on-reflection at all, I added the top one as well in the previous PR
Merged. new release on its way out 0.7.7
Thank you both!
No worries, thanks for reporting
awesome, thanks!
My pleasure!