Error Starting Backend Server - Syntax error (IOException) compiling at (/tmp/form-init7961961400806051699.clj:1:73)

Hi All,

I’m trying to start up Metabase for development on the frontend. When trying to start the backend server, with sudo lein ring server, I get this error:

I put the error here (it was saying I have too many links so I could not put in post) https://pastebin.com/aBs9T0cm

The version of Java i’m running is:

openjdk version “1.8.0_222”
OpenJDK Runtime Environment (build 1.8.0_222-8u222-b10-1ubuntu1~18.04.1-b10)
OpenJDK 64-Bit Server VM (build 25.222-b10, mixed mode)

Hi @dyaw-drexel
Do not use sudo. Not sure why it’s failing.
What do you see in /tmp/form-init7961961400806051699.clj:1:73?
Which branch and commit are you trying to build?
I prefer lein ring server-headless, since I don’t want it to automatically start the browser, in case frontend is not finished building.

Hi @flamber

I can’t seem to find /tmp/form-init7961961400806051699.clj… not sure if it was deleted?

When I try lein ring server-headless I get this:

Retrieving lein-environ/lein-environ/1.1.0/lein-environ-1.1.0.pom from clojars
Retrieving lein-environ/lein-environ/1.1.0/lein-environ-1.1.0.jar from clojars
java.io.FileNotFoundException: /home/uhc/metabase/.lein-env (Permission denied)
at java.io.FileOutputStream.open0 (FileOutputStream.java:-2)
java.io.FileOutputStream.open (FileOutputStream.java:270)
java.io.FileOutputStream. (FileOutputStream.java:213)
clojure.java.io$eval248$fn__251.invoke (io.clj:230)
clojure.java.io$eval139$fn__166$G__130__173.invoke (io.clj:69)
clojure.java.io$fn__208.invokeStatic (io.clj:166)
clojure.java.io/fn (io.clj:166)
clojure.java.io$eval139$fn__179$G__126__186.invoke (io.clj:69)
clojure.java.io$writer.invokeStatic (io.clj:119)
clojure.java.io$writer.doInvoke (io.clj:104)
clojure.lang.RestFn.invoke (RestFn.java:410)
clojure.lang.AFn.applyToHelper (AFn.java:154)
clojure.lang.RestFn.applyTo (RestFn.java:132)
clojure.core$apply.invokeStatic (core.clj:648)
clojure.core$apply.invoke (core.clj:641)
clojure.core$spit.invokeStatic (core.clj:6673)
clojure.core$spit.doInvoke (core.clj:6668)
clojure.lang.RestFn.invoke (RestFn.java:425)
lein_environ.plugin$write_env_to_file.invokeStatic (plugin.clj:28)
lein_environ.plugin$write_env_to_file.invoke (plugin.clj:27)
clojure.lang.Var.invoke (Var.java:394)
clojure.lang.AFn.applyToHelper (AFn.java:165)
clojure.lang.Var.applyTo (Var.java:700)
clojure.core$apply.invokeStatic (core.clj:648)
clojure.core$apply.invoke (core.clj:641)
robert.hooke$compose_hooks$fn__16535.doInvoke (hooke.clj:40)
clojure.lang.RestFn.applyTo (RestFn.java:137)
clojure.core$apply.invokeStatic (core.clj:646)
clojure.core$apply.invoke (core.clj:641)
robert.hooke$run_hooks.invokeStatic (hooke.clj:46)
robert.hooke$run_hooks.invoke (hooke.clj:45)
robert.hooke$prepare_for_hooks$fn__16540$fn__16541.doInvoke (hooke.clj:54)
clojure.lang.RestFn.applyTo (RestFn.java:137)
clojure.lang.AFunction$1.doInvoke (AFunction.java:29)
clojure.lang.RestFn.invoke (RestFn.java:436)
leiningen.core.main$resolve_and_apply.invokeStatic (main.clj:340)
leiningen.core.main$resolve_and_apply.invoke (main.clj:336)
leiningen.core.main$_main$fn__8955.invoke (main.clj:420)
leiningen.core.main$_main.invokeStatic (main.clj:411)
leiningen.core.main$_main.doInvoke (main.clj:408)
clojure.lang.RestFn.invoke (RestFn.java:421)
clojure.lang.Var.invoke (Var.java:383)
clojure.lang.AFn.applyToHelper (AFn.java:156)
clojure.lang.Var.applyTo (Var.java:700)
clojure.core$apply.invokeStatic (core.clj:646)
clojure.core$apply.invoke (core.clj:641)
clojure.main$main_opt.invokeStatic (main.clj:316)
clojure.main$main_opt.invoke (main.clj:310)
clojure.main$main.invokeStatic (main.clj:421)
clojure.main$main.doInvoke (main.clj:384)
clojure.lang.RestFn.invoke (RestFn.java:457)
clojure.lang.Var.invoke (Var.java:394)
clojure.lang.AFn.applyToHelper (AFn.java:165)
clojure.lang.Var.applyTo (Var.java:700)
clojure.main.main (main.java:37)

and when I try lein ring server I get this:

