I just started trying to go through the [getting started tutorial](https://github.com/igrishaev/etaoin#getting-stated). But when I try to define a chrome driver, using (def driver (chrome))
, I get an exception, any idea what might be going on? Googling suggests that it might be to do with having a 32 bit binary on OSX catalina, but I’ve never had to worry about that before with a clojure program… 😵
~
{:clojure.main/message
“Execution error (IOException) at java.lang.ProcessImpl/forkAndExec (ProcessImpl.java:-2).\nerror=86, Bad CPU type in executable\n”,
:clojure.main/triage
{:clojure.error/class http://java.io.IOException,
:clojure.error/line -2,
:clojure.error/cause “error=86, Bad CPU type in executable”,
:clojure.error/symbol java.lang.ProcessImpl/forkAndExec,
:clojure.error/source “ProcessImpl.java”,
:clojure.error/phase :execution},
:clojure.main/trace
{:via
[{:type clojure.lang.Compiler$CompilerException,
:message “Syntax error macroexpanding at (core.clj:9:13).“,
:data
{:clojure.error/phase :execution,
:clojure.error/line 9,
:clojure.error/column 13,
:clojure.error/source “core.clj”},
:at [clojure.lang.Compiler$InvokeExpr eval “Compiler.java” 3707]}
{:type http://java.io.IOException,
:message
“Cannot run program \“chromedriver\“: error=86, Bad CPU type in executable”,
:at [java.lang.ProcessBuilder start “ProcessBuilder.java” 1128]}
{:type http://java.io.IOException,
:message “error=86, Bad CPU type in executable”,
:at [java.lang.ProcessImpl forkAndExec “ProcessImpl.java” -2]}],
:trace
[[java.lang.ProcessImpl forkAndExec “ProcessImpl.java” -2]
[java.lang.ProcessImpl <init> “ProcessImpl.java” 319]
[java.lang.ProcessImpl start “ProcessImpl.java” 250]
[java.lang.ProcessBuilder start “ProcessBuilder.java” 1107]
[java.lang.ProcessBuilder start “ProcessBuilder.java” 1071]
[etaoin.proc$run invokeStatic “proc.clj” 16]
[etaoin.proc$run invoke “proc.clj” 12]
[etaoin.api$run_driver invokeStatic “api.clj” 2756]
[etaoin.api$run_driver doInvoke “api.clj” 2653]
[clojure.lang.RestFn invoke “RestFn.java” 423]
[etaoin.api$boot_driver invokeStatic “api.clj” 2830]
[etaoin.api$boot_driver invoke “api.clj” 2815]
[etaoin.api$boot_driver invokeStatic “api.clj” 2826]
[etaoin.api$boot_driver invoke “api.clj” 2815]
[clojure.core$partial$fn__5839 invoke “core.clj” 2623]
[clojure.lang.AFn applyToHelper “AFn.java” 152]
[clojure.lang.RestFn applyTo “RestFn.java” 132]
[clojure.lang.Compiler$InvokeExpr eval “Compiler.java” 3702]
[clojure.lang.Compiler$DefExpr eval “Compiler.java” 457]
[clojure.lang.Compiler eval “Compiler.java” 7182]
[clojure.lang.Compiler load “Compiler.java” 7636]
[clojure.lang.Compiler loadFile “Compiler.java” 7574]
[clojure.main$load_script invokeStatic “main.clj” 475]
[clojure.main$script_opt invokeStatic “main.clj” 535]
[clojure.main$script_opt invoke “main.clj” 530]
[clojure.main$main invokeStatic “main.clj” 664]
[clojure.main$main doInvoke “main.clj” 616]
[clojure.lang.RestFn applyTo “RestFn.java” 137]
[clojure.lang.Var applyTo “Var.java” 705]
[clojure.main main “main.java” 40]],
:cause “error=86, Bad CPU type in executable”,
:phase :execution}}
~
Ahh, just found some useful info in the github issues - might be worth putting https://github.com/igrishaev/etaoin#installing-drivers right next to the https://github.com/igrishaev/etaoin#installation section, and before the https://github.com/igrishaev/etaoin#getting-stated section!
btw, @igrishaev: made a pull request: https://github.com/igrishaev/etaoin/pull/230 to hopefully avoid confusion for other beginners!
and thanks for all your work on this, etaoin looks great!
asciidoctor watch + reload script using babashka and etaoin: https://twitter.com/borkdude/status/1268270628039282690
@borkdude Is the @(promise)
just a way to stop the script from exiting?