Skip to main content

Common Errors

Authentication Errors

Error:
Cause: You haven’t set up authentication yet.Solution:
Choose authentication method and follow prompts.
Error:
Causes:
  • Key was revoked
  • Key was copied incorrectly
  • Extra spaces in key
Solutions:
  1. Verify you copied the complete key
  2. Remove any extra spaces
  3. Generate new key via email method:
Problem: Email OTP code not receivedSolutions:
  1. Check spam/junk folder
  2. Wait 5 minutes (can be delayed)
  3. Try again with lua auth configure
  4. Use API Key method if available

Project Initialization Errors

Error:
Cause: You’re not in a skill project directory.Solution:
  1. Navigate to your skill directory:
  2. Or initialize a new project:
Error:
Cause: lua init requires an empty directory.Solution:
Error:
Solutions:
  • Check directory permissions
  • Don’t use sudo (creates permission issues later)
  • Use a directory you own:

Compilation Errors

Error:
Cause: Missing main skill file.Solution: Create src/index.ts:
Error:
Cause: TypeScript type error in your code.Solution: Fix the specific error mentioned:
Error:
Cause: Dependencies not installed.Solution:
Error:
Cause: Tool name contains invalid characters.Solution: Fix tool name:

Version Management Errors

Error:
Cause: You’ve already pushed this version number.Solution: Increment the version number in lua.skill.yaml (this is the only field you should manually edit):
Then push again:
Error:
Cause: Changed version but didn’t recompile.Solution: Recompile after version change:

Sync Errors

Message:
Cause: Server has different agent configuration than your local code. This happens when someone updates the agent from the admin dashboard.Solutions:
  1. Run sync: Use lua sync to review and resolve drift interactively
  2. Auto-accept: Use lua sync --accept to automatically update local from server
  3. Auto-push: Use lua sync --push to push local changes to server
Note: By default, lua compile does NOT check for drift. Use lua compile --sync to enable drift detection during compilation.To see the diff:
Message:
Cause: The LuaAgent configuration is missing or has an empty name.Solutions:
  1. Ensure your src/index.ts has a valid LuaAgent:
  2. Check for TypeScript compilation errors
Problem: Sync silently fails or shows no drift when there should be.Cause: Network issues when fetching server state.Solutions:
  1. Check internet connection
  2. Verify API key is valid: lua auth key
  3. Try again: lua sync

Dev Mode Errors

Error:
Cause: Port 3000 is being used by another process.Solutions:
  1. Stop the other process
  2. Or kill process on port 3000:
Error:
Cause: Skill hasn’t been pushed to server yet.Solution:
Problem: Local changes not showing in sandbox mode.Solutions:
  1. Verify file is in src/ directory
  2. Check file is actually saved
  3. Ensure you selected “Sandbox” mode in lua chat
  4. Check for compilation errors
  5. Try again:

Deployment Errors

Error:
Cause: You haven’t pushed any versions yet.Solution:
Error:
Solutions:
  1. Check API key is valid
  2. Verify you have deploy permissions
  3. Check network connection
  4. Try again - might be temporary server issue

Debugging Skills at Runtime

When your tool returns unexpected data or you’re unsure why a skill is behaving incorrectly, use this workflow.
Symptoms:
  • Field is undefined when you expected a value
  • results.data is undefined
  • results.count is undefined
  • Properties like entry.title return undefined
The fix — log before you transform:
Common causes:
  • Using results.data after Data.search — search returns a flat array, not { data: [...] }
  • Using results.count after Data.search — use results.length
  • Using entry.title after Data.get — get entries are not proxied, use entry.data.title
  • Using results.data after Products.search — use results.products or iterate directly
See the Return Shape Reference and Debugging guide.
  1. Add console.log('result:', JSON.stringify(result, null, 2)) to the suspicious spot
  2. Run lua push (or use lua chat sandbox mode without pushing)
  3. Send ONE test message: lua chat -m "your test query"
  4. Run lua logs --type skill --limit 10 — find your log entry
  5. Read the actual shape, fix code once, verify
Don’t deploy 5 times trying to patch blind. Log first, deploy once.Full debugging guide →
Your console.log() output appears in the log message body under 🔍 DEBUG entries.

Platform-Specific Issues

macOS

Error: Permission denied accessing keychainSolution: Grant Terminal/iTerm access:
  1. System Preferences → Security & Privacy
  2. Privacy → Automation
  3. Enable Terminal for Keychain Access
  4. Restart terminal
Cause: CLI not in PATHSolutions:
  1. Reinstall globally:
  2. Or use npx:

Windows

Error: Script execution disabledSolution: Enable script execution:
Error: ENAMETOOLONGSolution: Use shorter directory paths:

Linux

Error: Cannot find libsecretSolution: Install libsecret:
Error: Permission denied on global installSolution: Configure npm to install globally without sudo:

Node.js Issues

Error: Requires Node.js >= 16.0.0Solution: Update Node.js:
  1. Visit https://nodejs.org
  2. Download LTS version
  3. Or use nvm:
Warning: Package deprecated warningsSolution: Usually safe to ignore deprecated warnings from dependencies. Update if issues occur:
Error: Conflicting peer dependenciesSolution: Clear cache and reinstall:

Network Issues

Error: ETIMEDOUT or ECONNREFUSEDSolutions:
  1. Check internet connection
  2. Check if behind firewall/proxy
  3. Try again - might be temporary
  4. Check server status
Error: UNABLE_TO_VERIFY_LEAF_SIGNATURESolutions:
  1. Check system date/time is correct
  2. Update CA certificates
  3. If behind corporate proxy, may need proxy config
Problem: Behind corporate proxySolution: Configure npm proxy:

Environment Variable Issues

Problem: env('MY_VAR') returns undefinedSolutions:
  1. Check spelling in .env file:
  2. Ensure .env is in project root
  3. Restart command (variables loaded at startup)
  4. Check lua.skill.yaml:
Problem: Updated .env but changes not visibleSolution: Restart the CLI command:
Or manage variables with:

Getting Help

Diagnostic Information

When reporting issues, include:

Support Channels

Discord Community

Get real-time help from the community

Documentation

Search these docs first

Email Support

Contact support team

Prevention Tips

Or check current version:
Always commit lua.skill.yaml to git:
Add to .gitignore:
Always test locally:

Still Having Issues?

If your issue isn’t covered here:
  1. Ask on Discord: Get real-time help from the community
  2. Email Support: For urgent issues or account problems

Discord Community

Join other Lua builders for real-time help

Contact Support

[email protected] - We’re here to help!