Reference

Errors

Every error land can give, what it means and the exact fix. Each error links to its entry here.

Every error land gives has a docs link to its entry on this page, and the CLI prints it on a docs: line under fix:.

Merge refusals

A branch that does not land comes back in refused with a why. See Reading a verdict for the rest of the answer.

tests_failed

A test that passes on your target fails on the merged code, and land traced the failure to this branch. failing names the test and its assertion, hitBy names another branch it clashes with, and repro gives a commit and a command that show the same failure.

Fix. Read failing[].assert, fix the code the test uses, check it with the repro command, then run land merge again.

conflict

This branch and what landed before it (or the target itself) changed the same function or the same lines, and land could not combine them. conflict.with says which one, and conflict shows the base, the landed version and yours.

Fix. Rewrite your version on top of the one that landed, commit it, then run land merge again.

collection

The tests could not load on the merged code, for example after an import error or a syntax error, or the test command found no tests at all. The detail says what failed.

Fix. Fix the error the detail names, then run land merge again.

policy

The branch changes the owner's tests or test settings (files lists them), or it leaves .land/tests in a state land cannot read. A target whose .land/tests cannot be read refuses every branch this way.

Fix. Revert the edits to the tests. If the owner wants merges to change tests, the owner runs land add --allow-test-edits. For an unreadable .land/tests, make the change the detail asks for and commit it.

dependencies

The branch changes dependency files and the new dependencies would not install. land add refuses with this too when the repository has no .land/setup.sh or its setup does not install.

Fix. Fix the dependency files, or add the missing tool to .land/setup.sh, then run land merge again. See Tests and environment.

env

land could not build the environment to run the tests in. The target's own dependencies did not install, or the other branches' run failed first so this one was not checked. In land add it means the test command could not even start in land's environment (exit 126 or 127), so no test ran.

Fix. This is not your change. Run the same command again. If the target's dependencies are what fails, fix .land/setup.sh on the target. In land add, make sure the test command starts the right tool.

timeout

The check ran past its time limit (the detail says the limit in seconds), or every failing test was cut off at its own limit. land stores nothing from such a run.

Fix. Run land merge again. If it keeps timing out, raise the limit with land add --time-limit SECONDS or split slow commands into several lines of .land/tests.

oom

The kernel killed a process of the check for memory, or refused one at a process limit, so the run says nothing about your code. The detail names the tests and what the run measured.

Fix. Give the test that needs more room its own memory on its line in .land/tests by ending it with ;; mem=GB, or more CPUs with ;; cpu=N, commit, then run land merge again.

flaky

A test failed in the merge and then passed when land ran it again alone on the same code. Nothing lands and no branch is blamed. The detail gives both runs' times and how busy the machine was.

Fix. Make the test give the same answer every run (a fixed seed, no timing assumptions, no shared state), then run land merge again.

dirty

A branch's worktree on your machine has uncommitted or untracked files, which would not be merged. land merge stops before it sends anything (exit 1).

Fix. Commit the work in that worktree (the fix line prints the command), then run the same merge again.

no_plan (HTTP 402)

Your account has no plan, or this month's free minutes are used up. Nothing was checked and your branches are untouched.

Fix. Add a card or pick a plan on your dashboard (the pay link in the answer goes there), then run land merge again.

trial_ended (HTTP 402)

The same as no_plan, from older servers. The free trial has ended.

Fix. Add a card on your dashboard, then run land merge again.

token_scope (HTTP 403)

A LAND_TOKEN tried something it may not do. A token can only merge, wait and verify, and only on the repositories it names.

Fix. Run that command with your own login (land login), or mint a token for this repository on the dashboard. See Land from CI.

Add refusals

When land add does not add the repository, its answer has refused, needs or error. It can also refuse with dependencies, env, collection, timeout or oom, which mean the same as in a merge.

nothing_passes

No test command passes on the target, so land would guard nothing. This usually means the environment is missing something.

Fix. Read failing[].assert, fix .land/setup.sh or the test commands, then run land add again.

low_guard

Some tests already fail on the target when you first add the repository (or change its tests). land refuses so that a broken baseline is never accepted by accident.

Fix. Fix those tests on the target. If they really do fail there and you accept it, run the retry command land printed, which ends in --allow-low-guard.

needs: setup_script

The repository has no .land/setup.sh and its CI workflows give no setup steps, so land does not know how to install what the tests need.

Fix. Commit a .land/setup.sh that installs what your tests need, push it, then run land add again. See Recipes.

needs: test_command

The repository was added by an older land that picked tests per language. land now runs exactly the commands you name.

Fix. land add --test '<command>' --json

bad_cpus

--cpus names a size land does not offer. A repository runs on 2, 4, 8 or 16 vCPU.

Fix. land add --cpus 4 (or 2, 8 or 16). A line of .land/tests can pick its own size with ;; cpu=16.

bad_test_command

A --test value is empty or cannot be read as a command or a line of .land/tests.

Fix. land add --test '<one command>', or several as --test 'name=<command>'.

bad_tests_file