java.io.FileNotFoundException: /home/uhc/metabase/.lein-env (Permission denied)
at java.io.FileOutputStream.open0 (FileOutputStream.java:-2)
java.io.FileOutputStream.open (FileOutputStream.java:270)
java.io.FileOutputStream. (FileOutputStream.java:213)
clojure.java.io$eval248$fn__251.invoke (io.clj:230)
clojure.java.io$eval139$fn__166$G__130__173.invoke (io.clj:69)
clojure.java.io$fn__208.invokeStatic (io.clj:166)
clojure.java.io/fn (io.clj:166)
clojure.java.io$eval139$fn__179$G__126__186.invoke (io.clj:69)
clojure.java.io$writer.invokeStatic (io.clj:119)
clojure.java.io$writer.doInvoke (io.clj:104)
clojure.lang.RestFn.invoke (RestFn.java:410)
clojure.lang.AFn.applyToHelper (AFn.java:154)
clojure.lang.RestFn.applyTo (RestFn.java:132)
clojure.core$apply.invokeStatic (core.clj:648)
clojure.core$apply.invoke (core.clj:641)
clojure.core$spit.invokeStatic (core.clj:6673)
clojure.core$spit.doInvoke (core.clj:6668)
clojure.lang.RestFn.invoke (RestFn.java:425)
lein_environ.plugin$write_env_to_file.invokeStatic (plugin.clj:28)
lein_environ.plugin$write_env_to_file.invoke (plugin.clj:27)
clojure.lang.Var.invoke (Var.java:394)
clojure.lang.AFn.applyToHelper (AFn.java:165)
clojure.lang.Var.applyTo (Var.java:700)
clojure.core$apply.invokeStatic (core.clj:648)
clojure.core$apply.invoke (core.clj:641)
robert.hooke$compose_hooks$fn__16535.doInvoke (hooke.clj:40)
clojure.lang.RestFn.applyTo (RestFn.java:137)
clojure.core$apply.invokeStatic (core.clj:646)
clojure.core$apply.invoke (core.clj:641)
robert.hooke$run_hooks.invokeStatic (hooke.clj:46)
robert.hooke$run_hooks.invoke (hooke.clj:45)
robert.hooke$prepare_for_hooks$fn__16540$fn__16541.doInvoke (hooke.clj:54)
clojure.lang.RestFn.applyTo (RestFn.java:137)
clojure.lang.AFunction$1.doInvoke (AFunction.java:29)
clojure.lang.RestFn.invoke (RestFn.java:436)
leiningen.core.main$resolve_and_apply.invokeStatic (main.clj:340)
leiningen.core.main$resolve_and_apply.invoke (main.clj:336)
leiningen.core.main$_main$fn__8955.invoke (main.clj:420)
leiningen.core.main$_main.invokeStatic (main.clj:411)
leiningen.core.main$_main.doInvoke (main.clj:408)
clojure.lang.RestFn.invoke (RestFn.java:421)
clojure.lang.Var.invoke (Var.java:383)
clojure.lang.AFn.applyToHelper (AFn.java:156)
clojure.lang.Var.applyTo (Var.java:700)
clojure.core$apply.invokeStatic (core.clj:646)
clojure.core$apply.invoke (core.clj:641)
clojure.main$main_opt.invokeStatic (main.clj:316)
clojure.main$main_opt.invoke (main.clj:310)
clojure.main$main.invokeStatic (main.clj:421)
clojure.main$main.doInvoke (main.clj:384)
clojure.lang.RestFn.invoke (RestFn.java:457)
clojure.lang.Var.invoke (Var.java:394)
clojure.lang.AFn.applyToHelper (AFn.java:165)
clojure.lang.Var.applyTo (Var.java:700)
clojure.main.main (main.java:37)

Also, just to check, I should be starting the backend first, then the frontend right?

@dyaw-drexel
Well, that’s your problem:
java.io.FileNotFoundException: /home/uhc/metabase/.lein-env (Permission denied)
So if you are uhc, then you have probably installed lein using sudo, which then locks you out.
Think you need to cleanup and setup the environment again without sudo

@flamber - How would I go about doing the cleanup? I’m new at all this, so still learning. I tried deleting everything and re-cloning the master branch, and also reinstalled leingington.

uhc@uhc-dev:~/metabase$ lein ring server -headless
[include-drivers middleware] Attempting to include these drivers: #{"google" "bigquery" "oracle" "mongo" "sqlite" "sparksql" "vertica" "presto" "druid" "redshift" "sqlserver" "googleanalytics" "snowflake"}
 [include-drivers middleware]Not including vertica because not all dependencies matching #{#"^vertica-jdbc-.*\.jar$"} found in /plugins
 [include-drivers middleware]Not including oracle because not all dependencies matching #{#"^ojdbc\d+\.jar$"} found in /plugins
[include-drivers middleware] including these drivers: #{"google" "bigquery" "mongo" "sqlite" "sparksql" "presto" "druid" "redshift" "sqlserver" "googleanalytics" "snowflake"}
Error encountered performing task 'ring' with profile(s): 'base,system,user,provided,dev,ring'
java.lang.NumberFormatException: For input string: "-headless"
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
        at java.lang.Integer.parseInt(Integer.java:580)
        at java.lang.Integer.<init>(Integer.java:867)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
        at clojure.lang.Reflector.invokeConstructor(Reflector.java:180)
        at leiningen.ring.server$server.invokeStatic(server.clj:98)
        at leiningen.ring.server$server.invoke(server.clj:93)
        at clojure.lang.AFn.applyToHelper(AFn.java:156)
        at clojure.lang.AFn.applyTo(AFn.java:144)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at leiningen.ring$ring.invokeStatic(ring.clj:23)
        at leiningen.ring$ring.doInvoke(ring.clj:13)
        at clojure.lang.RestFn.invoke(RestFn.java:442)
        at clojure.lang.Var.invoke(Var.java:388)
        at clojure.lang.AFn.applyToHelper(AFn.java:160)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at leiningen.core.main$partial_task$fn__8888.doInvoke(main.clj:284)
        at clojure.lang.RestFn.applyTo(RestFn.java:139)
        at clojure.lang.AFunction$1.doInvoke(AFunction.java:29)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at leiningen.core.main$apply_task.invokeStatic(main.clj:334)
        at leiningen.core.main$apply_task.invoke(main.clj:320)
        at lein_environ.plugin$write_env_to_file.invokeStatic(plugin.clj:29)
        at lein_environ.plugin$write_env_to_file.invoke(plugin.clj:27)
        at clojure.lang.Var.invoke(Var.java:394)
        at clojure.lang.AFn.applyToHelper(AFn.java:165)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at robert.hooke$compose_hooks$fn__16535.doInvoke(hooke.clj:40)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.core$apply.invokeStatic(core.clj:646)
        at clojure.core$apply.invoke(core.clj:641)
        at robert.hooke$run_hooks.invokeStatic(hooke.clj:46)
        at robert.hooke$run_hooks.invoke(hooke.clj:45)
        at robert.hooke$prepare_for_hooks$fn__16540$fn__16541.doInvoke(hooke.clj:54)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.lang.AFunction$1.doInvoke(AFunction.java:29)
        at clojure.lang.RestFn.invoke(RestFn.java:436)
        at leiningen.with_profile$with_profiles_STAR_.invokeStatic(with_profile.clj:14)
        at leiningen.with_profile$with_profiles_STAR_.invoke(with_profile.clj:8)
        at leiningen.with_profile$apply_task_with_profiles.invokeStatic(with_profile.clj:53)
        at leiningen.with_profile$apply_task_with_profiles.invoke(with_profile.clj:45)
        at leiningen.with_profile$with_profile$fn__16594.invoke(with_profile.clj:85)
        at clojure.core$mapv$fn__15557.invoke(core.clj:6627)
        at clojure.core.protocols$fn__15359.invokeStatic(protocols.clj:167)
        at clojure.core.protocols$fn__15359.invoke(protocols.clj:124)
        at clojure.core.protocols$fn__15314$G__15309__15323.invoke(protocols.clj:19)
        at clojure.core.protocols$seq_reduce.invokeStatic(protocols.clj:31)
        at clojure.core.protocols$seq_reduce.invoke(protocols.clj:24)
        at clojure.core.protocols$fn__15342.invokeStatic(protocols.clj:101)
        at clojure.core.protocols$fn__15342.invoke(protocols.clj:75)
        at clojure.core.protocols$fn__15288$G__15283__15301.invoke(protocols.clj:13)
        at clojure.core$reduce.invokeStatic(core.clj:6545)
        at clojure.core$reduce.invoke(core.clj:6527)
        at clojure.core$mapv.invokeStatic(core.clj:6627)
        at clojure.core$mapv.invoke(core.clj:6618)
        at leiningen.with_profile$with_profile.invokeStatic(with_profile.clj:85)
        at leiningen.with_profile$with_profile.doInvoke(with_profile.clj:63)
        at clojure.lang.RestFn.invoke(RestFn.java:494)
        at clojure.lang.Var.invoke(Var.java:401)
        at clojure.lang.AFn.applyToHelper(AFn.java:171)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at leiningen.core.main$partial_task$fn__8888.doInvoke(main.clj:284)
        at clojure.lang.RestFn.applyTo(RestFn.java:139)
        at clojure.lang.AFunction$1.doInvoke(AFunction.java:29)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at leiningen.core.main$apply_task.invokeStatic(main.clj:334)
        at leiningen.core.main$apply_task.invoke(main.clj:320)
        at lein_environ.plugin$write_env_to_file.invokeStatic(plugin.clj:29)
        at lein_environ.plugin$write_env_to_file.invoke(plugin.clj:27)
        at clojure.lang.Var.invoke(Var.java:394)
        at clojure.lang.AFn.applyToHelper(AFn.java:165)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.core$apply.invokeStatic(core.clj:648)
        at clojure.core$apply.invoke(core.clj:641)
        at robert.hooke$compose_hooks$fn__16535.doInvoke(hooke.clj:40)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.core$apply.invokeStatic(core.clj:646)
        at clojure.core$apply.invoke(core.clj:641)
        at robert.hooke$run_hooks.invokeStatic(hooke.clj:46)
        at robert.hooke$run_hooks.invoke(hooke.clj:45)
        at robert.hooke$prepare_for_hooks$fn__16540$fn__16541.doInvoke(hooke.clj:54)
        at clojure.lang.RestFn.applyTo(RestFn.java:137)
        at clojure.lang.AFunction$1.doInvoke(AFunction.java:29)
        at clojure.lang.RestFn.invoke(RestFn.java:436)
        at leiningen.core.main$resolve_and_apply.invokeStatic(main.clj:340)
        at leiningen.core.main$resolve_and_apply.invoke(main.clj:336)
        at leiningen.core.main$_main$fn__8955.invoke(main.clj:420)
        at leiningen.core.main$_main.invokeStatic(main.clj:411)
        at leiningen.core.main$_main.doInvoke(main.clj:408)
        at clojure.lang.RestFn.invoke(RestFn.java:436)
        at clojure.lang.Var.invoke(Var.java:388)
        at clojure.lang.AFn.applyToHelper(AFn.java:160)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.core$apply.invokeStatic(core.clj:646)
        at clojure.core$apply.invoke(core.clj:641)
        at clojure.main$main_opt.invokeStatic(main.clj:316)
        at clojure.main$main_opt.invoke(main.clj:310)
        at clojure.main$main.invokeStatic(main.clj:421)
        at clojure.main$main.doInvoke(main.clj:384)
        at clojure.lang.RestFn.invoke(RestFn.java:482)
        at clojure.lang.Var.invoke(Var.java:401)
        at clojure.lang.AFn.applyToHelper(AFn.java:171)
        at clojure.lang.Var.applyTo(Var.java:700)
        at clojure.main.main(main.java:37)

