x-motemen / gore

Yet another Go REPL that works nicely. Featured with line editing, code completion, and more.
MIT License
5.11k stars 148 forks source link

Cannot launch on Mac M1 #225

Closed worm2fed closed 11 months ago

worm2fed commented 11 months ago

Hi!

I've tried gore, but cannot even execute help command.

❯ gore
[1]    5568 killed     gore

❯ gore --help
[1]    5559 killed     gore --help

Here is my machine:

❯ uname -a
Darwin vega.Home 23.1.0 Darwin Kernel Version 23.1.0: Mon Oct  9 21:27:24 PDT 2023; root:xnu-10002.41.9~6/RELEASE_ARM64_T6000 arm64

Installation was direct, via go install

itchyny commented 11 months ago

I can run on M1 mac. Need more information.

 $ uname -a
Darwin itchyny-MacBook-Pro.AirPort 23.1.0 Darwin Kernel Version 23.1.0: Mon Oct  9 21:28:12 PDT 2023; root:xnu-10002.41.9~6/RELEASE_ARM64_T8103 arm64

 $ gore
gore version 0.5.6  :help for help
gore> 42
42
gore> :q
worm2fed commented 11 months ago

not sure what to add, just installed go via official installer

❯ go version
go version go1.21.3 darwin/arm64
itchyny commented 11 months ago

Who kills the gore process? OOM or some security software?

worm2fed commented 11 months ago

There is no chance that I'm running out of memory, I have a lot. And I do not have security software, except build-in. here is some info from dmesg

❯ sudo dmesg | grep gore
Process (/Users/worm2fed/go/bin/gore) allowed via dev tool environment (/Applications/iTerm.app/Contents/MacOS/iTerm2)CODE SIGNING: cs_invalid_page(0x102dfc000): p=6143[gore] final status 0x23020200, denying page sending SIGKILL
[399324.558919]: CODE SIGNING: process 6143[gore]: rejecting invalid page at address 0x102dfc000 from offset 0x4000 in file "/Users/worm2fed/go/bin/gore" (cs_mtime:1699005474.553147593 == mtime:1699005474.553147593) (signed:1 validated:1 tainted:1 nx:0 wpmapped:0 dirty:0 depth:0)
[399324.559280]: CODE SIGNING: process 6143[gore]: rejecting invalid page at address 0x102dfc000 from offset 0x4000 in file "/Users/worm2fed/go/bin/gore" (cs_mtime:1699005474.553147593 == mtime:1699005474.553147593) (signed:1 validated:1 tainted:1 nx:0 wpmapped:0 dirty:0 depth:0)
[399324.559303]: gore[6143] Corpse allowed 2 of 5
itchyny commented 11 months ago

Can you check if resigning works?

codesign -f -s - "$(which gore)"
worm2fed commented 11 months ago

wow, after that I can run gore thanks!