If I can get a reliable big report that would help...
# pact-go
m
If I can get a reliable big report that would help. I use M1 exclusively now but on Rosetta mode (because there are just so many inconveniences otherwise)
h
if this was a reply for https://pact-foundation.slack.com/archives/C9UTHTFFB/p1661444633201449, then what sort of information would be help? eg, what a big report?
If I can get a reliable big report that would help.
m
I think: • A dump of the go environment • A report of what the
pact go install
command returns with verbose enabled (try removing the
~/.pact
dir and any existing lib) • Try also a
file /use/local/lib/libpact_ffi.dylib
h
hey matt, i'll write up some instructions for our developer to try and reproduce. however, while running on my mac, i noticed this error
Copy code
2022/08/25 16:18:11 [ERROR] Your Pact library installation is out of date and we were unable to download a newer one for you: open /Users/me/.pact/pact-go.yml: permission denied
curious if this line s/b
0755
instead. i dont think this relates to the underlying problem tho. just an annoying error instead
🙏 1
m
good spot, it probably should!
thanks
h
here's some more info without having rerun pact go install
Copy code
####
go env
GO111MODULE="on"
GOARCH="arm64"
GOBIN=""
GOCACHE="/Users/dev/Library/Caches/go-build"
GOENV="/Users/dev/Library/Application Support/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="arm64"
GOHOSTOS="darwin"
GOINSECURE=""
GOMODCACHE="/Users/dev/go/pkg/mod"
GONOPROXY="<http://bitbucket.org/dev/*,bitbucket.org/dev/*export|bitbucket.org/dev/*,bitbucket.org/dev/*export>"
GONOSUMDB="<http://bitbucket.org/acme/*,bitbucket.org/dev/*export|bitbucket.org/acme/*,bitbucket.org/dev/*export>"
GOOS="darwin"
GOPATH="/Users/dev/go"
GOPRIVATE="<http://bitbucket.org/acme/*,bitbucket.org/dev/*export|bitbucket.org/acme/*,bitbucket.org/dev/*export>"
GOPROXY="<https://proxy.golang.org>,direct"
GOROOT="/opt/homebrew/Cellar/go@1.17/1.17.11/libexec"
GOSUMDB="<http://sum.golang.org|sum.golang.org>"
GOTMPDIR=""
GOTOOLDIR="/opt/homebrew/Cellar/go@1.17/1.17.11/libexec/pkg/tool/darwin_arm64"
GOVCS=""
GOVERSION="go1.17.11"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD="/Users/dev/code/fun-engine/go.mod"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/9d/j7s32bkx70j85cchpy1fvdvc0000gn/T/go-build945175549=/tmp/go-build -gno-record-gcc-switches -fno-common"
####
sudo file /usr/local/lib/libpact_ffi.dylib
/usr/local/lib/libpact_ffi.dylib: Mach-O 64-bit dynamically linked shared library arm64
curious what's the best way to re-run the install? is this good
Copy code
rm -rf ~/.pact && pact-go -v -l DEBUG install
m
there is a
-f
flag I think to force the reinstall
h
more info on install
Copy code
rm -rf ~/.pact && pact-go -v -l DEBUG install -f
2022/08/26 09:59:16 [INFO] downloading library from <https://github.com/pact-foundation/pact-reference/releases/download/libpact_ffi-v0.3.8/libpact_ffi-osx-aarch64-apple-darwin.dylib.gz> to /usr/local/lib/libpact_ffi.dylib
2022/08/26 09:59:17 [ERROR] Your Pact library installation is out of date and we were unable to download a newer one for you: open /usr/local/lib/libpact_ffi.dylib: permission denied
dylib file info
Copy code
ls -l  /usr/local/lib/libpact_ffi.dylib
-rw-------  1 root  wheel  19531936 Aug 25 10:39 /usr/local/lib/libpact_ffi.dylib
and
Copy code
stat -f %A /usr/local/lib/libpact_ffi.dylib
600
my none m1 mac is
622
m
Strange that
/usr/local/lib/libpact_ffi.dylib
is root -
/usr/local/lib
is editable by me on my M1 and I’m positive I haven’t changed those perms from the default. Did you run the install with
sudo
or manually drop the file there?
It looks like it couldn’t overwrite the existing library. I think you’re right in that the perm need adjusting though.
Also I was hopinsg for a
file
on the dylib so I could see what the architecture etc. was, but I think it won’t be too helpful until we’ve removed the existing file and reliably can get pact-go to install it for you
h
the instructions i passed off to developers did not include
sudo
, they have since tried using that as well
but still same occurs.
yeah, i think re-install is somewhat a separate but tangentially related issue. the initial issue is after original install the error is
can't open file, errno=13 file '/usr/local/lib/libpact_ffi.dylib' for architecture arm64
which seems like the permission issue to read the file after install