@flamber here is the log when I run that without headless: https://pastebin.com/R3kJyWJ6

@dyaw-drexel There’s no space between server and -headless. lein ring server-headless
It’s giving a IOException, which probably means that you don’t have the correct permissions to some place. Most likely because you have been mixing sudo
Check the tmp file as reference in the end of the log.
I would recommend that you remove the requirements and install them again correctly:
https://www.metabase.com/docs/latest/developers-guide.html#install-prerequisites

@flamber I uninstalled and purged all the prerequisites and re-cloned the git and reinstalled everything and attempted to run as root so I do not have to use sudo. Now it allows me to do lein ring server-headless but I still get the same error under lein ring server. When browsing to port 3000 it displays the following messege (rather then the setup):

{“message”:“No method in multimethod ‘connection-properties’ for dispatch value: :googleanalytics”,“type”:“class java.lang.IllegalArgumentException”,“stacktrace”:[“clojure.lang.MultiFn.getFn(MultiFn.java:156)”,“clojure.lang.MultiFn.invoke(MultiFn.java:229)”,"–> driver.util$available_drivers_info$iter__24202__24206$fn__24207.invoke(util.clj:119)",“driver.util$available_drivers_info.invokeStatic(util.clj:117)”,“driver.util$available_drivers_info.invoke(util.clj:113)”,“public_settings$public_settings.invokeStatic(public_settings.clj:223)”,“public_settings$public_settings.invoke(public_settings.clj:209)”,“routes.index$load_entrypoint_template.invokeStatic(index.clj:72)”,“routes.index$load_entrypoint_template.invoke(index.clj:69)”,“routes.index$entrypoint.invokeStatic(index.clj:93)”,“routes.index$entrypoint.invoke(index.clj:88)”,“middleware.exceptions$catch_uncaught_exceptions$fn__79714.invoke(exceptions.clj:104)”,“middleware.exceptions$catch_api_exceptions$fn__79711.invoke(exceptions.clj:92)”,“middleware.log$log_api_call$fn__80172.invoke(log.clj:172)”,“middleware.security$add_security_headers$fn__79669.invoke(security.clj:122)”,“middleware.json$wrap_json_body$fn__79959.invoke(json.clj:75)”,“middleware.json$wrap_streamed_json_response$fn__79977.invoke(json.clj:109)”,“middleware.session$bind_current_user$fn__75705$fn__75706.invoke(session.clj:209)”,“middleware.session$do_with_current_user.invokeStatic(session.clj:184)”,“middleware.session$do_with_current_user.invoke(session.clj:177)”,“middleware.session$bind_current_user$fn__75705.invoke(session.clj:208)”,“middleware.session$wrap_current_user_id$fn__75682.invoke(session.clj:161)”,“middleware.session$wrap_session_id$fn__75667.invoke(session.clj:123)”,“middleware.auth$wrap_api_key$fn__79601.invoke(auth.clj:27)”,“middleware.misc$maybe_set_site_url$fn__80207.invoke(misc.clj:56)”,“middleware.misc$bind_user_locale$fn__80210.invoke(misc.clj:72)”,“middleware.misc$add_content_type$fn__80195.invoke(misc.clj:28)”,“middleware.misc$disable_streaming_buffering$fn__80218.invoke(misc.clj:87)”]}

@dyaw-drexel
From your last log, it looks like you’re master commit a1508c9, which is a month old. Use to latest master or one of the release tags.
Please post the output of these:

java -version
nodejs --version
lein --version
yarn --version
lsb_release -d
git log -1 --format="commit %H"
git status | head -1

Just switched to branch release 0.33 - same error.

Here’s the results from that:

java -version

openjdk version “1.8.0_222”
OpenJDK Runtime Environment (build 1.8.0_222-8u222-b10-1ubuntu1~18.04.1-b10)
OpenJDK 64-Bit Server VM (build 25.222-b10, mixed mode)

nodejs --version

v13.2.0

lein --version

Leiningen 2.8.1 on Java 1.8.0_222 OpenJDK 64-Bit Server VM

yarn --version

1.19.2

lsb_release -d

Description: Ubuntu 18.04.3 LTS

git log -1 --format=“commit %H”

commit be1e0e19c2ca7cfa1eab4e5731b4ead456b586f4

