Giter VIP home page Giter VIP logo

apps's Introduction

Coursier

Build status Join the chat at https://gitter.im/coursier/coursier Maven Central Scaladoc

Documentation

Coursier is the Scala application and artifact manager. It can install Scala applications and setup your Scala development environment. It can also download and cache artifacts from the web.

See the website for more details.

Code of Conduct

The coursier project welcomes contributions from anybody wishing to participate. All code or documentation that is provided must be licensed with the same license that coursier is licensed with (Apache 2.0, see LICENSE).

People are expected to follow the Scala Code of Conduct when discussing coursier on GitHub, Gitter channel, or other venues.

Feel free to open an issue if you notice a bug, have an idea for a feature, or have a question about the code. Pull requests are also gladly accepted.

Acknowledgments

Large parts of the developments in coursier since Sep. 2018 have been funded by the Scala Center, through the employment or contracting of myself (Alexandre Archambault).

apps's People

Contributors

actions-user avatar adpi2 avatar alejandrohdezma avatar alexarchambault avatar anatoliykmetyuk avatar arturopala avatar avdv avatar barkingbad avatar bishabosha avatar bjaglin avatar blandflakes avatar christopherdavenport avatar ckipp01 avatar d10xa avatar danbim avatar danielleontiev avatar dependabot[bot] avatar dwijnand avatar eloots avatar julienrf avatar keynmol avatar lwronski avatar molarmanful avatar mushtaq avatar olafurpg avatar rtar avatar scala-steward avatar tgodzik avatar traviscibot avatar vicennial avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

apps's Issues

Fails to install `scala-update`.

When trying to do a cs install --contrib scala-update it fails with the following:

