Skip to content
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

Configure cross version build for Scala 2.12 #437

Closed
jonas opened this issue Oct 26, 2016 · 18 comments
Closed

Configure cross version build for Scala 2.12 #437

jonas opened this issue Oct 26, 2016 · 18 comments
Assignees
Labels
t:build Issues that affect the build

Comments

@jonas
Copy link
Member

jonas commented Oct 26, 2016

Akka 2.4.11 was released for 2.12.0-RC2 so Akka HTTP should also provide artifacts for Scala 2.12.

@ktoso
Copy link
Member

ktoso commented Oct 26, 2016

Very true, let's make it ship for 12 on release :)
We checked 2.12.0-RC2 on Akka 2.4.11 and it works, so this should not run into any weird issues, just a matter of setting up dependencies.

@ktoso ktoso added this to the FIRST_STABLE milestone Oct 26, 2016
@ktoso ktoso added t:build Issues that affect the build 1 - triaged Tickets that are safe to pick up for contributing in terms of likeliness of being accepted labels Oct 26, 2016
@jonas
Copy link
Member Author

jonas commented Oct 31, 2016

@ktoso Were the tests run for 2.12? I am seeing several failures likely linked with differences between 2.11 and 2.12, like e.g.:

[info] DebuggingDirectivesSpec:
[info] The 'logRequest' directive
[info] - should produce a proper log message for incoming requests *** FAILED ***
[info]   "...none/none,ByteString[.ByteString1C]()),HttpProtocol(HTT..." did not equal "...none/none,ByteString[]()),HttpProtocol(HTT..." (DebuggingDirectivesSpec.scala:39)

jonas added a commit to jonas/akka-http that referenced this issue Oct 31, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- The fix for https://issues.scala-lang.org/browse/SI-9019 causes
  DebuggingDirectivesSpec to fail by printing `ByteString.ByteString1C`
  instead of `ByteString` in Scala 2.11.
@jonas
Copy link
Member Author

jonas commented Oct 31, 2016

OK, sanity restored.

@patriknw
Copy link
Member

There is also an issue with scaladoc due to sealed abstract class HttpCredentials.

We have many other sealed abstract class in the http-core model, but maybe it's only this HttpCredentials that is extended from java?

This was originally reported by @SethTisue in akka/akka#21543

@jrudolph
Copy link
Member

Interesting, I somehow missed the old issue. I'll have a look...

@jonas
Copy link
Member Author

jonas commented Oct 31, 2016

Does this issue affect publishing of the 2.12 artifacts or can we put it in a separate ticket and mark as a future improvement?

jonas added a commit to jonas/akka-http that referenced this issue Oct 31, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- DebuggingDirectivesSpec relied on ByteString.ByteString1C's `toString`
  which changed due to https://issues.scala-lang.org/browse/SI-9019.
jonas added a commit to jonas/akka-http that referenced this issue Oct 31, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- DebuggingDirectivesSpec relied on ByteString.ByteString1C's `toString`
  which changed due to https://issues.scala-lang.org/browse/SI-9019.
jonas added a commit to jonas/akka-http that referenced this issue Oct 31, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- DebuggingDirectivesSpec relied on ByteString.ByteString1C's `toString`
  which changed due to https://issues.scala-lang.org/browse/SI-9019.
jonas added a commit to jonas/akka-http that referenced this issue Oct 31, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- DebuggingDirectivesSpec relied on ByteString.ByteString1C's `toString`
  which changed due to https://issues.scala-lang.org/browse/SI-9019.