git status | head -1

On branch release-0.33.x

@dyaw-drexel Upgrade lein. Latest release is 2.9.1. Try Oracle JDK instead of OpenJDK.

@flamber - just upgraded lein to 2.9. From what I understand we cant get Oracle JDK 8 anymore, so I had to stick with OpenJDK. Still having the same issue. Here’s the error log again:

{:clojure.main/message “Syntax error (IOException) compiling at (/tmp/form-init283574714773832308.clj:1:72).\nServer returned HTTP response code: 500 for URL: http://localhost:3000/\n”,
:clojure.main/triage
{:clojure.error/phase :compile-syntax-check,
:clojure.error/line 1,
:clojure.error/column 72,
:clojure.error/source “form-init283574714773832308.clj”,
:clojure.error/path “/tmp/form-init283574714773832308.clj”,
:clojure.error/class java.io.IOException,
:clojure.error/cause “Server returned HTTP response code: 500 for URL: http://localhost:3000/”},
:clojure.main/trace
{:via
[{:type clojure.lang.Compiler$CompilerException,
:message “Syntax error compiling at (/tmp/form-init283574714773832308.clj:1:72).”,
:data {:clojure.error/phase :compile-syntax-check, :clojure.error/line 1, :clojure.error/column 72, :clojure.error/source “/tmp/form-init283574714773832308.clj”},
:at [clojure.lang.Compiler load “Compiler.java” 7648]}
{:type java.io.IOException,
:message “Server returned HTTP response code: 500 for URL: http://localhost:3000/”,
:at [jdk.internal.reflect.NativeConstructorAccessorImpl newInstance0 “NativeConstructorAccessorImpl.java” -2]}
{:type java.io.IOException,
:message “Server returned HTTP response code: 500 for URL: http://localhost:3000/”,
:at [sun.net.www.protocol.http.HttpURLConnection getInputStream0 “HttpURLConnection.java” 1919]}],
:trace
[[sun.net.www.protocol.http.HttpURLConnection getInputStream0 “HttpURLConnection.java” 1919]
[sun.net.www.protocol.http.HttpURLConnection getInputStream “HttpURLConnection.java” 1515]
[java.net.HttpURLConnection getResponseCode “HttpURLConnection.java” 527]
[javax.swing.JEditorPane getStream “JEditorPane.java” 735]
[javax.swing.JEditorPane setPage “JEditorPane.java” 433]
[javax.swing.JEditorPane setPage “JEditorPane.java” 883]
[javax.swing.JEditorPane “JEditorPane.java” 276]
[jdk.internal.reflect.NativeConstructorAccessorImpl newInstance0 “NativeConstructorAccessorImpl.java” -2]
[jdk.internal.reflect.NativeConstructorAccessorImpl newInstance “NativeConstructorAccessorImpl.java” 62]
[jdk.internal.reflect.DelegatingConstructorAccessorImpl newInstance “DelegatingConstructorAccessorImpl.java” 45]
[java.lang.reflect.Constructor newInstance “Constructor.java” 490]
[clojure.lang.Reflector invokeConstructor “Reflector.java” 305]
[clojure.java.browse_ui$open_url_in_swing invokeStatic “browse_ui.clj” 15]
[clojure.java.browse_ui$open_url_in_swing invoke “browse_ui.clj” 15]
[clojure.lang.Var invoke “Var.java” 384]
[clojure.java.browse$open_url_in_swing invokeStatic “browse.clj” 64]
[clojure.java.browse$browse_url invokeStatic “browse.clj” 74]
[clojure.java.browse$browse_url invoke “browse.clj” 66]
[ring.server.standalone$open_browser_to invokeStatic “standalone.clj” 38]
[ring.server.standalone$open_browser_to invoke “standalone.clj” 37]
[ring.server.standalone$serve$fn__4247 invoke “standalone.clj” 107]
[ring.server.standalone$try_port invokeStatic “standalone.clj” 16]
[ring.server.standalone$try_port invoke “standalone.clj” 10]
[ring.server.standalone$serve invokeStatic “standalone.clj” 100]
[ring.server.standalone$serve doInvoke “standalone.clj” 75]
[clojure.lang.RestFn invoke “RestFn.java” 423]
[ring.server.leiningen$serve invokeStatic “leiningen.clj” 19]
[ring.server.leiningen$serve invoke “leiningen.clj” 16]
[user$eval76292 invokeStatic “form-init283574714773832308.clj” 1]
[user$eval76292 invoke “form-init283574714773832308.clj” 1]

[clojure.lang.Compiler eval “Compiler.java” 7177]
[clojure.lang.Compiler eval “Compiler.java” 7167]
[clojure.lang.Compiler load “Compiler.java” 7636]
[clojure.lang.Compiler loadFile “Compiler.java” 7574]
[clojure.main$load_script invokeStatic “main.clj” 475]
[clojure.main$init_opt invokeStatic “main.clj” 477]
[clojure.main$init_opt invoke “main.clj” 477]
[clojure.main$initialize invokeStatic “main.clj” 508]
[clojure.main$null_opt invokeStatic “main.clj” 542]
[clojure.main$null_opt invoke “main.clj” 539]
[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 “Server returned HTTP response code: 500 for URL: http://localhost:3000/”,
:phase :compile-syntax-check}}

@dyaw-drexel Why can’t you get Oracle JDK? Yes, it now has a horrible license, but you should be able to use it for development without problems.
There must be something wrong with your development environment. Try setting up a completely new Ubuntu and install the prerequisites as noted in the documentation. And don’t run as root or with sudo.

@flamber - just to make sure i’m understanding correctly, I should try to install the prerequisites without sudo or root? How do I do that on Ubuntu? I thought you always needed to be root or sudo to apt-get install

@flamber - Sorry was confused by the ppa pulling JDK, I was able to manually get it from Oracle. Just started a new Ubuntu Server 18.04 VM using Oracle JDK 8, Lein 2.9. Everything was installed by root so as to not use sudo, and the rest of the prerequisite process was done using a normal account.

@dyaw-drexel Okay, so does that mean that it’s working now? And yes, some things requires to be installed with sudo, but the install will normally fail if sudo is required.

@flamber Sorry i forgot to mention that it’s still not working, having the same issue. Feels like it must be something I’m doing wrong. I should start the backend first, and then the front end , right?

@dyaw-drexel It shouldn’t matter which end you start first.
My only idea right now would be that you posted your ~/.bash_history, so I can see what you did from since you reinstalled the VM to now.
Please post again

java -version
nodejs --version
lein --version
yarn --version
lsb_release -d
git log -1 --format="commit %H"
git status | head -1

@flamber I was able to figure out I was missing the JAVA_HOME environmental variable - just set it and now I get a different error. It’s got to be something with permissions.
Error encountered performing task ‘ring’ with profile(s): ‘base,system,user,provided,dev,ring’

java.lang.Exception: Couldn’t create directories: /home/uhc/metabase/target/default+ring+564a970d/classes
at leiningen.core.utils$mkdirs.invokeStatic(utils.clj:71)
at leiningen.core.utils$mkdirs.invoke(utils.clj:66)
at leiningen.core.eval$prep.invokeStatic(eval.clj:79)
at leiningen.core.eval$prep.invoke(eval.clj:73)
at leiningen.core.eval$eval_in_project.invokeStatic(eval.clj:363)
at leiningen.core.eval$eval_in_project.invoke(eval.clj:357)
at clojure.lang.Var.invoke(Var.java:393)
at leinjacker.eval$eval_in_project$fn__1416.invoke(eval.clj:33)
at leinjacker.eval$eval_in_project.invokeStatic(eval.clj:36)
at leinjacker.eval$eval_in_project.invoke(eval.clj:28)
at leiningen.ring.server$server_task.invokeStatic(server.clj:79)
at leiningen.ring.server$server_task.invoke(server.clj:72)
at leiningen.ring.server$server.invokeStatic(server.clj:96)
at leiningen.ring.server$server.invoke(server.clj:93)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at leiningen.ring$ring.invokeStatic(ring.clj:23)
at leiningen.ring$ring.doInvoke(ring.clj:13)
at clojure.lang.RestFn.invoke(RestFn.java:425)
at clojure.lang.AFn.applyToHelper(AFn.java:156)
at clojure.lang.RestFn.applyTo(RestFn.java:132)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at leiningen.core.main$partial_task$fn__7021.doInvoke(main.clj:284)
at clojure.lang.RestFn.applyTo(RestFn.java:139)
at clojure.lang.AFunction$1.doInvoke(AFunction.java:31)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at leiningen.core.main$apply_task.invokeStatic(main.clj:334)
at leiningen.core.main$apply_task.invoke(main.clj:320)
at lein_environ.plugin$write_env_to_file.invokeStatic(plugin.clj:29)
at lein_environ.plugin$write_env_to_file.invoke(plugin.clj:27)
at clojure.lang.AFn.applyToHelper(AFn.java:165)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at robert.hooke$compose_hooks$fn__10848.doInvoke(hooke.clj:40)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invokeStatic(core.clj:665)
at clojure.core$apply.invoke(core.clj:660)
at robert.hooke$run_hooks.invokeStatic(hooke.clj:46)
at robert.hooke$run_hooks.invoke(hooke.clj:45)
at robert.hooke$prepare_for_hooks$fn__10853$fn__10854.doInvoke(hooke.clj:54)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.lang.AFunction$1.doInvoke(AFunction.java:31)
at clojure.lang.RestFn.invoke(RestFn.java:436)
at leiningen.with_profile$with_profiles_STAR_.invokeStatic(with_profile.clj:14)
at leiningen.with_profile$with_profiles_STAR_.invoke(with_profile.clj:8)
at leiningen.with_profile$apply_task_with_profiles.invokeStatic(with_profile.clj:53)
at leiningen.with_profile$apply_task_with_profiles.invoke(with_profile.clj:45)
at leiningen.with_profile$with_profile$fn__10911.invoke(with_profile.clj:85)
at clojure.core$mapv$fn__8430.invoke(core.clj:6912)
at clojure.core.protocols$fn__8144.invokeStatic(protocols.clj:168)
at clojure.core.protocols$fn__8144.invoke(protocols.clj:124)
at clojure.core.protocols$fn__8099$G__8094__8108.invoke(protocols.clj:19)
at clojure.core.protocols$seq_reduce.invokeStatic(protocols.clj:31)
at clojure.core.protocols$fn__8131.invokeStatic(protocols.clj:75)
at clojure.core.protocols$fn__8131.invoke(protocols.clj:75)
at clojure.core.protocols$fn__8073$G__8068__8086.invoke(protocols.clj:13)
at clojure.core$reduce.invokeStatic(core.clj:6828)
at clojure.core$mapv.invokeStatic(core.clj:6903)
at clojure.core$mapv.invoke(core.clj:6903)
at leiningen.with_profile$with_profile.invokeStatic(with_profile.clj:85)
at leiningen.with_profile$with_profile.doInvoke(with_profile.clj:63)
at clojure.lang.RestFn.applyTo(RestFn.java:146)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at leiningen.core.main$partial_task$fn__7021.doInvoke(main.clj:284)
at clojure.lang.RestFn.applyTo(RestFn.java:139)
at clojure.lang.AFunction$1.doInvoke(AFunction.java:31)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at leiningen.core.main$apply_task.invokeStatic(main.clj:334)
at leiningen.core.main$apply_task.invoke(main.clj:320)
at lein_environ.plugin$write_env_to_file.invokeStatic(plugin.clj:29)
at lein_environ.plugin$write_env_to_file.invoke(plugin.clj:27)
at clojure.lang.AFn.applyToHelper(AFn.java:165)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:660)
at robert.hooke$compose_hooks$fn__10848.doInvoke(hooke.clj:40)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invokeStatic(core.clj:665)
at clojure.core$apply.invoke(core.clj:660)
at robert.hooke$run_hooks.invokeStatic(hooke.clj:46)
at robert.hooke$run_hooks.invoke(hooke.clj:45)
at robert.hooke$prepare_for_hooks$fn__10853$fn__10854.doInvoke(hooke.clj:54)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.lang.AFunction$1.doInvoke(AFunction.java:31)
at clojure.lang.RestFn.invoke(RestFn.java:436)
at leiningen.core.main$resolve_and_apply.invokeStatic(main.clj:340)
at leiningen.core.main$resolve_and_apply.invoke(main.clj:336)
at leiningen.core.main$_main$fn__7110.invoke(main.clj:449)
at leiningen.core.main$_main.invokeStatic(main.clj:439)
at leiningen.core.main$_main.doInvoke(main.clj:436)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.core$apply.invokeStatic(core.clj:665)
at clojure.main$main_opt.invokeStatic(main.clj:491)
at clojure.main$main_opt.invoke(main.clj:487)
at clojure.main$main.invokeStatic(main.clj:598)
at clojure.main$main.doInvoke(main.clj:561)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.lang.Var.applyTo(Var.java:705)
at clojure.main.main(main.java:37)

But when I try to run it under root, I get the same error:

12-04 14:21:25 INFO metabase.core :: Metabase Initialization COMPLETE
Started server on port 3000
Syntax error (IOException) compiling at (/tmp/form-init5660150135970919504.clj:1:73).
Server returned HTTP response code: 500 for URL: http://localhost:3000/

And here’s the current versions:

uhc@uhc-dev:~/metabase$ java -version
java version “1.8.0_231”
Java™ SE Runtime Environment (build 1.8.0_231-b11)
Java HotSpot™ 64-Bit Server VM (build 25.231-b11, mixed mode)
uhc@uhc-dev:~/metabase$ nodejs --version
v13.2.0
uhc@uhc-dev:~/metabase$ lein --version
Warning: implicit hook found: lein-environ.plugin/hooks
Hooks are deprecated and will be removed in a future version.
Leiningen 2.9.0 on Java 1.8.0_231 Java HotSpot™ 64-Bit Server VM
uhc@uhc-dev:~/metabase$ yarn --version
1.19.2
uhc@uhc-dev:~/metabase$ lsb_release -d
Description: Ubuntu 18.04.3 LTS
uhc@uhc-dev:~/metabase$ git log -1 --format=“commit %H”
commit be1e0e19c2ca7cfa1eab4e5731b4ead456b586f4
uhc@uhc-dev:~/metabase$ git status | head -1
On branch release-0.33.x

And also just tried to build the jar file, and get this error:

Stripping duplicate classes and extra-compressing /home/uhc/metabase/modules/drivers/bigquery/target/uberjar/bigquery.metabase-driver.jar…
Syntax error (FileNotFoundException) compiling at (/tmp/form-init2335660144762921215.clj:1:73).
resources/modules/google.metabase-driver.jar (No such file or directory)

I can’t seem to get the .bash_history to work… comes up blank, will post if I can get it

@flamber - So I went and reinstalled everything again on a fresh VM and I am now able to build the jar file. However, I have a new error when I try to run the backend:

12-04 16:52:17 INFO sync.util :: FINISHED: step ‘classify-tables’ for h2 Database 1 ‘Sample Dataset’ (48.9 ms)
12-04 16:52:17 INFO sync.util :: FINISHED: Analyze data for h2 Database 1 ‘Sample Dataset’ (297.9 ms)
Syntax error (HeadlessException) compiling at (/tmp/form-init6812580044391796278.clj:1:73).
null

Full report at:
/tmp/clojure-6202335187189616478.edn
12-04 16:52:18 INFO metabase.core :: Metabase Shutting Down …
12-04 16:52:18 INFO metabase.core :: Metabase Shutdown COMPLETE
Error encountered performing task ‘ring’ with profile(s): ‘base,system,user,provided,dev,ring’
Subprocess failed

And the log says

:clojure.main/message “Syntax error (HeadlessException) compiling at (/tmp/form-init6812580044391796278.clj:1:73).\nnull\n”,
:clojure.main/triage
{:clojure.error/phase :compile-syntax-check,
:clojure.error/line 1,
:clojure.error/column 73,
:clojure.error/source “form-init6812580044391796278.clj”,
:clojure.error/path “/tmp/form-init6812580044391796278.clj”,
:clojure.error/class java.awt.HeadlessException},
:clojure.main/trace
{:via
[{:type clojure.lang.Compiler$CompilerException,
:message “Syntax error compiling at (/tmp/form-init6812580044391796278.clj:1:73).”,
:data {:clojure.error/phase :compile-syntax-check, :clojure.error/line 1, :clojure.error/column 73, :clojure.error/source “/tmp/form-init6812580044391796278.clj”},
:at [clojure.lang.Compiler load “Compiler.java” 7648]}
{:type java.awt.HeadlessException, :at [java.awt.GraphicsEnvironment checkHeadless “GraphicsEnvironment.java” 204]}],
:trace
[[java.awt.GraphicsEnvironment checkHeadless “GraphicsEnvironment.java” 204]
[java.awt.Window “Window.java” 536]
[java.awt.Frame “Frame.java” 420]
[java.awt.Frame “Frame.java” 385]
[javax.swing.JFrame “JFrame.java” 189]
[clojure.java.browse_ui$open_url_in_swing invokeStatic “browse_ui.clj” 19]
[clojure.java.browse_ui$open_url_in_swing invoke “browse_ui.clj” 15]
[clojure.lang.Var invoke “Var.java” 384]
[clojure.java.browse$open_url_in_swing invokeStatic “browse.clj” 64]
[clojure.java.browse$browse_url invokeStatic “browse.clj” 74]
[clojure.java.browse$browse_url invoke “browse.clj” 66]
[ring.server.standalone$open_browser_to invokeStatic “standalone.clj” 38]
[ring.server.standalone$open_browser_to invoke “standalone.clj” 37]
[ring.server.standalone$serve$fn__4247 invoke “standalone.clj” 107]
[ring.server.standalone$try_port invokeStatic “standalone.clj” 16]
[ring.server.standalone$try_port invoke “standalone.clj” 10]
[ring.server.standalone$serve invokeStatic “standalone.clj” 100]
[ring.server.standalone$serve doInvoke “standalone.clj” 75]
[clojure.lang.RestFn invoke “RestFn.java” 423]
[ring.server.leiningen$serve invokeStatic “leiningen.clj” 19]
[ring.server.leiningen$serve invoke “leiningen.clj” 16]
[user$eval82186 invokeStatic “form-init6812580044391796278.clj” 1]
[user$eval82186 invoke “form-init6812580044391796278.clj” 1]
[clojure.lang.Compiler eval “Compiler.java” 7177]
[clojure.lang.Compiler eval “Compiler.java” 7167]
[clojure.lang.Compiler load “Compiler.java” 7636]
[clojure.lang.Compiler loadFile “Compiler.java” 7574]
[clojure.main$load_script invokeStatic “main.clj” 475]
[clojure.main$init_opt invokeStatic “main.clj” 477]
[clojure.main$init_opt invoke “main.clj” 477]
[clojure.main$initialize invokeStatic “main.clj” 508]
[clojure.main$null_opt invokeStatic “main.clj” 542]
[clojure.main$null_opt invoke “main.clj” 539]
[clojure.main$main invokeStatic “main.clj” 664]
[clojure.main$main doInvoke “main.clj” 616]
[clojure.lang.RestFn applyTo “RestFn.java” 137]

[clojure.java.browse$browse_url invoke “browse.clj” 66]
[ring.server.standalone$open_browser_to invokeStatic “standalone.clj” 38]
[ring.server.standalone$open_browser_to invoke “standalone.clj” 37]
[ring.server.standalone$serve$fn__4247 invoke “standalone.clj” 107]
[ring.server.standalone$try_port invokeStatic “standalone.clj” 16]
[ring.server.standalone$try_port invoke “standalone.clj” 10]
[ring.server.standalone$serve invokeStatic “standalone.clj” 100]
[ring.server.standalone$serve doInvoke “standalone.clj” 75]
[clojure.lang.RestFn invoke “RestFn.java” 423]
[ring.server.leiningen$serve invokeStatic “leiningen.clj” 19]
[ring.server.leiningen$serve invoke “leiningen.clj” 16]
[user$eval82186 invokeStatic “form-init6812580044391796278.clj” 1]
[user$eval82186 invoke “form-init6812580044391796278.clj” 1]
[clojure.lang.Compiler eval “Compiler.java” 7177]
[clojure.lang.Compiler eval “Compiler.java” 7167]
[clojure.lang.Compiler load “Compiler.java” 7636]
[clojure.lang.Compiler loadFile “Compiler.java” 7574]
[clojure.main$load_script invokeStatic “main.clj” 475]
[clojure.main$init_opt invokeStatic “main.clj” 477]
[clojure.main$init_opt invoke “main.clj” 477]
[clojure.main$initialize invokeStatic “main.clj” 508]
[clojure.main$null_opt invokeStatic “main.clj” 542]
[clojure.main$null_opt invoke “main.clj” 539]
[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]],
:phase :compile-syntax-check}}