Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 17:41
    craffit opened #2420
  • May 20 16:19
    alexarchambault commented #2419
  • May 20 09:35
    sjrd commented #2419
  • May 19 16:32
    bishabosha edited #2419
  • May 19 16:30
    bishabosha edited #2419
  • May 19 16:27
    bishabosha edited #2419
  • May 19 16:26
    bishabosha opened #2419
  • May 19 16:26
    bjornregnell closed #2058
  • May 19 16:26
    bjornregnell commented #2058
  • May 19 16:20
    bishabosha commented #2058
  • May 18 18:26
    chenrui333 opened #2418
  • May 18 12:06

    alexarchambault on v2.1.0-M6

    (compare)

  • May 18 12:02

    alexarchambault on mill-0.10.4

    (compare)

  • May 18 12:02

    alexarchambault on master

    Update Mill to 0.10.4 (#2411) (compare)

  • May 18 12:02
    alexarchambault closed #2411
  • May 17 20:03
    chadselph closed #1774
  • May 17 20:02
    chadselph commented #1774
  • May 17 18:54

    alexarchambault on gh-pages

    Update website (compare)

  • May 17 18:20

    alexarchambault on master

    Merge page cli-setup.md into cl… (compare)

  • May 17 18:20
    alexarchambault closed #2417
Chris Kipp
@ckipp:matrix.org
[m]
also keep in mind that you can do a bloop exit to shutdown bloop, and then open Metals, and metals will start the version of bloop it has reference to
xraybat
@xraybat
yes, might have to let metals take care of its ownbloop needs, ftm
xraybat
@xraybat

ok, appears to be my mistake -- after bloop exit and restarting bloop it attached to a 1.4.9 server -- so bloop about now reports 1.4.9.

i assume it just kept restarting an older server previously.

Tobias Roeser
@lefou
With the update of from 20.16+73-gddc6d9cc9 to 2.0.16-158-gbdc8669f9 we get the following exception in out CI
  java.lang.NoSuchMethodError: 'com.google.common.collect.ImmutableSet com.google.common.collect.ImmutableSet.copyOf(java.util.Collection)'
    com.google.common.jimfs.Configuration$Builder.setRoots(Configuration.java:611)
    com.google.common.jimfs.Configuration$UnixHolder.<clinit>(Configuration.java:90)
    com.google.common.jimfs.Configuration.unix(Configuration.java:86)
    com.google.common.jimfs.Configuration.forCurrentPlatform(Configuration.java:210)
    com.google.common.jimfs.Jimfs.newFileSystem(Jimfs.java:110)
    com.google.common.jimfs.Jimfs.newFileSystem(Jimfs.java:92)
    org.scalajs.jsenv.nodejs.ComRun$.setupFile(ComSupport.scala:247)
    org.scalajs.jsenv.nodejs.ComRun$.start(ComSupport.scala:214)
    org.scalajs.jsenv.nodejs.NodeJSEnv.startWithCom(NodeJSEnv.scala:46)
    org.scalajs.testing.adapter.JSEnvRPC.<init>(JSEnvRPC.scala:25)
    org.scalajs.testing.adapter.TestAdapter.startManagedRunner(TestAdapter.scala:129)
    org.scalajs.testing.adapter.TestAdapter.$anonfun$getRunnerForThread$1(TestAdapter.scala:120)
    scala.collection.concurrent.TrieMap.getOrElseUpdate(TrieMap.scala:952)
    org.scalajs.testing.adapter.TestAdapter.getRunnerForThread(TestAdapter.scala:120)
    org.scalajs.testing.adapter.TestAdapter.loadFrameworks(TestAdapter.scala:56)
    mill.scalajslib.worker.ScalaJSWorkerImpl.getFramework(ScalaJSWorkerImpl.scala:127)
    mill.scalajslib.ScalaJSWorker.getFramework(ScalaJSWorkerApi.scala:68)
    mill.scalajslib.TestScalaJSModule.$anonfun$testTask$1(ScalaJSModule.scala:230)
    mill.define.ApplyerGenerated.$anonfun$zipMap$9(ApplicativeGenerated.scala:21)
    mill.define.Task$MappedDest.evaluate(Task.scala:374)
    mill.eval.Evaluator.$anonfun$evaluateGroup$13(Evaluator.scala:509)
It's not directly related to coursier, but probably to it's transitive dependencies
This is a ScalaJS test.
Any ideas?
Also, we get this:
  java.lang.NoClassDefFoundError: Could not initialize class com.google.common.jimfs.Configuration$UnixHolder
    com.google.common.jimfs.Configuration.unix(Configuration.java:86)
    com.google.common.jimfs.Configuration.forCurrentPlatform(Configuration.java:210)
    com.google.common.jimfs.Jimfs.newFileSystem(Jimfs.java:110)
    com.google.common.jimfs.Jimfs.newFileSystem(Jimfs.java:92)
    org.scalajs.jsenv.nodejs.NodeJSEnv$.fs$lzycompute(NodeJSEnv.scala:77)
    org.scalajs.jsenv.nodejs.NodeJSEnv$.fs(NodeJSEnv.scala:77)
    org.scalajs.jsenv.nodejs.NodeJSEnv$.installSourceMapIfAvailable$lzycompute(NodeJSEnv.scala:83)
    org.scalajs.jsenv.nodejs.NodeJSEnv$.org$scalajs$jsenv$nodejs$NodeJSEnv$$installSourceMapIfAvailable(NodeJSEnv.scala:81)
    org.scalajs.jsenv.nodejs.NodeJSEnv.initFiles(NodeJSEnv.scala:68)
    org.scalajs.jsenv.nodejs.NodeJSEnv.start(NodeJSEnv.scala:39)
    mill.scalajslib.worker.Run$.runInterruptible(Run.scala:39)
Grégory Marti
@gmarti

Morning,

Trying to migrate my repositories to gitlab i seem to have a problem to download sbt plugins from there.

I tried to configure normal sbt with Http headers, its not working

my project/plugins.sbt file :

import lmcoursier.definitions.Authentication

val auth:Authentication = if (sys.env.contains("CI")) {
  Authentication(Seq(("Job-Token",sys.env("CI_JOB_TOKEN"))))
} else {
  Authentication(Seq(("Private-Token", sys.env("GITLAB_PRIVATE_TOKEN"))))
}
resolvers += ("COUCOU" at "https://myrepo/api/v4/groups/mygroup/-/packages/maven")


csrConfiguration ~= (_.addRepositoryAuthentication("COUCOU",auth))
updateClassifiers / csrConfiguration ~= (_.addRepositoryAuthentication("COUCOU",auth))
updateSbtClassifiers / csrConfiguration ~= (_.addRepositoryAuthentication("COUCOU",auth))

addSbtPlugin("myorg"    % "sbt-myplugin"    % "1.2.3")

error : Im forbidden, so probably it doesnt use the authentication (I can successfully curl with the token )

So i tried to use sbt-coursier plugin for this "specific use-case" with sbt-extras (like here https://get-coursier.io/docs/sbt-coursier#sbt-13x) but it doesnt compile, seems there is an issue with coursier version conflict
java.lang.NoSuchMethodError: 'coursier.core.Project lmcoursier.definitions.ToCoursier$.project(lmcoursier.definitions.Project)'

Is there a way to use sbt-coursier plugin instead of coursier used by sbt ?

Thanks

Boris Capitanu
@borice

Is it possible to unify artifact cache locations between Maven and SBT such that we don't end up with multiple copies of the same artifact in the various caches (Maven, Ivy, Coursier)? I have projects built with Maven and SBT and over time the cached artifacts are starting to occupy a non-trivial amount of disk space. "It is what it is" was my philosophy so far, but a cursory inspection shows that there are many duplicates between the artifacts stored at ~/.m2/repository/, ~/.ivy2/cache/, and ~/Library/Caches/Coursier/....

Is it possible to create a setup where Maven and SBT projects look up (and store) cached artifacts in a single location? That includes sbt publishLocal to store the locally-published artifact in the same cached location. I don't care which location it is between the 3 I mentioned...

Tobias Roeser
@lefou
@borice Possible, yes, advisable, probably not. At least, each tools has different assumption about the mutability of the downloaded artifacts. I think coursier is rather strict. The simplest solution would be IMHO, to derive from MavenRepository and just lookup the JARs in alternative locations before downloading them. That means all metadata is still redundant and under the control of each respective tool, but the actual JARs, which are the large files, and which can be checked for their checksums, are shared in the sense that they will be reused if already present in some other location.
2 replies
mtjon-gitter
@mtjon-gitter

Hi just got myself an ARM-based Apple computer and tried installing Java, Scala, sbt, etc. through coursier. It appears to work for Java (adopt-openj9:1.8.0-292) and Scala (2.13.6). But when launching sbt I am presented with the following error:

❯ sbt [info] [launcher] getting org.scala-sbt sbt 1.5.5 (this may take some time)... assertion failed [found_x86_offset]: no instruction entry found for jit breakpoint at arm address 0x10838cbb0 (TranslationCacheJit.cpp:300 handle_jit_breakpoint)

I don't see anything on this on the docs so was hoping someone could help me out with this. I'd prefer to install everything thsough one manager (coursier) and not have to install e.g. sbt through brew. Thanks!

Omid
@karamiomid
Hi Gitter Guys!
I'm trying to install this command "cs setup --jvm adopt:11" I have some errors. Please help me!
Exception in thread "main" coursier.cache.ArtifactError$DownloadError: download error: Caught javax.net.ssl.SSLHandshakeException (PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target) while downloading https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11%2B28/OpenJDK11-jdk_x64_mac_hotspot_11_28.tar.gz
Eugene Medvediev
@eugenemedvediev
Hello, I have a problem with updating bloop to latest version:
I have Ubuntu 20.04 and have installed bloop via coursier. Current version is bloop v1.4.10-8-8d1cbc4f.
I see no errors when I execute command cs update bloop. I even uninstall bloop and install again, but somehow it installs version 1.4.10, even if 1.4.11 is available.
Looks like it uses already downloaded version and only copying it to ~/.local/share/coursier/bin/bloop location.
What is the way to install latest bloop?
Eugene Medvediev
@eugenemedvediev

❯ cs install bloop
https://repo1.maven.org/maven2/ch/epfl/scala/bloopgun_2.12/maven-metadata.xml
No new update since 2021-11-02 20:11:03
Wrote bloop

~/.cache/coursier/v1/https/repo1.maven.org/maven2/ch/epfl/scala/bloop-launcher_2.12
❯ bloop about
bloop v1.4.10-8-8d1cbc4f

but if I follow the link, then latest version is 1.4.11

1 reply
Miuler
@miuler:matrix.org
[m]
have you tried with: cs update bloop ? @eugenemedvediev
Tomasz Godzik
@tgodzik
You also need to stop the server first with bloop ng-stop and then do any other Bloop command
render1980
@render1980

Hello!
I'm wondering if https://logging.apache.org/log4j/2.x/security.html could affect https://github.com/coursier/sbt-coursier

See that there is log4j as a third-party dependency:

io.get-coursier:lm-coursier_2.12:2.0.9+5-935e59c8+20211213-1307-SNAPSHOT [S]
  +-io.get-coursier:coursier_2.12:2.1.0-M1-1
  ...
  |
  +-org.scala-sbt:librarymanagement-ivy_2.12:1.3.4 [S]
  ...
    +-org.scala-sbt:librarymanagement-core_2.12:1.3.4 [S]
    ...
       +-org.scala-sbt:util-logging_2.12:1.3.3 [S]
       | +-org.apache.logging.log4j:log4j-core:2.11.2
       | | +-org.apache.logging.log4j:log4j-api:2.11.2
Tim Steinbach
@NeQuissimus
Hello. Homebrew just upgraded me to Coursier 2.1.0-M1 yesterday. The one thing that stood out for my use case is coursier/coursier#2188 I can set COURSIER_ARCHIVE_CACHE and then things such as cs setup --jvm adopt:1.11.0-11 will write into that folder. However, the JAVA_HOME ends up looking similar to the following: .coursier.d/https/github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.11%252B9/OpenJDK11U-jdk_x64_mac_hotspot_11.0.11_9.tar.gz/jdk-11.0.11+9/Contents/Home/ Is there currently a way to get a more direct route to JAVA_HOME? What I mean by that is that when I say adopt:1.11.0-11, the actual PATH is fairly unpredictable. I would like to know JAVA_HOME without calling cs java --envif at all possible. Maybe something like $COURSIER_ARCHIVE_CACHE/jvm/$JDK_SHORTNAME would be amazing as a symlink into the directory structure. So I suppose my question here is whether something similar already exists. And if not, I would to contribute such functionality but am having a bit of a hard time finding where exactly these paths would be built. Is modules/jvm/src/main/scala/coursier/jvm/JvmCache.scala a good place to start?
Bernie
@WorkDayHeyHey

Does Coursier support ssh resolvers?

I have used an ssh resolver in SBT for years and I like it. But I can't make it work in the current environment. The SBT doc is unchanged, but I am getting an error out of coursier.internal.PlatformRepositoryParser:89. I guess I'm not saying Maven or Ivy repo type.

Olivier Mélois
@Baccata
It might be a dumb question : have scalajs bootstraps been considered ?
A. Alonso Dominguez
@alonsodomin
hi all, wondering if any of the maintainers could take a look at the following PR and give some feedback (or at least trigger the CI build): coursier/coursier#2317
msolomon-ck
@msolomon-ck

Hey all, I'm having trouble getting coursier to discover new versions of a dependency even when setting coursier_mode and coursier_ttl to the following

export COURSIER_TTL="0s"
export COURSIER_MODE="update-local-changing,offline,missing"

The dependency in question is an sbt plugin and is wildcarding on the patch version like so 1.2.+. I'm hoping that when new patch versions of the dependency are published coursier will automatically discover and download them but as of right now it doesn't seem like that's happening. Also, the maven-metadata.xml file in the local coursier cache does not match the file in the remote repository, the local file seems to be a few versions behind. Wondering if anyone has thoughts on what I can try to make this work the way I'm expecting it to, thanks in advance!

1 reply
Vijay Emmanuel PAZHEPARAMPIL
@vijayemmanuel

I am using the standalone JAR coursier (V 2.1.0 M2) to set up scala .

$  ./coursier install -r https://username:password@artifactory.corp:443/artifactory/r-XXX-virtual scala
https://artifactory.corp:443/artifactory/r-XXX-virtual/io/get-coursier/apps/maven-metadata.xml
  No new update since 2021-11-16 00:52:42
Exception in thread "main" coursier.error.ResolutionError$CantDownloadModule: Error downloading org.scala-lang:scala-compiler:latest.stable
  download error: Caught javax.net.ssl.SSLException (Connection reset) while downloading https://repo1.maven.org/maven2/org/scala-lang/scala-compiler/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:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)

Any idea why the custom repository '-r' is not considered? I am in a enterprise environment and we cannot use repo1.maven.org.

A. Alonso Dominguez
@alonsodomin

hi all, wondering if any of the maintainers could take a look at the following PR and give some feedback (or at least trigger the CI build): coursier/coursier#2317

giving some visibility to this, if any of the maintainers is around, could this PR be reviewed please?

Mark T. Kennedy
@mtk
right now metals v0.11.0 wants bloop v1.4.12. but cs (even after a 'cs update') has bloop 1.4.11 installed. a 'cs uninstall bloop' followed by a 'cs install bloop' still downloads 1.4.11. the online doc for a cs install of bloop lists the current version as 1.4.12. i'm confused :-).
Mark T. Kennedy
@mtk
belay that question. it just needed to be restarted.
A. Alonso Dominguez
@alonsodomin
just a quick reminder for the maintainers that this PR is waiting again for approval: coursier/coursier#2317. Last time it failed because of the code format check made by scalafmt, I reformatted the code and pushed new changes.
Thijs Broersen
@ThijsBroersen
Is coursier setup currently broken? I get the following on any env I try to install it: Checking if the standard Scala applications are installed Installed ammonite Error downloading gz+https://github.com/coursier/coursier/releases/download/v2.1.0-M5-1-gc8a0a64bd/cs-x86_64-pc-linux.gz
simonjscott
@simonjscott
I've run into a problem with artefact resolution using sbt-coursier 2.0.10, sbt 1.2.6, on Windows 10. My compilations are failing because a needed artefact can't be found on the classpath. What seems to be happening is that, if an artefact is already present in my local .m2 repo, then coursier doesn't add the artefact's location to the classpath. If I remove the artefact from the .m2 repo, then coursier downloads and everything works. Does this sound familiar to anyone? I am wondering if it is related to this issue: coursier/coursier#372
2 replies
Chris Kipp
@ckipp:matrix.org
[m]
maybe not the answer you're looking for, but depending on why you are using sbt-coursier, you could just consider using mainline sbt without sbt-coursier since as of 1.4.x it uses coursier by default
1 reply
since you are on a pretty old version of sbt
Chris Kipp
@ckipp:matrix.org
[m]
but rather your coursier cache location
Gideon Potok
@GideonPotok
image.png
image.png
image.png
image.png
image.png
image.png
image.png

[error] (update) lmcoursier.internal.shaded.coursier.error.FetchError$DownloadingArtifacts: Error fetching artifacts:
[error] https://repo1.maven.org/maven2/org/apache/avro/avro-mapred/1.10.2/avro-mapred-1.10.2-hadoop2.jar: not found: https://repo1.maven.org/maven2/org/apache/avro/avro-mapred/1.10.2/avro-mapred-1.10.2-hadoop2.jar
[error] Total time: 3 s, completed Feb 18, 2022 10:01:42 PM

What is my next move?

anyone want to dm me and help me walk through some dependency issues?
Steve Jones
@sjfloat
Is anyone else aware of problems with coursier? I seem to be limited to scala 3
cs install scala:2.13.1 https://repo1.maven.org/maven2/io/get-coursier/apps/maven-metadata.xml No new update since 2022-02-06 13:51:21 Exception in thread "main" coursier.error.ResolutionError$CantDownloadModule: Error downloading org.scala-lang:scala3-compiler_3:2.13.1 not found: https://repo1.maven.org/maven2/org/scala-lang/scala3-compiler_3/2.13.1/scala3-compiler_3-2.13.1.pom