The committed .land/tests has a line land cannot read. The message names the line.

Fix. Edit .land/tests so each line is name folder files command or name folder - command, commit it, then run land add again. See The .land/tests file.

bad_workflow

land read the tests from your CI workflows and one of them could not be read.

Fix. Fix the workflow file the message names, commit it, then run land add again. Or name the tests yourself with --test.

bad_adapter

A file in .land/adapters/ could not be read.

Fix. Fix the file in .land/adapters/ the message names, commit it, then run land add again.

no_inspect

The server is missing inspect, the tool land checks every command with. This only happens on a self-hosted server.

Fix. Ask the operator to install it (upgrade-land.sh --inspect).

API errors

An HTTP answer that is an error carries {"error": {"code", "message", "docs"}}, or for the git routes just a status.

unauthorized (401)

The request had no key, or the Authorization header was not a Bearer key.

Fix. Run land login, or set LAND_TOKEN to a token from the dashboard.

invalid_api_key (401)

The key is unknown or was revoked.

Fix. land login --logout && land login, or mint a new token on the dashboard.

forbidden (403)

The key is valid but may not do this, for example a repository on another account or an organization action that needs an admin. The message says which.

Fix. Sign in as the account that owns the repository, or ask an admin of the organization.

rate_limited (429)

Too many requests in a short time.

Fix. Wait the seconds the message gives, then try again.

bad_request (400)

The request was malformed or asked for something that cannot be done. The message says what was wrong.

Fix. Change the request as the message says.

entity_not_found (404)

The thing the request names does not exist, such as an organization or a member.

Fix. Check the name and try again.

internal_error (500)

Something failed on land's side.

Fix. Try again. If it repeats, tell us with the command you ran.

unknown_repository (404)

No repository by that name is on this account or this plane. It was never added, or the name is misspelled.

Fix. Check the name with land status, or run land add in the repository.

secret_refused (400)

land did not store the secret. The message says why.

Fix. Fix what the message names and set it again. See Databases, network and secrets.

secrets_refused (400)

land could not list or remove the repository's secrets. The message says why.

Fix. Fix what the message names, then run land secret list or land secret rm again.

runners_refused (400)

land could not list, add or revoke the repository's own runners. The message says why.

Fix. Fix what the message names and try again from the dashboard.

bad_event (400)

A self-hosted plane sent an event land could not read. Other events in the same batch are still stored.

Fix. Upgrade the plane to the current land.

event_too_large (413)

A self-hosted plane sent an event over the size limit, which the answer gives in limit.

Fix. Upgrade the plane to the current land, which keeps its events small.

HTTP 401

A git or land route got no key or a key land does not accept. The body is empty.

Fix. Run land login, or check LAND_TOKEN.

HTTP 403

The key may not change this repository's settings, secrets or runners. Only its owner can.

Fix. Run the command signed in as the repository's owner.

HTTP 404

The repository is not on your account, or the route does not exist. land answers 404 rather than saying whose repository it is.

Fix. Check the repository name, and run land add if it was never added.

HTTP 409

Your land CLI is too old for a repository that your own data plane offers.

Fix. curl -fsSL https://useland.dev/install.sh | sh

HTTP 413

A request body was larger than land accepts.

Fix. Upload less, for example by committing generated or vendored files less often, then try again. land add --dry-run shows what would upload.

HTTP 421

This repository's code lives on its data plane, not in land's cloud. plane in the answer gives the plane's address.

Fix. Upgrade land so the CLI goes to the plane by itself. See Self-hosting.

HTTP 502

The engine behind the server gave an answer that could not be read.

Fix. Run the same command again. If it repeats, tell us.

HTTP 503

land is busy or could not reach its accounts right now. Nothing was decided.

Fix. Run the same command again in a minute.

Exit codes

What the land command's exit status means, for scripts and agents.

exit 0

Every branch landed, or the command did what it was asked.

Fix. Run the printed local.push to put the result on your target.

exit 1

Some branch was refused, or land refused the request as a whole. The rest landed and can be pushed. Each refusal has a why with its own entry above.

Fix. Follow the entry for each why, then run land merge again.

exit 2

A usage or local problem on your machine, such as an unknown option, not being inside a git repository, not being signed in, a branch or origin/<target> git does not know, or branches that share no history with the target. Nothing was sent to land.

Fix. Run the command printed after fix. It is always the exact next step.

exit 3

land is still working on it. The answer says "state": "running" and gives the command to wait with.

Fix. Run the same command again. That is how you wait, and it never starts the merge twice.

exit 4

land could not check this run. Its engine or its machines failed, or its answer was not a complete verdict. This is about land, not your change, and there is nothing to push.

Fix. Run the same command again. If it repeats, tell us with the JSON it printed.

infra

The why of an exit 4. land's own tooling or machines failed while checking, or the job's process died.

Fix. Run the same command again.

probe

land logs --run could not run your command in the failed test's view, for example because the test is no longer in the last merge's answer.

Fix. Run land logs to see the tests you can name, then land logs <test> --run again.