larksuite / larksuite/cli

macOS arm64: lark-cli binary fails with exit code 137 (SIGKILL)

Open
#165 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug domain/core
Dominant language
Go
Stars
17.3k
Forks
1.4k
Avg merge
2d 4h
Merged PRs (30d)
105

Description

lark-cli Binary Fails to Execute on macOS arm64 (Exit Code 137/SIGKILL)

Environment

  • OS: macOS 15.1 (Darwin 25.1.0) arm64
  • lark-cli version: v1.0.1
  • Node.js: v22.21.1
  • npm: 10.9.4
  • Installation method: npm global install
  • Architecture: Apple Silicon (arm64)

Description

After successfully installing @larksuite/cli via npm and running the postinstall script, the lark-cli binary fails to execute with exit code 137 (SIGKILL). The binary is killed by the system immediately upon execution without producing any output.

Steps to Reproduce

  1. Install lark-cli globally:
npm install -g @larksuite/cli
  1. Run postinstall script manually (as per issue #135):
cd ~/.nvm/versions/node/v22.21.1/lib/node_modules/@larksuite/cli
node scripts/install.js

Output: lark-cli v1.0.1 installed successfully

  1. Verify binary exists and is executable:
ls -la ~/.nvm/versions/node/v22.21.1/lib/node_modules/@larksuite/cli/bin/lark-cli
file ~/.nvm/versions/node/v22.21.1/lib/node_modules/@larksuite/cli/bin/lark-cli

Output:

-rwxr-xr-x  1 yang  staff  14846642 Mar 31 20:46 lark-cli
Mach-O 64-bit executable arm64
  1. Attempt to run any lark-cli command:
lark-cli --version
lark-cli --help
lark-cli config init

Expected Behavior

The command should display help text, version information, or start the configuration wizard.

Actual Behavior

  • The process exits immediately with code 137 (SIGKILL)
  • No output is produced on stdout or stderr
  • The process appears in ps briefly then disappears
  • No crash reports are generated in ~/Library/Logs/DiagnosticReports/

Additional Information

Binary Details
otool -L ~/.nvm/versions/node/v22.21.1/lib/node_modules/@larksuite/cli/bin/lark-cli

Output:

/usr/lib/libSystem.B.dylib (compatibility version 0.0.0, current version 0.0.0)
/usr/lib/libresolv.9.dylib (compatibility version 0.0.0, current version 0.0.0)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
/System/Library/Frameworks/Security.framework/Versions/A/Security
Attempted Solutions
  1. Tried downloading pre-built binary from GitHub releases:

    • Downloaded lark-cli-1.0.1-darwin-arm64.tar.gz
    • Same behavior (exit code 137)
  2. Attempted source build:

    • Encountered SSL certificate verification error during make install
    • Compiled binary exhibits same exit code 137 behavior
  3. Checked for quarantine attributes:

    • No com.apple.quarantine attribute found
    • spctl --assess rejects the binary
  4. Skills installation successful:

    • npx skills add larksuite/cli -y -g completed successfully
    • All 19 skills installed to ~/.agents/skills/

Exit Code 137 Context

Exit code 137 = 128 + 9 = SIGKILL, which typically indicates:

  • The process was forcibly terminated by the system
  • Possible code signing issues
  • Possible compatibility issues with the macOS version
  • Security restrictions preventing execution

Related Issues

  • Issue #135: pnpm installation requires manual postinstall (similar installation flow issue)
  • Issue #70: macOS token persistence issues (macOS-specific behavior)
  • Issue #122: Silent failures on macOS arm64 environment

Workaround Needed

Is there:

  1. A known issue with code signing for the macOS arm64 binary?
  2. An alternative installation method that works on macOS 15.x?
  3. Any additional configuration needed for the binary to execute?

System Details

# macOS Version
sw_vers

Output:

ProductName:		macOS
ProductVersion:		15.1
BuildVersion:		24B83
# Architecture
uname -m

Output: arm64

# Go version (for reference)
go version

Output: go version go1.25.7 darwin/arm64


The skills package installed successfully, but the CLI binary itself cannot be used. Any guidance would be appreciated!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with the published arm64 binary and inspect scripts/install.js, the binary path, and the reported macOS execution and signing checks. Compare the release and source-built binaries to identify why macOS 15.1 terminates them with SIGKILL; done means lark-cli runs and produces output on the reported arm64 environment.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, macos
Domain
cli, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.