CLI Troubleshooting
1) Daemon connection issues
Symptoms:
- Runs hang on daemon connect.
- Errors mentioning socket/connect/request timeout.
Actions:
- Retry in verbose mode to capture details:
latdx test run -n MyTest -o my-org -v - Check daemon/cache state:
latdx cache status - Clear daemon/cache artifacts and retry:
latdx cache clear --all - Rerun the original command. Org mode can still fall back to direct core execution when daemon fails.
2) Org/package readiness issues
Symptoms:
- Package not installed/outdated errors.
- Org alias resolution issues.
Actions:
- Verify auth/default org:
sf org list - Pass explicit org alias:
For list mode:
latdx test run -n MyTest -o my-orglatdx test list -o my-org - Check package status quickly:
latdx --version -o my-org - If using source install mode, verify source path inputs (
LATDX_SF_SOURCE_PATH) and repo checkout.
3) Debug log storage exceeded
Symptoms:
- Error indicates debug log storage exceeded.
- Run stops before normal test results complete.
Actions:
- Accept CLI prompt to delete logs and retry when offered.
- If needed, rerun command and confirm cleanup prompt.
- Reduce repeated high-volume runs while diagnosing and use targeted test selection.
4) Compilation/test failures
Symptoms:
- Compile problems in output.
- Tests fail with stack traces or class/method errors.
Actions:
- Re-run with verbose output:
latdx test run -n MyTest -o my-org -v - Isolate execution strategy:
- Add
--sequential - Add
--fullSim
- Add
- Narrow scope to one test method:
latdx test run -t MyTest.testMethod -o my-org - If file mode, verify selected path exists and contains Apex test methods:
latdx test list -f force-app/main/default/classes/MyTest.cls
5) Input validation errors
Symptoms:
- Messages like:
Cannot use --class-names or --tests with --file or --dirCannot use --method with --dir or org mode
Actions:
- Choose exactly one input family per run:
- Org mode:
--class-namesor--tests(or no file/dir) - File mode:
--fileor--dir
- Org mode:
- Use
--methodonly with--file.
6) latdx: command not found
Symptoms:
- Shell returns
latdx: command not found.
Actions:
- Install the CLI binary as described in
docs/user/cli-quickstart.mdunderInstall the CLI Binary. - Open a new terminal session so PATH updates are reloaded.
- Verify:
latdx --help
7) Bypassing the automatic FLS/OLS grant
Symptoms:
- You manage
latdx_TestRunnerAccess(or an equivalent permset) yourself and want LATdx to stop deploying it. - The running user lacks permission to deploy metadata on a tightly controlled sandbox and you see a warning like
Test-runner access grant failed, continuing anyway: ....
Actions:
- Stop the daemon so the new env var is picked up on restart:
latdx daemon stop - Launch
latdx test runwith the opt-out env var:LATDX_SKIP_TEST_RUNNER_ACCESS=1 latdx test run -o my-org -n MyTest - If you need this consistently, export the var in your shell profile so every daemon spawn inherits it.
Notes:
- The grant is cached two ways (in-memory on the
LatdxCoreinstance and on disk at~/.latdx/runner-access/<orgId>.json). With the cache warm, the grant step adds well under a second per run. - If the org’s schema changes (custom object added/edited), LATdx detects the fingerprint change and regenerates the permset automatically on the next run.
- Deleting the org’s file under
~/.latdx/runner-access/forces a full regenerate on the next run.