jrudolph added a commit that referenced this issue Nov 1, 2016
Cross compile to Scala 2.12.0-RC2 (#437)
@jrudolph
Copy link
Member

jrudolph commented Nov 1, 2016

Yes, we won't be able to release a docs artifact as long as this is not fixed.

We decided that removing the sealed modifier is ok and shouldn't break anything. It should be replaced by a comment that extending these classes with third-party implementations is not supported right now.

@ktoso ktoso added the 2 - pick next Used to mark issues which are next up in the queue to be worked on. The tag is non-binding label Nov 2, 2016
@ktoso
Copy link
Member

ktoso commented Nov 2, 2016

Just saw #447 (comment) so... are we ready to publish 2.12 or not yet? (not sure which comment was written first ;-))

@jonas
Copy link
Member Author

jonas commented Nov 2, 2016

We need to validate scaladoc generation for 2.12 and it would be nice to configure at least nightly builds for 2.12 unless we do that as part of the Travis ticket.

@wsargent
Copy link
Contributor

wsargent commented Nov 2, 2016

Play also has a dependency on akka-http playframework/playframework#6110

@ruippeixotog
Copy link

So, are there any updates about this? As more and more libraries release artifacts for 2.12.0, akka-http is starting to become the last blocker in many of the projects I work with.

Is there anything I can do to help? Thanks in advance for your effort on this :)

@adamw
Copy link

adamw commented Nov 12, 2016

@ruippeixotog There's 10.0.0-RC2 which is cross-built for 2.12 (see e.g. akka-http-session build). I don't know the timeline, but I suspect a final release to be available soon.

@ktoso
Copy link
Member

ktoso commented Nov 13, 2016

Yeah 10.0.0-RC2 is available, we didn't announce - will do so on this monday.
And I hope to release a stable as soon as we can (been trying to since last week).

Sorry for the wait, but we're very close.

@ktoso
Copy link
Member

ktoso commented Nov 13, 2016

This task is blocking the stable release for example: #517
So for Akka HTTP the thing that's slow is making the first stable release from the new repo, 2.12 we're ready (and did release 10.0.0-RC2 for it already).

jedrekn pushed a commit to jedrekn/akka-http that referenced this issue Nov 17, 2016
Fixes two tests to work with Scala 2.12:

 - SprayJsonPrettyMarshalSpec defined a trait inside a test scope, which
   resulted in a ClassFormatError:

   [info] docs.http.scaladsl.SprayJsonPrettyMarshalSpec *** ABORTED ***
   [info]   java.lang.ClassFormatError: Duplicate field name&signature in class file docs/http/scaladsl/SprayJsonPrettyMarshalSpec$MyJsonService$1
   [info]   at java.lang.ClassLoader.defineClass1(Native Method)

- DebuggingDirectivesSpec relied on ByteString.ByteString1C's `toString`
  which changed due to https://issues.scala-lang.org/browse/SI-9019.
jedrekn pushed a commit to jedrekn/akka-http that referenced this issue Nov 17, 2016
@ktoso
Copy link
Member

ktoso commented Nov 18, 2016

Cross building solved in #544
RC2 was already for 2.12.0, and so will 10.0.0 👍

@ktoso ktoso added 3 - in progress Someone is working on this ticket and removed 1 - triaged Tickets that are safe to pick up for contributing in terms of likeliness of being accepted 2 - pick next Used to mark issues which are next up in the queue to be worked on. The tag is non-binding labels Nov 18, 2016
@ktoso ktoso self-assigned this Nov 18, 2016
@ktoso ktoso removed the 3 - in progress Someone is working on this ticket label Nov 18, 2016
@ktoso ktoso closed this as completed Nov 18, 2016
@SethTisue
Copy link
Contributor

@ktoso if this is done, could you submit an update to https://github.com/scala/make-release-notes/blob/2.12.x/projects-2.12.md ?

@SethTisue
Copy link
Contributor

@ktoso is this done?

@ktoso
Copy link
Member

ktoso commented Dec 6, 2016

Yes, and we're released against 2.12 as well :-)
http://search.maven.org/#artifactdetails%7Ccom.typesafe.akka%7Cakka-http_2.12%7C10.0.0%7Cjar

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
t:build Issues that affect the build
Projects
None yet
Development

No branches or pull requests

8 participants