ClojureScript

cljs.main: Sometimes print side effects don't properly occur prior to REPL

Details

  • Type: Defect Defect
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None
  • Environment:
    {:deps {org.clojure/clojurescript {:mvn/version "1.10.138"}}}
    macOS
    Safari

Description

Using built 1.10.138:

src/hello_world/core.cljs
(ns hello-world.core)

(println "Hello world!")

Note that sometimes Hello world! is printed, and sometimes only a newline.

$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit

Activity

Mike Fikes made changes -
Field Original Value New Value
Environment {:deps {org.clojure/clojurescript {:mvn/version "1.10.138"}}} {:deps {org.clojure/clojurescript {:mvn/version "1.10.138"}}}
macOS
Safari
Mike Fikes made changes -
Summary cljs.main: Sometimes print side effects don't occur prior to REPL cljs.main: Sometimes print side effects don't fully occur prior to REPL
Mike Fikes made changes -
Description Using built 1.10.138:

{code:title=src/hello_world/core.cljs}
(ns hello-world.core)

(println "Hello world!")
{code}

{noformat}
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit
{noformat}
Using built 1.10.138:

{code:title=src/hello_world/core.cljs}
(ns hello-world.core)

(println "Hello world!")
{code}

Note that sometimes {{Hello world!}} is printed, and sometimes only a newline.

{noformat}
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl
Hello world!
ClojureScript 1.10.138
cljs.user=> :cljs/quit
$ clj -Srepro --main cljs.main --compile hello-world.core --repl

ClojureScript 1.10.138
cljs.user=> :cljs/quit
{noformat}
Summary cljs.main: Sometimes print side effects don't fully occur prior to REPL cljs.main: Sometimes print side effects don't properly occur prior to REPL

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated: