Fixes #16491: Port Rudder to Scala 2.13 #2699
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
https://issues.rudder.io/issues/16491
There is a lot of little things, only one tricky, so start by that one:
In scala.xml,
Node ++ Node
leads toSeq[Node]
in place ofNodeSeq
. There is nothing special for method awaitingNodeSeq
because there's an implicit conversion, but when a method acceptsSeq[A]
, it keeps the former. This is a problem for lift#>
which accept bothSeq[A]
etNodeSeq
with different semantic. OnSeq[A]
, it applies the mapping on allA
, else it applies one wholeNodeSeq
. So we need to force everything toNodeSeq
to be sure.Other things:
Timestamp
now).toSeq
mapValues
andfilterKey
are now method onview
, which has a different type to make explicit when there is a view. So we must force its evaluation withtoMap
afterward.toString
before+
(thing not coerced to string automatically by default, which is a big win against silly errors)