From 1902755670200e94f2283e255d0264794f3e4b6a Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Wed, 21 Feb 2024 18:53:44 -0800 Subject: [PATCH 1/5] add Scala 2.12.19 and 2.13.13 --- .github/workflows/validate.yml | 2 ++ build.sbt | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index eac21bd..c1839f0 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -28,6 +28,7 @@ jobs: - 2.12.16 - 2.12.17 - 2.12.18 + - 2.12.19 - 2.13.0 - 2.13.1 - 2.13.2 @@ -41,6 +42,7 @@ jobs: - 2.13.10 - 2.13.11 - 2.13.12 + - 2.13.13 java: [8, 11, 17] steps: diff --git a/build.sbt b/build.sbt index 2950f4d..db1a6ca 100644 --- a/build.sbt +++ b/build.sbt @@ -46,8 +46,8 @@ lazy val defaults = Seq( sonatypeProfileName := "com.typesafe", scalaVersion := crossScalaVersions.value.last, crossScalaVersions := { - val supportedScala212Versions = (5 to 18).map(p => s"2.12.$p") - val supportedScala213Versions = (0 to 12).map(p => s"2.13.$p") + val supportedScala212Versions = (5 to 19).map(p => s"2.12.$p") + val supportedScala213Versions = (0 to 13).map(p => s"2.13.$p") supportedScala212Versions ++ supportedScala213Versions }, scalaMajorVersion := CrossVersion.partialVersion(scalaVersion.value).get._2.toInt, From b650858121cc6b8bb066212603bba9866570a907 Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Wed, 21 Feb 2024 18:54:01 -0800 Subject: [PATCH 2/5] add JDK 21 to CI matrix --- .github/workflows/validate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index c1839f0..d64eb45 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -43,7 +43,7 @@ jobs: - 2.13.11 - 2.13.12 - 2.13.13 - java: [8, 11, 17] + java: [8, 11, 17, 21] steps: - name: Checkout From 82d2aa48116086111bbad04a2d40b97aa4b212db Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Wed, 21 Feb 2024 18:54:08 -0800 Subject: [PATCH 3/5] copyright 2024 --- LICENSE | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LICENSE b/LICENSE index f854a53..7b092c9 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ This software is licensed under the Apache 2 license, quoted below. -Copyright 2009-2018 Lightbend Inc. [http://www.lightbend.com] +Copyright 2009-2024 Lightbend Inc. [http://www.lightbend.com] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of From d370b0245894d21224be8487fc8bd474ea8e4017 Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Wed, 21 Feb 2024 18:54:31 -0800 Subject: [PATCH 4/5] add patch files for eventual 2.12.20, 2.13.14 Scala 2 community build needs these now --- src/test/resources/patches/2.12.20.patch | 71 ++++++ src/test/resources/patches/2.13.14.patch | 261 +++++++++++++++++++++++ 2 files changed, 332 insertions(+) create mode 100644 src/test/resources/patches/2.12.20.patch create mode 100644 src/test/resources/patches/2.13.14.patch diff --git a/src/test/resources/patches/2.12.20.patch b/src/test/resources/patches/2.12.20.patch new file mode 100644 index 0000000..e812eb8 --- /dev/null +++ b/src/test/resources/patches/2.12.20.patch @@ -0,0 +1,71 @@ +--- target/expected_output/basic/akka/rk/buh/is/it/A.java ++++ target/expected_output/basic/akka/rk/buh/is/it/A.java +@@ -48,13 +48,13 @@ + public class NonStatic { + public NonStatic () { throw new RuntimeException(); } + } ++ public akka.rk.buh.is.it.A.D$.E$ E () { throw new RuntimeException(); } + public D$ () { throw new RuntimeException(); } + /** + * def A.D.math + * @return (undocumented) + */ + public long math () { throw new RuntimeException(); } +- public akka.rk.buh.is.it.A.D$.E$ E () { throw new RuntimeException(); } + } + /** + * class A.B +@@ -103,8 +103,8 @@ + * class A.C + */ + static public class C1 { +- public C1 () { throw new RuntimeException(); } + public akka.rk.buh.is.it.A.C1$C1$ C1 () { throw new RuntimeException(); } ++ public C1 () { throw new RuntimeException(); } + } + /** + * object C1 +@@ -142,6 +142,11 @@ + static public java.lang.String stattic () { throw new RuntimeException(); } + static public java.lang.Object x () { throw new RuntimeException(); } + /** ++ * Accessor for nested Scala object ++ * @return (undocumented) ++ */ ++ public akka.rk.buh.is.it.A.D$ D () { throw new RuntimeException(); } ++ /** + * varargs + * @param s (undocumented) + * @return (undocumented) +@@ -214,9 +219,4 @@ + */ + public int testthrows () throws java.lang.IllegalArgumentException, java.lang.NullPointerException { throw new RuntimeException(); } + public scala.runtime.Null$ getNull () { throw new RuntimeException(); } +- /** +- * Accessor for nested Scala object +- * @return (undocumented) +- */ +- public akka.rk.buh.is.it.A.D$ D () { throw new RuntimeException(); } + } +--- target/expected_output/basic/akka/actor/dsl/Inbox.java 2018-12-13 15:51:52.473679518 +0100 ++++ target/expected_output/basic/akka/actor/dsl/Inbox.java 2018-12-13 15:51:51.473673128 +0100 +@@ -2,5 +2,6 @@ + public interface Inbox { + public interface InboxExtension { + public int DSLInboxQueueSize () ; ++ public void akka$actor$dsl$Inbox$InboxExtension$_setter_$DSLInboxQueueSize_$eq (int x$1) ; + } + } +--- target/expected_output/basic/akka/persistence/testkit/EventStorage.java 2020-03-23 16:04:03.313049968 +0100 ++++ target/expected_output/basic/akka/persistence/testkit/EventStorage.java 2020-03-23 16:04:03.313049968 +0100 +@@ -5,7 +5,9 @@ + * Static reference to the singleton instance of this Scala object. + */ + public static final JournalPolicies$ MODULE$ = null; ++ public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll$ PassAll () { throw new RuntimeException(); } + public JournalPolicies$ () { throw new RuntimeException(); } + } +- public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll$ DefaultPolicy () ; ++ public void akka$persistence$testkit$EventStorage$_setter_$DefaultPolicy_$eq (akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll x$1) ; ++ public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll DefaultPolicy () ; + } diff --git a/src/test/resources/patches/2.13.14.patch b/src/test/resources/patches/2.13.14.patch new file mode 100644 index 0000000..df6c303 --- /dev/null +++ b/src/test/resources/patches/2.13.14.patch @@ -0,0 +1,261 @@ +--- target/expected_output/basic/akka/actor/Identify$.java ++++ target/expected_output/basic/akka/actor/Identify$.java +@@ -1,5 +1,5 @@ + package akka.actor; +-public class Identify$ extends scala.runtime.AbstractFunction1 implements scala.Serializable { ++public class Identify$ extends scala.runtime.AbstractFunction1 implements java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/actor/Identify.java ++++ target/expected_output/basic/akka/actor/Identify.java +@@ -1,5 +1,5 @@ + package akka.actor; +-public final class Identify implements scala.Product, scala.Serializable { ++public final class Identify implements scala.Product, java.io.Serializable { + static public akka.actor.Identify apply (Object messageId) { throw new RuntimeException(); } + static public scala.Option unapply (akka.actor.Identify x$0) { throw new RuntimeException(); } + public Object messageId () { throw new RuntimeException(); } +@@ -13,6 +13,7 @@ + public Object productElement (int x$1) { throw new RuntimeException(); } + public scala.collection.Iterator productIterator () { throw new RuntimeException(); } + public boolean canEqual (Object x$1) { throw new RuntimeException(); } ++ public java.lang.String productElementName (int x$1) { throw new RuntimeException(); } + public int hashCode () { throw new RuntimeException(); } + public java.lang.String toString () { throw new RuntimeException(); } + public boolean equals (Object x$1) { throw new RuntimeException(); } +--- target/expected_output/basic/akka/actor/dsl/Inbox.java ++++ target/expected_output/basic/akka/actor/dsl/Inbox.java +@@ -2,5 +2,6 @@ + public interface Inbox { + public interface InboxExtension { + public int DSLInboxQueueSize () ; ++ public void akka$actor$dsl$Inbox$InboxExtension$_setter_$DSLInboxQueueSize_$eq (int x$1) ; + } + } +--- target/expected_output/basic/akka/actor/typed/DispatcherSelector$.java ++++ target/expected_output/basic/akka/actor/typed/DispatcherSelector$.java +@@ -1,5 +1,5 @@ + package akka.actor.typed; +-public class DispatcherSelector$ implements scala.Serializable { ++public class DispatcherSelector$ implements java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/actor/typed/Props.java ++++ target/expected_output/basic/akka/actor/typed/Props.java +@@ -1,5 +1,5 @@ + package akka.actor.typed; +-public abstract class Props implements scala.Product, scala.Serializable { ++public abstract class Props implements scala.Product, java.io.Serializable { + public Props () { throw new RuntimeException(); } + public abstract akka.actor.typed.Props next () ; + } +--- target/expected_output/basic/akka/persistence/testkit/EventStorage.java ++++ target/expected_output/basic/akka/persistence/testkit/EventStorage.java +@@ -5,7 +5,9 @@ + * Static reference to the singleton instance of this Scala object. + */ + public static final JournalPolicies$ MODULE$ = null; ++ public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll$ PassAll () { throw new RuntimeException(); } + public JournalPolicies$ () { throw new RuntimeException(); } + } +- public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll$ DefaultPolicy () ; ++ public void akka$persistence$testkit$EventStorage$_setter_$DefaultPolicy_$eq (akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll x$1) ; ++ public akka.persistence.testkit.ProcessingPolicy.DefaultPolicies.PassAll DefaultPolicy () ; + } +--- target/expected_output/basic/akka/persistence/testkit/ProcessingPolicy.java ++++ target/expected_output/basic/akka/persistence/testkit/ProcessingPolicy.java +@@ -10,8 +10,10 @@ + static public int hashCode () { throw new RuntimeException(); } + static public java.lang.String toString () { throw new RuntimeException(); } + static public abstract boolean equals (Object that) ; ++ static public java.lang.String productElementName (int n) { throw new RuntimeException(); } ++ static public scala.collection.Iterator productElementNames () { throw new RuntimeException(); } + } +- public class PassAll$ implements akka.persistence.testkit.ProcessingPolicy, scala.Product, scala.Serializable { ++ public class PassAll$ implements akka.persistence.testkit.ProcessingPolicy, scala.Product, java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/rk/buh/is/it/A.java ++++ target/expected_output/basic/akka/rk/buh/is/it/A.java +@@ -35,7 +35,7 @@ + /** + * object A.D + */ +- public class D$ implements scala.Serializable { ++ public class D$ implements java.io.Serializable { + /** + * And a nested object. + */ +@@ -48,13 +48,13 @@ + public class NonStatic { + public NonStatic () { throw new RuntimeException(); } + } ++ public akka.rk.buh.is.it.A.D$.E$ E () { throw new RuntimeException(); } + public D$ () { throw new RuntimeException(); } + /** + * def A.D.math + * @return (undocumented) + */ + public long math () { throw new RuntimeException(); } +- public akka.rk.buh.is.it.A.D$.E$ E () { throw new RuntimeException(); } + } + /** + * class A.B +@@ -76,7 +76,7 @@ + * def b(args: java.lang.String*): Unit + * @param args (undocumented) + */ +- public void b (scala.collection.Seq args) { throw new RuntimeException(); } ++ public void b (scala.collection.immutable.Seq args) { throw new RuntimeException(); } + public java.lang.String d (java.lang.String a, akka.rk.buh.is.it.X b) { throw new RuntimeException(); } + } + public class C implements akka.rk.buh.is.it.X { +@@ -103,8 +103,8 @@ + * class A.C + */ + static public class C1 { +- public C1 () { throw new RuntimeException(); } + public akka.rk.buh.is.it.A.C1$C1$ C1 () { throw new RuntimeException(); } ++ public C1 () { throw new RuntimeException(); } + } + /** + * object C1 +@@ -142,6 +142,11 @@ + static public java.lang.String stattic () { throw new RuntimeException(); } + static public java.lang.Object x () { throw new RuntimeException(); } + /** ++ * Accessor for nested Scala object ++ * @return (undocumented) ++ */ ++ public akka.rk.buh.is.it.A.D$ D () { throw new RuntimeException(); } ++ /** + * varargs + * @param s (undocumented) + * @return (undocumented) +@@ -207,16 +212,11 @@ + * @param s (undocumented) + * @return (undocumented) + */ +- public int hello (scala.collection.Seq s) { throw new RuntimeException(); } ++ public int hello (scala.collection.immutable.Seq s) { throw new RuntimeException(); } + /** + * throws + * @return (undocumented) + */ + public int testthrows () throws java.lang.IllegalArgumentException, java.lang.NullPointerException { throw new RuntimeException(); } + public scala.runtime.Null$ getNull () { throw new RuntimeException(); } +- /** +- * Accessor for nested Scala object +- * @return (undocumented) +- */ +- public akka.rk.buh.is.it.A.D$ D () { throw new RuntimeException(); } + } +--- target/expected_output/basic/akka/rk/buh/is/it/Blarb.java ++++ target/expected_output/basic/akka/rk/buh/is/it/Blarb.java +@@ -4,8 +3,7 @@ + * I am an object. I have no class. + */ + public class Blarb { +- // no position +- static public class A$ implements akka.rk.buh.is.it.Blarb.Fuz, scala.Product, scala.Serializable { ++ static public class A$ implements akka.rk.buh.is.it.Blarb.Fuz, scala.Product, java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +@@ -18,9 +16,8 @@ + public boolean canEqual (Object x$1) { throw new RuntimeException(); } + public int hashCode () { throw new RuntimeException(); } + public java.lang.String toString () { throw new RuntimeException(); } +- private java.lang.Object readResolve () { throw new RuntimeException(); } + } +- static public class B implements akka.rk.buh.is.it.Blarb.Fuz, scala.Product, scala.Serializable { ++ static public class B implements akka.rk.buh.is.it.Blarb.Fuz, scala.Product, java.io.Serializable { + public java.lang.String x () { throw new RuntimeException(); } + // not preceding + public B (java.lang.String x) { throw new RuntimeException(); } +@@ -32,12 +29,12 @@ + public Object productElement (int x$1) { throw new RuntimeException(); } + public scala.collection.Iterator productIterator () { throw new RuntimeException(); } + public boolean canEqual (Object x$1) { throw new RuntimeException(); } ++ public java.lang.String productElementName (int x$1) { throw new RuntimeException(); } + public int hashCode () { throw new RuntimeException(); } + public java.lang.String toString () { throw new RuntimeException(); } + public boolean equals (Object x$1) { throw new RuntimeException(); } + } +- // no position +- static public class B$ extends scala.runtime.AbstractFunction1 implements scala.Serializable { ++ static public class B$ extends scala.runtime.AbstractFunction1 implements java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/rk/buh/is/it/CompressionProtocol.java ++++ target/expected_output/basic/akka/rk/buh/is/it/CompressionProtocol.java +@@ -5,7 +5,7 @@ + * Static reference to the singleton instance of this Scala object. + */ + public static final Events$ MODULE$ = null; +- public final class HeavyHitterDetected implements akka.rk.buh.is.it.CompressionProtocol.Events.Event, scala.Product, scala.Serializable { ++ public final class HeavyHitterDetected implements akka.rk.buh.is.it.CompressionProtocol.Events.Event, scala.Product, java.io.Serializable { + static public akka.rk.buh.is.it.CompressionProtocol.Events.HeavyHitterDetected apply (Object key, int id, long count) { throw new RuntimeException(); } + static public scala.Option> unapply (akka.rk.buh.is.it.CompressionProtocol.Events.HeavyHitterDetected x$0) { throw new RuntimeException(); } + public Object key () { throw new RuntimeException(); } +@@ -24,11 +24,12 @@ + public Object productElement (int x$1) { throw new RuntimeException(); } + public scala.collection.Iterator productIterator () { throw new RuntimeException(); } + public boolean canEqual (Object x$1) { throw new RuntimeException(); } ++ public java.lang.String productElementName (int x$1) { throw new RuntimeException(); } + public int hashCode () { throw new RuntimeException(); } + public java.lang.String toString () { throw new RuntimeException(); } + public boolean equals (Object x$1) { throw new RuntimeException(); } + } +- public class HeavyHitterDetected$ extends scala.runtime.AbstractFunction3 implements scala.Serializable { ++ public class HeavyHitterDetected$ extends scala.runtime.AbstractFunction3 implements java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/rk/buh/is/it/EWMA$.java ++++ target/expected_output/basic/akka/rk/buh/is/it/EWMA$.java +@@ -1,6 +1,5 @@ + package akka.rk.buh.is.it; +-// no position +-public class EWMA$ implements scala.Serializable { ++public class EWMA$ implements java.io.Serializable { + /** + * Static reference to the singleton instance of this Scala object. + */ +--- target/expected_output/basic/akka/rk/buh/is/it/EWMA.java ++++ target/expected_output/basic/akka/rk/buh/is/it/EWMA.java +@@ -18,7 +18,7 @@ + * This value is always used as the previous EWMA to calculate the new EWMA. + *

+ */ +-public final class EWMA implements scala.Product, scala.Serializable { ++public final class EWMA implements scala.Product, java.io.Serializable { + // not preceding + static public akka.rk.buh.is.it.EWMA apply (double value, double alpha) { throw new RuntimeException(); } + static public scala.Option> unapply (akka.rk.buh.is.it.EWMA x$0) { throw new RuntimeException(); } +@@ -44,6 +44,7 @@ + public Object productElement (int x$1) { throw new RuntimeException(); } + public scala.collection.Iterator productIterator () { throw new RuntimeException(); } + public boolean canEqual (Object x$1) { throw new RuntimeException(); } ++ public java.lang.String productElementName (int x$1) { throw new RuntimeException(); } + public int hashCode () { throw new RuntimeException(); } + public java.lang.String toString () { throw new RuntimeException(); } + public boolean equals (Object x$1) { throw new RuntimeException(); } +--- target/expected_output/basic/akka/rk/buh/is/it/Status$Status.java ++++ target/expected_output/basic/akka/rk/buh/is/it/Status$Status.java +@@ -1,3 +1,3 @@ + package akka.rk.buh.is.it; +-public interface Status$Status extends scala.Serializable { ++public interface Status$Status extends java.io.Serializable { + } +--- target/expected_output/basic/akka/rk/buh/is/it/X.java ++++ target/expected_output/basic/akka/rk/buh/is/it/X.java +@@ -1,3 +1,3 @@ + package akka.rk.buh.is.it; +-public interface X extends scala.Serializable, akka.rk.buh.is.it.Y { ++public interface X extends java.io.Serializable, akka.rk.buh.is.it.Y { + } From 4d2fde85e6d21795f1948f8598c3c2695de9d64b Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Wed, 21 Feb 2024 18:57:59 -0800 Subject: [PATCH 5/5] remove some ancient Scala versions --- .github/workflows/validate.yml | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index d64eb45..bdff6af 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -14,32 +14,8 @@ jobs: fail-fast: false matrix: scala: - - 2.12.5 - - 2.12.6 - - 2.12.7 - - 2.12.8 - - 2.12.9 - - 2.12.10 - - 2.12.11 - - 2.12.12 - - 2.12.13 - - 2.12.14 - - 2.12.15 - - 2.12.16 - - 2.12.17 - 2.12.18 - 2.12.19 - - 2.13.0 - - 2.13.1 - - 2.13.2 - - 2.13.3 - - 2.13.4 - - 2.13.5 - - 2.13.6 - - 2.13.7 - - 2.13.8 - - 2.13.9 - - 2.13.10 - 2.13.11 - 2.13.12 - 2.13.13