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

Support Scala 2.12.0 #58

Closed
ScalaWilliam opened this issue Oct 30, 2016 · 15 comments
Closed

Support Scala 2.12.0 #58

ScalaWilliam opened this issue Oct 30, 2016 · 15 comments

Comments

@ScalaWilliam
Copy link

Seems to be secretly out.

@nrinaudo
Copy link
Owner

Yeah, I realised that this weekend. I need to look into this though, as there are a few potential roadblocks:

  • all dependencies must have 2.12 artifacts, and some are quite obscure.
  • 2.12 is Java 8 only, and current artifacts are Java 7. Is there a way to cross-compile smartly, or do I need to drop Java 7 support altogether? Is that actually a problem in the Scala world?

Thoughts on the matter are quite welcome.

@ScalaWilliam
Copy link
Author

ScalaWilliam commented Oct 31, 2016

SBT supports cross-building.

  1. It appears that scalaz-stream has been moved to another library called fs2. So for a 2.12 build you'd need to be using that as I don't think they'll release a 2.12 for scalaz-stream any more. I created an issue for fs2 to do a 2.12 release: Scala 2.12.0 support/release to Maven typelevel/fs2#757 as kantan will depend upon it. kantan build.sbt reference - DONE
  2. Created an issue for a 2.12 release for: 2.12.0 support marklister/product-collections#41 - reference:
    "com.github.marklister" %% "product-collections" % productCollectionVersion,
    - DONE
  3. Created an issue for a 2.12 release for scala-csv: Scala 2.12.0 release tototoshi/scala-csv#92 - reference:
    "com.github.tototoshi" %% "scala-csv" % scalaCsvVersion
    - DONE

You also have a ScalaTest dependency but it should already be published.

2.12 artifacts will have to be Java 8 only, whereas 2.11 (or below) will support Java 7 and above as they should now.

Does this answer your roadblocks?

@nrinaudo
Copy link
Owner

Oh no I know sbt supports cross building - kantan.csv already has published artifacts for 2.11.8 and 2.10.6. What I'm not sure it supports is something like: 2.12.0 -> java 8, 2.11.8 -> java 7, ... I'll look into it.

Regarding scalaz-stream / fs2: you're entirely right, and there's already a ticket (#51) for that. Last time I looked, it meant dropping support for 2.10, which makes me a bit uncomfortable - kantan.csv doesn't have many users, but a significant part of them are running 2.10 (because of spark, mostly).

There are also some "hidden" dependencies - kantan.codecs has a lot of transitive dependencies, including scalaz, cats, shapeless... libraries that I'm pretty sure will get a 2.12.0 release fairly soon, but don't have one yet.

But yeah, the ones you created tickets for were the ones I was worried about. I'm not 100% sure they're still actively maintained. Not necessarily a show stopper, it'll just mean I need to drop them from the benchmarks, but since scala-csv is the main kantan.csv alternative, it'd be a shame. Thanks a lot for creating these tickets by the way, they probably carry more weight from a user than from a competing library author :)

@nrinaudo
Copy link
Owner

Ok, so my worries about needing to drop java 7 support are entirely unfounded. It'll actually require simplifying my build process: nrinaudo/kantan.sbt#6 .

@ScalaWilliam
Copy link
Author

FS2 unblocked. Updating issue with strikethrough. typelevel/fs2#757 (comment)

@ScalaWilliam
Copy link
Author

scala-csv unblocked: tototoshi/scala-csv#93

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 3, 2016

I think most dependencies are good now, except for product-collections which should be soon or could be dropped.

This is going to have to wait on #59 though, which I'm struggling with right now. Feel free to check what's getting me stuck and lending a hand :)

@ScalaWilliam
Copy link
Author

product-collections unblocked:
marklister/product-collections#41 (comment)

So we're now only blocked on #59 ;)

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 4, 2016

Actually, one more: non/imp#11.

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 4, 2016

Also, I think scala-csv artifacts are not yet published. Only a matter of time until they are, but I can't seem to find them.

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 4, 2016

Regarding scalaz-stream / fs2: turns out supporting fs2 actually means dropping support for 2.10. On the other hand, scalaz-stream now has a 2.12 build.

@ScalaWilliam
Copy link
Author

Then no need to migrate yet, which is good.

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 5, 2016

Almost there, I think. Still blocked on typelevel/cats#1450, but once that's done it looks pretty straightforward, provided 2.12 doesn't break too many things.

@nrinaudo
Copy link
Owner

nrinaudo commented Nov 9, 2016

Update on this: all dependencies are now available. I need to work out a couple of behavioural changes in implicit resolutions to get tests to compile again, but so far, all tests that compile pass. Shouldn't be much longer.

nrinaudo added a commit that referenced this issue Nov 10, 2016
There appears to be some weird issues with unidoc that I still need to track down.
@nrinaudo
Copy link
Owner

0.1.16-SNAPSHOT has been published with artifacts for Scala 2.12.0. Don't forget to declare the proper snapshot repository if you want to play with this:

resolvers := Seq(Resolver.sonatypeRepo("snapshots"))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants