zio / zio-quickstarts

A minimal quickstart ZIO application for writing a RESTful Web Service
https://zio.dev/guides/#quickstart-guides
60 stars 39 forks source link

error when "sbt run" #32

Open coleea opened 1 year ago

coleea commented 1 year ago

Envirionment

Windows 10 Pro Version 2009

$ > java --version
java 20 2023-03-21
Java(TM) SE Runtime Environment (build 20+36-2344)
Java HotSpot(TM) 64-Bit Server VM (build 20+36-2344, mixed mode, sharing)
scala --version
Scala code runner version 3.2.2 -- Copyright 2002-2023, LAMP/EPFL

I run "sbt run" in ".\zio-quickstart-hello-world" directory but error occurs like this

[info] welcome to sbt 1.8.2 (Oracle Corporation Java 20)
[info] loading project definition from J:\project\study\fp-libraries\zio-quickstarts\zio-quickstart-hello-world\project
J:\project\study\fp-libraries\zio-quickstarts\zio-quickstart-hello-world\build.sbt:3: error: not found: value stdSettings
    .settings(stdSettings())
              ^
J:\project\study\fp-libraries\zio-quickstarts\zio-quickstart-hello-world\build.sbt:4: error: not found: value enableZIO
    .settings(enableZIO())
              ^
sbt.compiler.EvalException: Type error in expression
[error] sbt.compiler.EvalException: Type error in expression
[error] Use 'last' for the full log.
[warn] Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? (default: r)

What I am missing ? thank you

gusost commented 1 year ago

Having the same issue

Environment MacBook Pro - Apple M1 Max - macOS 13.4

zio-quickstart-hello-world % java -version 
openjdk version "1.8.0_322"
OpenJDK Runtime Environment (Zulu 8.60.0.21-CA-macos-aarch64) (build 1.8.0_322-b06)
OpenJDK 64-Bit Server VM (Zulu 8.60.0.21-CA-macos-aarch64) (build 25.322-b06, mixed mode)
zio-quickstart-hello-world % scala --version
Scala code runner version 3.2.2 -- Copyright 2002-2023, LAMP/EPFL

Running sbt run yields the same complaint about not found:

zio-quickstart-hello-world % sbt run
[info] welcome to sbt 1.8.2 (Azul Systems, Inc. Java 1.8.0_322)
[info] loading project definition from /Users/syb/Documents/GitHub/zio-quickstarts/zio-quickstart-hello-world/project
/Users/syb/Documents/GitHub/zio-quickstarts/zio-quickstart-hello-world/build.sbt:3: error: not found: value stdSettings
    .settings(stdSettings())
              ^
/Users/syb/Documents/GitHub/zio-quickstarts/zio-quickstart-hello-world/build.sbt:4: error: not found: value enableZIO
    .settings(enableZIO())
              ^
sbt.compiler.EvalException: Type error in expression
[error] sbt.compiler.EvalException: Type error in expression
[error] Use 'last' for the full log.
[warn] Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? (default: r)
GrigoriiBerezin commented 1 month ago

Hello, as I can see, now it is fixed and all zio plugin stuff was moved into root sbt file