http4s / http4s-scala-xml-1

Backport of http4s-scala-xml to scala-xml-1.0
Apache License 2.0
0 stars 1 forks source link

Move package to org.http4s.scalaxml1 #1

Closed rossabaker closed 2 years ago

rossabaker commented 2 years ago

We don't want it to clash with http4s-scala-xml.

Should probably also move the source directory, but that matters less.

sjenna commented 2 years ago

Thinking about this more...making the package name different makes my use case harder. Twirl and Refined, among others, currently cross build with scala-xml 1 or 2 depending on the Scala version. To cross build with this change, there will need to be scala_2- and scala_3-specific consumer code. Using this and http4s-scala-xml would cause the diamond problem all over again anyway. Can we back off on this change?

rossabaker commented 2 years ago

You're right about the diamond. I was thinking about being able to run both http4s-scala-xml, but they'd both point to scala-xml, one incompatibly.

I generally don't like to publish the same fully qualified class name under two different Maven artifacts, because then you get classloader roulette whenever both jars end up on the classpath. But if that happens, anything that uses this package is in trouble, because the scala-xml coordinates didn't change, and scala-xml-2 will (barring weird build tricks) have evicted scala-xml-1.

Yeah, I'm good with a revert here.