Fork me on GitHub
#lumo
<
2017-07-15
>
hlolli16:07:37

I was running sudo npm install lumo-cljs -g and hit

Error: EACCES: permission denied, open 'lumo_linux64.zip'
sh: nodejs: command not found
workes with
su
# npm install lumo-cljs -g
just thinking out loud...

anmonteiro16:07:08

@hlolli see the latest open issue in Lumo

anmonteiro16:07:26

We could probably support that, but I haven't investigated

anmonteiro16:07:32

PR welcome if you wanna dig

hlolli16:07:56

yes, I think the script needs to detect if the active user is super user and do whatever action is there with sudo.

pesterhazy17:07:28

@hlolli not sure - if a process runs as sudo, its children are also run as root

pesterhazy17:07:51

the whole "npm as root" vs "npm as normal user" situation is a mess

pesterhazy17:07:02

it trips people up all the time

hlolli17:07:50

The upstream npm_install.js is not on the github repo?

hlolli17:07:24

haha, I'm blind 馃檪

hlolli17:07:26

noo first packages

pesterhazy17:07:26

compare the paths

anmonteiro17:07:27

@pesterhazy @hlolli I鈥檒l be eternally grateful if you wanna figure this out

hlolli19:07:44

solved this sudo npm install lumo-cljs -g --unsafe-perm works from the documentation

If npm was invoked with root privileges, then it will change the uid to the user account or uid specified by the user config, which defaults to nobody. Set the unsafe-perm flag to run scripts with root privileges.
this can be added
"config": {
    "unsafe-perm":true
}

hlolli19:07:07

PR, 5 mins

anmonteiro19:07:46

@hlolli you can try it with sudo npm install .

anmonteiro19:07:50

if you cd packages/lumo

hlolli19:07:39

that's what I did, there I got an error which led me to the answer the error was

cannot run in wd

hlolli19:07:22

which led me to this answer, but this is in no way a descriptive error message

hlolli20:07:32

someone got instaparse running in lumo, I'm getting

ERROR in file instaparse/gll.cljc
	 (new)
	 Function.cljs.core.ex_info.cljs$core$IFn$_invoke$arity$3 (NO_SOURCE_FILE <embedded>:1935:200)
	 Function.cljs.analyzer.error.cljs$core$IFn$_invoke$arity$3 (NO_SOURCE_FILE <embedded>:2482:92)
	 (NO_SOURCE_FILE <embedded>:5947:100)
	 z (NO_SOURCE_FILE <embedded>:5948:13)
	 (NO_SOURCE_FILE <embedded>:5942:232)
	 (NO_SOURCE_FILE <embedded>:5862:482)
	 Object.cljs.js.load_macros (NO_SOURCE_FILE <embedded>:5838:464)
	 (NO_SOURCE_FILE <embedded>:5857:20)
	 Object.cljs.js.load_macros (NO_SOURCE_FILE <embedded>:5838:464)

hlolli20:07:32

https://clojars.org/com.lucasbradstreet/instaparse-cljs works, I file a ticket anyway, they are doing something wrong if they are claiming cljs compatability on instaparse (not -cljs).

futuro21:07:55

Anyone have suggestions on debugging cljs code in lumo?

futuro21:07:43

I've got a weird issue with some protocols that I'm trying to sort out