DevInsideYou / install-scala-env

MIT License
1 stars 2 forks source link

Error when running install-scala-env #1

Open otterlover24 opened 3 years ago

otterlover24 commented 3 years ago

Hi,

Many thanks for your detailed Git tutorial series on Youtube. I was trying to follow along the Part 11 video which required installing Scala environment and used the script in install-scala-dev. However, I ran into an error, with the output shown below. May I know how to resolve this please? Also, is there an uninstall script to uninstall the Scala environment that is installed using the script?

[otterlover24@Vovo] ~/dev/interactive-rebase-playground/seven-segment-display-clock (main)
❯ curl -fLOs https://script.install.devinsideyou.com/scala-env
chmod +x scala-env && ./scala-env

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0
100   144  100   144    0     0     87      0  0:00:01  0:00:01 --:--:--    87
100 57.1M  100 57.1M    0     0  6968k      0  0:00:08  0:00:08 --:--:-- 16.1M
Checking if a JVM is installed
No JVM found, should we try to install one? [Y/n] Y
Extracting
  /home/otterlover24/.cache/coursier/v1/https/github.com/graalvm/graalvm-ce-builds/releases/download/vm-21.1.0/graalvm-ce-java8-linux-amd64-21.1.0.tar.gz
in
  /home/otterlover24/.cache/coursier/jvm/graalvm-ce-java8@21.1.0
Done
Should we update ~/.profile? [Y/n] Y
Some shell configuration files were updated. It is recommended to close this terminal once the setup command is done, and open a new one for the changes to be taken into account.

Checking if ~/.local/share/coursier/bin is in PATH
Should we add ~/.local/share/coursier/bin to your PATH via ~/.profile? [Y/n] Y

Checking if the standard Scala applications are installed
 [    #     ]   Downloaded 56 POM files
Exception in thread "main" coursier.error.ResolutionError$CantDownloadModule: Error downloading com.lihaoyi:upickle-core_2.13:1.4.0
  download error: Caught java.net.ConnectException (Connection timed out (Connection timed out)) while downloading https://repo1.maven.org/maven2/com/lihaoyi/upickle-core_2.13/1.4.0/upickle-core_2.13-1.4.0.pom
        at coursier.Resolve$.$anonfun$validate$1(Resolve.scala:329)
        at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:285)
        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:285)
        at scala.collection.TraversableLike.map$(TraversableLike.scala:278)
        at scala.collection.AbstractTraversable.map(Traversable.scala:108)
        at coursier.Resolve$.validate(Resolve.scala:327)
        at coursier.Resolve.validate0$1(Resolve.scala:115)
        at coursier.Resolve.$anonfun$ioWithConflicts0$4(Resolve.scala:161)
        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:84)
        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:1128)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.lang.Thread.run(Thread.java:834)
        at com.oracle.svm.core.thread.JavaThreads.threadStartRoutine(JavaThreads.java:517)
        at com.oracle.svm.core.posix.thread.PosixJavaThreads.pthreadStartRoutine(PosixJavaThreads.java:193)
Don't forget to restart your terminal and/or your session!
agilesteel commented 3 years ago

Hi,

You are welcome! It looks like it was just a small network issue. Just finish running the rest of the install script manually (make sure to restart the terminal before you run this) by doing

cs install ammonite bloop cs giter8 sbt scala scalafmt

The list of the apps is taken from https://github.com/DevInsideYou/install-scala-env/blob/master/install-scala-env.sh#L13

If you are a Scala dev and want to learn more about coursier/cs (it's the tool/package manager that is used by this script) I have a playlist about it.

Cheers and happy coding! :)