Errors & Diagnostics

Complete error reference — exit codes, error defines, error messages with resolutions, and diagnostic tools for debugging ScorpioX Code.

1,906
Total Errors
7
Exit Codes
54
Error Defines
6
Categories

Exit Codes

Code Meaning
0 success
1 general error
2 usage/config error
3 clone/operation failure (vault-git)
4 export failure (vault-git)
127 exec failed (child process could not execvp)
128 signal base (128+N = killed by signal N)

Error Defines

Name Value Source
SX_ERR_NOMEM -1
SX_ERR_NOT_FOUND -2
SX_ERR_DOWNLOAD_FAILED -3
SX_ERR_VERIFY_FAILED -4
SX_ERR_EXECUTE_FAILED -5
SX_ERR_INVALID_BRIDGE -6
SX_FRP_ERR_NOMEM -1
SX_FRP_ERR_CONNECT -2
SX_FRP_ERR_AUTH -3
SX_FRP_ERR_PROTOCOL -4
SX_FRP_ERR_PROXY -5
SX_FRP_ERR_IO -6
SX_FRP_ERR_TIMEOUT -7
SX_FRP_ERR_CONFIG -8
SX_FRP_ERR_SHUTDOWN -9
SX_HTTP_ERR_NOMEM -1
SX_HTTP_ERR_INIT -2
SX_HTTP_ERR_NETWORK -3
SX_HTTP_ERR_TIMEOUT -4
SX_HTTP_ERR_CANCELLED -5
SX_HTTP_ERR_NOTSUP -6
SX_HTTP_INTERNAL_ERROR 500
SX_EXEC_ERR_NOMEM -1
SX_EXEC_ERR_SPAWN -2
SX_EXEC_ERR_TIMEOUT -3
SX_EXEC_ERR_NOTSUP -4
SX_TCP_ERR_CONNECT -1
SX_TCP_ERR_AUTH -2
SX_TCP_ERR_NODATA -3
SX_TCP_ERR_ALLHOSTS -4
SX_TCP_ERR_BADARG -5
SX_WSL_ERR_NOT_SUPPORTED -1
SX_WSL_ERR_NOT_INSTALLED -2
SX_WSL_ERR_REGISTER -3
SX_WSL_ERR_UNREGISTER -4
SX_WSL_ERR_LAUNCH -5
SX_WSL_ERR_ALREADY_EXISTS -6
SX_WSL_ERR_NOT_FOUND -7
SX_WSL_ERR_INVALID_TAR -8
SX_WSL_ERR_TIMEOUT -9
SX_WSL_ERR_CANCELLED -10
SX_WSL_ERR_API_LOAD -11
EXIT_OK 0
EXIT_ERRORS 1
EXIT_CONFIG_ERR 2
EXIT_OK 0
EXIT_ERRORS 1
EXIT_CONFIG_ERR 2
EXIT_OK 0
EXIT_ARGS 1
EXIT_INSTALL 2
EXIT_CLONE 3
EXIT_EXPORT 4
SX_COLOR_ERROR 0

Error Messages by Category

🔒
auth
108 errors
⚙️
config
103 errors
📁
filesystem
297 errors
🌐
network
314 errors
🤖
provider
122 errors
💥
runtime
962 errors

🔒 auth 108

Code Message Cause Resolution Source
1 [frp] login failed: <string> Operation failed Verify authentication credentials scorpiox/libsxnet/sx_frp.c
1 anthropic: load_env auth=<string> key=<string> url=<string> model=<string> streaming=<number> thinking=<number> tools=<number> Warning in sx_provider_anthropic.c Verify authentication credentials scorpiox/libsxnet/sx_provider_anthropic.c
1 Failed to run fetchtoken command: <string> Error in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 Failed to spawn fetchtoken: <string> Error in sx_provider_claude_code.c Check system resources (process limits) scorpiox/libsxnet/sx_provider_claude_code.c
1 HTTP 401 after token refresh - authentication permanently failed Error in sx_provider_claude_code.c Re-authenticate to get a fresh token scorpiox/libsxnet/sx_provider_claude_code.c
1 HTTP 401: OAuth token likely expired, refreshing and retrying... Warning in sx_provider_claude_code.c Re-authenticate to get a fresh token scorpiox/libsxnet/sx_provider_claude_code.c
1 HTTP 403: possible token issue, refreshing token before retry... Warning in sx_provider_claude_code.c Re-authenticate to get a fresh token scorpiox/libsxnet/sx_provider_claude_code.c
1 No access_token in fetchtoken output Error in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 No output from fetchtoken Error in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 No output from fetchtoken (exit=<number>) Error in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 claude_code: OAuth refresh failed, falling back to file read Warning in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 claude_code: init token_mode=<number> exe_dir=<string> Warning in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 claude_code: loading token (first API call) Warning in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 claude_code: token loaded ok Warning in sx_provider_claude_code.c Verify authentication credentials scorpiox/libsxnet/sx_provider_claude_code.c
1 claude_code: token refresh failed after 401 Error in sx_provider_claude_code.c Re-authenticate to get a fresh token scorpiox/libsxnet/sx_provider_claude_code.c
Show 93 more errors ▼

⚙️ config 103

Code Message Cause Resolution Source
1 HOME env not set Required condition not met Review configuration settings scorpiox/libsxbridge/sx_bridge.c
1 agent: CONTEXT_AUTO_COMPACT=<number> (from config) Warning in sx_agent.c Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_agent.c
1 agent: CONTEXT_CLEAR_THRESHOLD=<number> (from config) Warning in sx_agent.c Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_agent.c
1 agent: CONTEXT_WARN_THRESHOLD=<number>%% (from config) Warning in sx_agent.c Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_agent.c
1 mcp: MCP_FILE=<string> (from config) Warning in sx_mcp.c Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_mcp.c
1 mcp: MCP_FILE=<string> (from env) Warning in sx_mcp.c Review configuration settings scorpiox/libsxnet/sx_mcp.c
1 state: reloading config Warning in sx_state.c Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_state.c
1 Resolved branch from index.txt: <string> Warning in sx_config.c Review configuration settings scorpiox/libsxutil/sx_config.c
1 config: cannot open <string> for reading Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: cannot open <string> for writing Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: cannot write \xe2\x80\x94 exe_dir not set Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: cannot write global \xe2\x80\x94 exe_dir not set Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: cannot write user \xe2\x80\x94 HOME not set Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: embedded config loaded, count=<number> Warning in sx_config.c Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
1 config: exe_dir=\ Warning in sx_config.c Review scorpiox-env.txt configuration scorpiox/libsxutil/sx_config.c
Show 88 more errors ▼

📁 filesystem 297

Code Message Cause Resolution Source
1 Failed to create tmp directory Error in sx_bridge.c Check file paths and permissions scorpiox/libsxbridge/sx_bridge.c
1 Failed to open SHA256 checksum file Error in sx_bridge.c Check file paths and permissions scorpiox/libsxbridge/sx_bridge.c
1 Failed to read SHA256 checksum file Error in sx_bridge.c Check file paths and permissions scorpiox/libsxbridge/sx_bridge.c
1 Invalid path: <string> Error in sx_bridge.c Check file paths and permissions scorpiox/libsxbridge/sx_bridge.c
1 mkdir failed: <string>: <string> Error in sx_bridge.c Check file paths and permissions scorpiox/libsxbridge/sx_bridge.c
1 agent: ReadImage validation failed for '<string>' Warning in sx_agent.c Check file paths and permissions scorpiox/libsxnet/sx_agent.c
1 agent: no provider available (sx_state not initialized?) Required condition not met Check file paths and permissions scorpiox/libsxnet/sx_agent.c
1 agent: plan mode exited, plan_just_exited=true, plan_file=<string> Warning in sx_agent.c Check file paths and permissions scorpiox/libsxnet/sx_agent.c
1 agent: using provider '<string>' from sx_state Warning in sx_agent.c Check file paths and permissions scorpiox/libsxnet/sx_agent.c
1 mcp: cannot create temp file: <string> Required condition not met Check file paths and permissions scorpiox/libsxnet/sx_mcp.c
1 mcp: run 'scorpiox-mcp --mcp-file <string> discover --json' to debug Warning in sx_mcp.c Check file paths and permissions scorpiox/libsxnet/sx_mcp.c
1 mcp: sx_popen_no_window failed: <string> Error in sx_mcp.c Check file paths and permissions scorpiox/libsxnet/sx_mcp.c
1 using no-op provider (static, no heap allocation) Warning in sx_provider.c Free up system memory or reduce workload scorpiox/libsxnet/sx_provider.c
1 openai-proxy: <string> Warning in sx_provider_openai.c Check file paths and permissions scorpiox/libsxnet/sx_provider_openai.c
1 openai: failed to allocate provider data Error in sx_provider_openai.c Free up system memory or reduce workload scorpiox/libsxnet/sx_provider_openai.c
Show 282 more errors ▼

🌐 network 314

Code Message Cause Resolution Source
1 error: -d requires HOST:PORT Error in ws2tcp.c Check network connectivity and server availability bridge/ws2tcp.c
1 Bridge execution not yet supported on Windows Required condition not met Check network connectivity and server availability scorpiox/libsxbridge/sx_bridge.c
1 Download URL: <string>/<string> Warning in sx_bridge.c Check network connectivity and server availability scorpiox/libsxbridge/sx_bridge.c
1 wasm_tools: ReadDocs url=<string> format=<string> Warning in sx_agent_tools_wasm.c Check network connectivity and server availability scorpiox/libsxnet/sx_agent_tools_wasm.c
1 HTTP <number> (retryable), retry <number>/<number> in <number>ms... Warning in sx_claude.c Check network connectivity and server availability scorpiox/libsxnet/sx_claude.c
1 claude: HTTP error <number> after <number> attempts Error in sx_claude.c Check network connectivity and server availability scorpiox/libsxnet/sx_claude.c
1 claude: HTTP error: <string> Error in sx_claude.c Check network connectivity and server availability scorpiox/libsxnet/sx_claude.c
1 claude: ROUTER_URL not configured (set in scorpiox-env.txt) Required condition not met Review scorpiox-env.txt configuration scorpiox/libsxnet/sx_claude.c
1 [frp] TLS handshake failed: <string> Operation failed Check network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] TLS: warning: no system CA bundle found Error in sx_frp.c Check network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] connect failed: <string> Operation failed Verify network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] crypto init failed: <string> Operation failed Check network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] disconnected: <string> Error in sx_frp.c Verify network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] failed to read StartWorkConn (slot <number>, type=0x<hex> rc=<number>) Operation failed Check network connectivity and server availability scorpiox/libsxnet/sx_frp.c
1 [frp] local closed (slot <number>) Error in sx_frp.c Check network connectivity and server availability scorpiox/libsxnet/sx_frp.c
Show 299 more errors ▼

🤖 provider 122

Code Message Cause Resolution Source
1 claude: INVALID JSON at byte <number>/<number>: <string> Error in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 claude: failed to build JSON request Error in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 claude: failed to parse response JSON Error in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 claude: json context: <string> Error in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 claude: request cancelled by user Warning in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 claude: send started, model=<string> history=<number> Warning in sx_claude.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_claude.c
1 failed to allocate provider Error in sx_provider.c Free up system memory or reduce workload scorpiox/libsxnet/sx_provider.c
1 provider init failed for '<string>' Error in sx_provider.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider.c
1 unknown provider type: <number> Error in sx_provider.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider.c
1 unknown provider: <string> Error in sx_provider.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider.c
1 anthropic: INVALID JSON at byte <number>/<number>: <string> Error in sx_provider_anthropic.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider_anthropic.c
1 anthropic: antigravity model mapping: <string> -> <string> Warning in sx_provider_anthropic.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider_anthropic.c
1 anthropic: failed to allocate provider data Error in sx_provider_anthropic.c Free up system memory or reduce workload scorpiox/libsxnet/sx_provider_anthropic.c
1 anthropic: history required <number> fixes before send Warning in sx_provider_anthropic.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider_anthropic.c
1 anthropic: init ok exe_dir=<string> Warning in sx_provider_anthropic.c Verify provider configuration and API credentials scorpiox/libsxnet/sx_provider_anthropic.c
Show 107 more errors ▼

💥 runtime 962

Code Message Cause Resolution Source
1 error: need at least -t, -d, or -w Error in ws2tcp.c See log output for details and retry bridge/ws2tcp.c
1 Aborting download: SHA256 verification failed Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Bridge killed by signal <number> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Bridge version: <string> Warning in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Failed to download bridge binary from <string>/<string> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Failed to install bridge: <string> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Failed to make binary executable Error in sx_bridge.c Verify the executable exists and is in PATH scorpiox/libsxbridge/sx_bridge.c
1 Invalid SHA256 hash format (expected 64 hex chars, got <number>) Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Out of memory Error in sx_bridge.c Free up system memory or reduce workload scorpiox/libsxbridge/sx_bridge.c
1 SHA256 MISMATCH for <string> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 SHA256 checksum not available — aborting download for security Required condition not met See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 SHA256 verified: <string> Warning in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 Unknown platform, auto-download may fail Warning in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 computed: <string> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
1 expected: <string> Error in sx_bridge.c See log output for details and retry scorpiox/libsxbridge/sx_bridge.c
Show 947 more errors ▼

Diagnostics

Debug Flag
--verbose (most subcommands)
Verbose Flag
--verbose
Config Key
Config File
Log Output
Log Levels
ERROR WARN INFO DEBUG TRACE