warning: unknown anonymous info of class scala.tools.nsc.typechecker.ContextErrors$NamerContextErrors$NamerErrorGen$DuplicatesErrorKinds$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by scala.tools.nsc.typechecker.ContextErrors$NamerContextErrors$NamerErrorGen$DuplicatesErrorKinds$ which is not following the naming convention.
warning: unknown anonymous info of class scala.tools.nsc.typechecker.ContextErrors$InferencerContextErrors$InferErrorGen$PolyAlternativeErrorKind$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by scala.tools.nsc.typechecker.ContextErrors$InferencerContextErrors$InferErrorGen$PolyAlternativeErrorKind$ which is not following the naming convention.
warning: unknown anonymous info of class scala.tools.nsc.settings.Warnings$LintWarnings$LintWarning, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by scala.tools.nsc.settings.Warnings$LintWarnings$LintWarning which is not following the naming convention.
warning: unknown anonymous info of class scala.tools.nsc.typechecker.ContextErrors$NamerContextErrors$NamerErrorGen$SymValidateErrors$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by scala.tools.nsc.typechecker.ContextErrors$NamerContextErrors$NamerErrorGen$SymValidateErrors$ which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTag$ParsedLightTypeTag$SubtypeDBs, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTag$ParsedLightTypeTag$SubtypeDBs which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature which is not following the naming convention.
warning: unknown anonymous info of class [Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature; which is not following the naming convention.
warning: unknown anonymous info of class [[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature; which is not following the naming convention.
warning: unknown anonymous info of class [[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature; which is not following the naming convention.
warning: unknown anonymous info of class [[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature; which is not following the naming convention.
warning: unknown anonymous info of class [[[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$Signature; which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember which is not following the naming convention.
warning: unknown anonymous info of class [Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember; which is not following the naming convention.
warning: unknown anonymous info of class [[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember; which is not following the naming convention.
warning: unknown anonymous info of class [[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember; which is not following the naming convention.
warning: unknown anonymous info of class [[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember; which is not following the naming convention.
warning: unknown anonymous info of class [[[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember;, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by [[[[[Lizumi.reflect.macrortti.LightTypeTagRef$RefinementDecl$TypeMember; which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$Variance$Covariant$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$Variance$Covariant$ which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$Variance$Contravariant$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$Variance$Contravariant$ which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$Variance$Invariant$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$Variance$Invariant$ which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$SymName$SymTermName, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$SymName$SymTermName which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$SymName$SymTypeName, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$SymName$SymTypeName which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$SymName$SymLiteral, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$SymName$SymLiteral which is not following the naming convention.
warning: unknown anonymous info of class zio.Fiber$Runtime$Internal, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.Fiber$Runtime$Internal which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$Boundaries$Defined, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$Boundaries$Defined which is not following the naming convention.
warning: unknown anonymous info of class izumi.reflect.macrortti.LightTypeTagRef$Boundaries$Empty$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by izumi.reflect.macrortti.LightTypeTagRef$Boundaries$Empty$ which is not following the naming convention.
warning: unknown anonymous info of class zio.internal.FiberRuntime$EvaluationSignal$Continue$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.internal.FiberRuntime$EvaluationSignal$Continue$ which is not following the naming convention.
warning: unknown anonymous info of class zio.internal.FiberRuntime$EvaluationSignal$Done$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.internal.FiberRuntime$EvaluationSignal$Done$ which is not following the naming convention.
warning: unknown anonymous info of class zio.internal.FiberRuntime$EvaluationSignal$YieldNow$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.internal.FiberRuntime$EvaluationSignal$YieldNow$ which is not following the naming convention.
warning: unknown anonymous info of class zio.Fiber$Status$Done$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.Fiber$Status$Done$ which is not following the naming convention.
warning: unknown anonymous info of class zio.Fiber$Status$Unfinished, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.Fiber$Status$Unfinished which is not following the naming convention.
warning: unknown anonymous info of class zio.Fiber$Status$Running, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.Fiber$Status$Running which is not following the naming convention.
warning: unknown anonymous info of class zio.Fiber$Status$Suspended, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.Fiber$Status$Suspended which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$EvaluationStep$UpdateRuntimeFlags, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$EvaluationStep$UpdateRuntimeFlags which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$EvaluationStep$UpdateTrace, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$EvaluationStep$UpdateTrace which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$EvaluationStep$UpdateRuntimeFlags$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$EvaluationStep$UpdateRuntimeFlags$ which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$EvaluationStep$Continuation$, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$EvaluationStep$Continuation$ which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$ZIOError$Traced, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$ZIOError$Traced which is not following the naming convention.
warning: unknown anonymous info of class zio.ZIO$UpdateRuntimeFlagsWithin$Dynamic, assuming class is not anonymous. To remove the warning report an issue to the library or language author. The issue is caused by zio.ZIO$UpdateRuntimeFlagsWithin$Dynamic which is not following the naming convention.
[/Users/ckipp/Library/Application Support/Coursier/bin/.scala-update.aux.part:83711]     analysis:   9,361.34 ms
Error: Classes that should be initialized at run time got initialized during image building:
 scala.runtime.Statics was unintentionally initialized at build time. To see why scala.runtime.Statics got initialized use -H:+TraceClassInitialization

Error: Use -H:+ReportExceptionStackTraces to print stacktrace of underlying exception
Error: Image build request failed with exit status 1
Exception in thread "main" java.lang.RuntimeException: Error running native-image (exit code: 1)
        at scala.sys.package$.error(package.scala:30)
        at coursier.launcher.NativeImageGenerator$.generate(NativeImageGenerator.scala:124)
        at coursier.launcher.Generator$.generate(Generator.scala:14)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$15(InstallDir.scala:342)
        at coursier.install.InstallDir$.coursier$install$InstallDir$$writing(InstallDir.scala:570)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$14(InstallDir.scala:341)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$14$adapted(InstallDir.scala:311)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$22(InstallDir.scala:417)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$22$adapted(InstallDir.scala:416)
        at coursier.install.Updatable$.get$1(Updatable.scala:61)
        at coursier.install.Updatable$.$anonfun$writing$1(Updatable.scala:106)
        at coursier.cache.CacheLocks$.loop$1(CacheLocks.scala:71)
        at coursier.cache.CacheLocks$.withLockOr(CacheLocks.scala:95)
        at coursier.install.Updatable$.writing(Updatable.scala:106)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:416)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:96)
        at coursier.cli.install.Install$.$anonfun$run$7(Install.scala:127)
        at coursier.cli.install.Install$.$anonfun$run$7$adapted(Install.scala:114)
        at scala.collection.immutable.List.foreach(List.scala:431)
        at coursier.cli.install.Install$.run(Install.scala:114)
        at coursier.cli.install.Install$.run(Install.scala:22)
        at caseapp.core.app.CaseApp.main(CaseApp.scala:149)
        at caseapp.core.app.CommandsEntryPoint.main(CommandsEntryPoint.scala:115)
        at coursier.cli.Coursier$.main(Coursier.scala:118)
        at coursier.cli.Coursier.main(Coursier.scala)
  • cs version: 2.1.0-M7-18-g67daad6a9
  • os: macOS Monterey 12.6
  • Java version: openjdk 17.0.4

CC @kitlangton

Unable to cs install mill

I wasn't sure if this was better reported here or in the mill repo, so if it's a better fit there, let me know and I'll submit there.

Currently a user is unable to do either a cs update mill or cs install mill. They are created with the following:

❯ cs install mill
https://repo1.maven.org/maven2/io/get-coursier/apps/maven-metadata.xml
  No new update since 2020-04-18 12:10:23
https://repo1.maven.org/maven2/com/lihaoyi/mill-dev_2.13/maven-metadata.xml
  No new update since 2020-04-17 14:04:05
Exception in thread "main" coursier.error.ResolutionError$CantDownloadModule: Error downloading com.lihaoyi:mill-dev_2.13:latest.stable
  No latest stable version found in https://repo1.maven.org/maven2/com/lihaoyi/mill-dev_2.13/maven-metadata.xml
	at coursier.Resolve$.$anonfun$validate$1(Resolve.scala:325)
	at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:273)
	at scala.collection.Iterator.foreach(Iterator.scala:943)
	at scala.collection.Iterator.foreach$(Iterator.scala:943)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1431)
	at scala.collection.IterableLike.foreach(IterableLike.scala:74)
	at scala.collection.IterableLike.foreach$(IterableLike.scala:73)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:56)
	at scala.collection.TraversableLike.map(TraversableLike.scala:273)
	at scala.collection.TraversableLike.map$(TraversableLike.scala:266)
	at scala.collection.AbstractTraversable.map(Traversable.scala:108)
	at coursier.Resolve$.validate(Resolve.scala:323)
	at coursier.Resolve.validate0$1(Resolve.scala:112)
	at coursier.Resolve.$anonfun$ioWithConflicts0$4(Resolve.scala:156)
	at coursier.util.Task$.$anonfun$flatMap$2(Task.scala:14)
	at scala.concurrent.Future.$anonfun$flatMap$1(Future.scala:307)
	at scala.concurrent.impl.Promise.$anonfun$transformWith$1(Promise.scala:41)
	at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
	at com.oracle.svm.core.thread.JavaThreads.threadStartRoutine(JavaThreads.java:497)
	at com.oracle.svm.core.posix.thread.PosixJavaThreads.pthreadStartRoutine(PosixJavaThreads.java:193)

I'm assuming because like it says, there is not actual stable version listed in versions here?

`cs install seed` fails on macOS

Coursier 2.0.13
macOS Catalina 10.15.7
JDK Zulu 8.52.0.23-CA-macosx (build 1.8.0_282-b08)

cs install seed fails with this output:

https://repo1.maven.org/maven2/io/get-coursier/apps/maven-metadata.xml
  No new update since 2021-05-14 02:42:19
Exception in thread "main" java.lang.Exception: coursier.install.AppArtifacts$ScalaDependenciesNotFound: Can't find a scala version suffix for tindzk::seed:latest.stable (likely a non existing module or version)
	at coursier.install.AppDescriptor.artifacts(AppDescriptor.scala:66)
	at coursier.install.InstallDir.update$1(InstallDir.scala:259)
	at coursier.install.InstallDir.$anonfun$createOrUpdate$21(InstallDir.scala:385)
	at coursier.install.InstallDir.$anonfun$createOrUpdate$21$adapted(InstallDir.scala:384)
	at coursier.install.Updatable$.get$1(Updatable.scala:55)
	at coursier.install.Updatable$.$anonfun$writing$1(Updatable.scala:96)
	at coursier.cache.CacheLocks$.loop$1(CacheLocks.scala:72)
	at coursier.cache.CacheLocks$.withLockOr(CacheLocks.scala:98)
	at coursier.install.Updatable$.writing(Updatable.scala:96)
	at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:384)
	at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:87)
	at coursier.cli.install.Install$.$anonfun$run$7(Install.scala:108)
	at coursier.cli.install.Install$.$anonfun$run$7$adapted(Install.scala:95)
	at scala.collection.immutable.List.foreach(List.scala:431)
	at coursier.cli.install.Install$.run(Install.scala:95)
	at coursier.cli.Coursier$.$anonfun$runA$2(Coursier.scala:151)
	at coursier.cli.Coursier$.$anonfun$runA$2$adapted(Coursier.scala:139)
	at coursier.cli.CommandAppPreA.run(CommandAppPreA.scala:22)
	at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$5(CommandAppWithPreCommand.scala:99)
	at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$5$adapted(CommandAppWithPreCommand.scala:99)
	at scala.util.Either.fold(Either.scala:191)
	at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$3(CommandAppWithPreCommand.scala:99)
	at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$3$adapted(CommandAppWithPreCommand.scala:85)
	at scala.Option.foreach(Option.scala:407)
	at caseapp.core.app.CommandAppWithPreCommand.main(CommandAppWithPreCommand.scala:85)
	at coursier.cli.Coursier$.main(Coursier.scala:104)
	at coursier.cli.Coursier.main(Coursier.scala)
Caused by: coursier.install.AppArtifacts$ScalaDependenciesNotFound: Can't find a scala version suffix for tindzk::seed:latest.stable (likely a non existing module or version)
	at coursier.install.AppDescriptor.$anonfun$processDependencies$9(AppDescriptor.scala:184)
	at scala.Option.toRight(Option.scala:485)
	at coursier.install.AppDescriptor.processDependencies(AppDescriptor.scala:184)
	at coursier.install.AppDescriptor.artifacts(AppDescriptor.scala:64)
	... 26 more

scalac:3.x does not support -print-tasty flag

The official GitHub hosted Scala 3 scalac script for versions 3.0.0 and higher scans the flags to pick which main class to run, for example:

  • scalac -print-tasty is meant to run dotty.tools.dotc.config.TastyPrinter,
  • scalac -decompile is meant to run dotty.tools.dotc.decompiler.Main,
  • by default run dotty.tools.dotc.Main.

This means that the scalac bootstrap launcher installed by cs does not have feature parity as it always runs dotty.tools.dotc.Main.

this impacts the doc page at https://docs.scala-lang.org/scala3/guides/tasty-overview.html#what-is-tasty which recommends to use

$ scalac -print-tasty hello.tasty
$ scalac -decompile hello.tasty

So the solutions are either

  1. to publish somewhere a jar with a main class that replicates the scalac script
  2. to bundle the original bash/bat scripts for the 3.x series. This requires versionOverrides to support using prebuilt for one version, and jvm launcher for another

another mitigation is to add the tasty-printer main class to apps

cs install bloop fails

On an Intel iMac Big Sur 11.6.3
OpenJDK Runtime Environment Temurin-17+35 (build 17+35)

jmgimeno:~/ $ cs install bloop                                                            [6:07:24]
https://repo1.maven.org/maven2/io/get-coursier/apps/maven-metadata.xml
  No new update since 2022-02-06 19:51:21
https://repo1.maven.org/maven2/ch/epfl/scala/bloopgun_2.13/maven-metadata.xml
  No new update since 2022-02-11 21:30:18
Exception in thread "main" coursier.error.ResolutionError$CantDownloadModule: Error downloading ch.epfl.scala:bloopgun_2.13:latest.stable
  No latest stable version found in https://repo1.maven.org/maven2/ch/epfl/scala/bloopgun_2.13/maven-metadata.xml
	at coursier.Resolve$.$anonfun$validate$1(Resolve.scala:347)
	at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:286)
	at scala.collection.Iterator.foreach(Iterator.scala:943)
	at scala.collection.Iterator.foreach$(Iterator.scala:943)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1431)
	at scala.collection.IterableLike.foreach(IterableLike.scala:74)
	at scala.collection.IterableLike.foreach$(IterableLike.scala:73)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:56)
	at scala.collection.TraversableLike.map(TraversableLike.scala:286)
	at scala.collection.TraversableLike.map$(TraversableLike.scala:279)
	at scala.collection.AbstractTraversable.map(Traversable.scala:108)
	at coursier.Resolve$.validate(Resolve.scala:345)
	at coursier.Resolve.validate0$1(Resolve.scala:117)
	at coursier.Resolve.$anonfun$ioWithConflicts0$4(Resolve.scala:167)
	at coursier.util.Task$.$anonfun$flatMap$extension$1(Task.scala:14)
	at coursier.util.Task$.$anonfun$flatMap$extension$1$adapted(Task.scala:14)
	at coursier.util.Task$.wrap(Task.scala:82)
	at coursier.util.Task$.$anonfun$flatMap$2(Task.scala:14)
	at scala.concurrent.Future.$anonfun$flatMap$1(Future.scala:307)
	at scala.concurrent.impl.Promise.$anonfun$transformWith$1(Promise.scala:41)
	at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.lang.Thread.run(Thread.java:833)
	at com.oracle.svm.core.thread.JavaThreads.threadStartRoutine(JavaThreads.java:597)
	at com.oracle.svm.core.posix.thread.PosixJavaThreads.pthreadStartRoutine(PosixJavaThreads.java:194)
jmgimeno:~/ $

MalformedURLException when installing scala-cli

🤔 am I doing something wrong with this, when trying out cs install --contrib scala-cli on mac I'm met with this when passing in -v a couple times:

Completing 'org.virtuslab.scala-cli:cli_' (org: org.virtuslab.scala-cli, name: cli)
Found 1 completions:
  cli_2.12
Module org.virtuslab.scala-cli::cli supports 1 scala versions:
  2.12 (found)
Versions for org.virtuslab.scala-cli:cli_2.12: 0.0.2, 0.0.3, 0.0.4, 0.0.5, 0.0.6, 0.0.7, 0.0.8
Checking prebuilt launcher at gz+https://github.com/VirtusLab/scala-cli/releases/download/v0.0.8/scala-cli-x86_64-apple-darwin.gz
Error downloading gz+https://github.com/VirtusLab/scala-cli/releases/download/v0.0.8/scala-cli-x86_64-apple-darwin.gz
Exception in thread "main" coursier.install.InstallDir$DownloadError: Error downloading gz+https://github.com/VirtusLab/scala-cli/releases/download/v0.0.8/scala-cli-x86_64-apple-darwin.gz
        at coursier.install.InstallDir$.handleArtifactErrors(InstallDir.scala:626)
        at coursier.install.InstallDir$.$anonfun$prebuiltOrNotFoundUrls$1(InstallDir.scala:653)
        at scala.collection.Iterator$$anon$11.nextCur(Iterator.scala:486)
        at scala.collection.Iterator$$anon$11.hasNext(Iterator.scala:492)
        at coursier.install.InstallDir$.$anonfun$prebuiltOrNotFoundUrls$6(InstallDir.scala:660)
        at scala.util.Either.flatMap(Either.scala:341)
        at coursier.install.InstallDir$.coursier$install$InstallDir$$prebuiltOrNotFoundUrls(InstallDir.scala:658)
        at coursier.install.InstallDir.update$1(InstallDir.scala:255)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$21(InstallDir.scala:385)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$21$adapted(InstallDir.scala:384)
        at coursier.install.Updatable$.get$1(Updatable.scala:55)
        at coursier.install.Updatable$.$anonfun$writing$1(Updatable.scala:96)
        at coursier.cache.CacheLocks$.loop$1(CacheLocks.scala:72)
        at coursier.cache.CacheLocks$.withLockOr(CacheLocks.scala:98)
        at coursier.install.Updatable$.writing(Updatable.scala:96)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:384)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:87)
        at coursier.cli.install.Install$.$anonfun$run$7(Install.scala:108)
        at coursier.cli.install.Install$.$anonfun$run$7$adapted(Install.scala:95)
        at scala.collection.immutable.List.foreach(List.scala:431)
        at coursier.cli.install.Install$.run(Install.scala:95)
        at coursier.cli.Coursier$.$anonfun$runA$2(Coursier.scala:152)
        at coursier.cli.Coursier$.$anonfun$runA$2$adapted(Coursier.scala:140)
        at coursier.cli.CommandAppPreA.run(CommandAppPreA.scala:22)
        at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$5(CommandAppWithPreCommand.scala:99)
        at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$5$adapted(CommandAppWithPreCommand.scala:99)
        at scala.util.Either.fold(Either.scala:191)
        at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$3(CommandAppWithPreCommand.scala:99)
        at caseapp.core.app.CommandAppWithPreCommand.$anonfun$main$3$adapted(CommandAppWithPreCommand.scala:85)
        at scala.Option.foreach(Option.scala:407)
        at caseapp.core.app.CommandAppWithPreCommand.main(CommandAppWithPreCommand.scala:85)
        at coursier.cli.Coursier$.main(Coursier.scala:105)
        at coursier.cli.Coursier.main(Coursier.scala)

Originally posted by @ckipp01 in #115 (comment)

Consider using latest.stable version of ammonite instead of latest.release

Even if I run cs install ammonite:latest.stable every time I run cs update to update all of my apps it falls back to latest.release configured here and updates ammonite to 2.2.0-4-4bd225e instead of the desired 2.2.0.

This might be a bigger issue. Maybe coursier should remember how the app was installed to keep track of the updates.

For now I would consider using latest.stable in the resource. WDYT?

scala:[3.0.0-3.1.0) can not launch due to missing class

cs install scala:3.0.0 && scala fails because dotty.tools.MainGenericRunner was introduced in scala 3.1.0,

for [3.0.0-3.1.0) the features of the scala command were implemented in bash - so I guess the options could be to backport MainGenericRunner, or use dotty.tools.repl.Main and forgive the limitations (such as no running of files)

Add kotlin compiler (Kotlinc) app

I have been trying to write application descriptor for Kotlin compiler, but couldn’t get it working. Was someone more successful than me?

(edit by maintainer: phrasing)

Is there a way to "install" a snapshot?

I sort of assumed I could do something like this:

cs install -r sonatype:snapshots metals:0.11.9+128-92db24b7-SNAPSHOT

But when I try this I get:

❯ cs install -r sonatype:snapshots metals:0.11.9+128-92db24b7-SNAPSHOT
https://repo1.maven.org/maven2/org/scala-lang/scala-library/maven-metadata.xml
  No new update since 2022-10-08 20:29:56
Exception in thread "main" java.lang.Exception: coursier.install.AppArtifacts$ScalaDependenciesNotFound: Can't find a scala version suffix for org.scalameta::metals:0.11.9+128-92db24b7-SNAPSHOT (likely a non existing module or version)
        at coursier.install.AppDescriptor.artifacts(AppDescriptor.scala:109)
        at coursier.install.InstallDir.update$1(InstallDir.scala:271)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$22(InstallDir.scala:417)
        at coursier.install.InstallDir.$anonfun$createOrUpdate$22$adapted(InstallDir.scala:416)
        at coursier.install.Updatable$.get$1(Updatable.scala:61)
        at coursier.install.Updatable$.$anonfun$writing$1(Updatable.scala:106)
        at coursier.cache.CacheLocks$.loop$1(CacheLocks.scala:71)
        at coursier.cache.CacheLocks$.withLockOr(CacheLocks.scala:95)
        at coursier.install.Updatable$.writing(Updatable.scala:106)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:416)
        at coursier.install.InstallDir.createOrUpdate(InstallDir.scala:96)
        at coursier.cli.install.Install$.$anonfun$run$7(Install.scala:127)
        at coursier.cli.install.Install$.$anonfun$run$7$adapted(Install.scala:114)
        at scala.collection.immutable.List.foreach(List.scala:431)
        at coursier.cli.install.Install$.run(Install.scala:114)
        at coursier.cli.install.Install$.run(Install.scala:22)
        at caseapp.core.app.CaseApp.main(CaseApp.scala:149)
        at caseapp.core.app.CommandsEntryPoint.main(CommandsEntryPoint.scala:115)
        at coursier.cli.Coursier$.main(Coursier.scala:118)
        at coursier.cli.Coursier.main(Coursier.scala)
Caused by: coursier.install.AppArtifacts$ScalaDependenciesNotFound: Can't find a scala version suffix for org.scalameta::metals:0.11.9+128-92db24b7-SNAPSHOT (likely a non existing module or version)
        at coursier.install.AppDescriptor.$anonfun$processDependencies$9(AppDescriptor.scala:231)
        at scala.Option.toRight(Option.scala:485)
        at coursier.install.AppDescriptor.processDependencies(AppDescriptor.scala:231)
        at coursier.install.AppDescriptor.artifacts(AppDescriptor.scala:107)
        ... 19 more

Is this meant to work, or is there any way to achieve this?

Error installing scala-cli

Error installing scala-cli

cs install -v scala-cli

# Using install directory /home/miuler/.local/share/coursier/bin
# Found app scala-cli in channel io.get-coursier:apps
# Error downloading gz+https://github.com/VirtusLab/scala-cli/releases/download/v0.1.10/scala-cli-x86_64-pc-linux.gz

cannot install spark-repl

~ % cs install --contrib spark-repl
https://maven.aliyun.com/repository/central/io/get-coursier/apps/maven-metadata.xml
  100.0% [##########] 2.6 KiB (1.6 KiB / s)
https://maven.aliyun.com/repository/central/io/get-coursier/apps-contrib/maven-metadata.xml
  100.0% [##########] 2.4 KiB (4.2 KiB / s)
Cannot find app spark-repl in channels io.get-coursier:apps, io.get-coursier:apps-contrib

and my environment goes like (UTM in macOS M2)

coursier version # 2.1.2
scala -version # Scala code runner version 3.2.2 -- Copyright 2002-2023, LAMP/EPFL
java -version # openjdk version "19.0.2" 2023-01-17
uname -a # Linux clouds-pc 6.2.10-1-MANJARO-ARM #1 SMP PREEMPT Sat Apr  8 14:02:33 UTC 2023 aarch64 GNU/Linux

Detection of main method behaves differently for mill

I noticed that when using mill installed via cs install mill behaves a bit differently than when using the mill wrapper that is normally in mill projects. For example:

  1. Download the example project for cask
  2. Using the mill wrapper to run ./mill app.run seems to work as expected.

Now instead of using the wrapper if you try to use mill installed via cs you'll see an error.

  1. Instead of using the wrapper script, use mill installed via cs.
~/Downloads/minimalApplication-0.7.3
❯ mill app.run
  1. You should see the following:
~/Downloads/minimalApplication-0.7.3
❯ mill app.run
Compiling /Users/ckipp/Downloads/minimalApplication-0.7.3/build.sc
[26/36] app.compile
[info] Compiling 1 Scala source to /Users/ckipp/Downloads/minimalApplication-0.7.3/out/app/compile/dest/classes ...
[info] Done compiling.
[28/36] app.finalMainClass
1 targets failed
app.finalMainClass No main class specified or found

Should there be a difference in behavior for finding the main class for the two of these?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.