You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm running opam init from a fresh Ubunutu virtual machine with just the bare dependencies installed. I get the following message, which suggests a problem in the way opam checks whether sandboxing works.
[ERROR] Sandboxing is not working on your platform ubuntu:
"~/.opam/opam-init/hooks/sandbox.sh build sh -c echo SUCCESS >/tmp/t &&
cat /tmp/t" exited with code 1
"/home/gscherer/.opam/opam-init/hooks/sandbox.sh: ligne 96:
OPAM_SWITCH_PREFIX : variable sans liaison"
My understanding is that opam init tries to check whether sandbox.sh works, but then the script fails because OPAM_SWITCH_PREFIX is undefined, which I expect is standard if opam init has not run ever yet on the machine. Interpreting this as a failure of sandboxing (and then suggesting that users disable it) looks like a UI bug to me; opam init should instead check sandboxing in a more robust way.
The opam config report output is as follows:
# opam config report
# opam-version 2.1.0~beta2
# self-upgrade no
# system arch=x86_64 os=linux os-distribution=ubuntu os-version=18.04
[ERROR] Opam has not been initialised, please run `opam init'
# read-state OpamStd.OpamSys.Exit(50)
The text was updated successfully, but these errors were encountered:
Ah, sorry for missing the two other issue reports (I did look for OPAM_SWITCH_PREFIX... and then did not use it in my own issue title), #4397 and #4368, and thanks for the quick triaging.
gasche
changed the title
opam init error (2.1.0~beta2) when checking sandboxing
opam init error (2.1.0~beta2) when checking sandboxing (OPAM_SWITCH_PREFIX: unbound variable)
Nov 5, 2020
I'm running
opam init
from a fresh Ubunutu virtual machine with just the bare dependencies installed. I get the following message, which suggests a problem in the way opam checks whether sandboxing works.My understanding is that
opam init
tries to check whethersandbox.sh
works, but then the script fails becauseOPAM_SWITCH_PREFIX
is undefined, which I expect is standard ifopam init
has not run ever yet on the machine. Interpreting this as a failure of sandboxing (and then suggesting that users disable it) looks like a UI bug to me;opam init
should instead check sandboxing in a more robust way.The
opam config report
output is as follows:The text was updated successfully, but these errors were encountered: