Troubleshooting
The errors and warnings the CLI and the frontend server print most often, what causes them, and how to fix them.
The CLI prints the fix for a failure on a line that starts with →. This page collects the common failures, with their causes. To see the full pnpm and Vite output and the stack trace of the underlying error, add --verbose to the command.
The backend
No backend URL and no running project
✖ No backend URL provided and no running antelope project found
Searched for .antelope/dev.json from the current directory upward.
→ Run this command inside an antelope project started with 'ajs project dev'
→ Or pass the backend explicitly with -b <url> (env: DMS_API_BASE_URL)
ajs dms dev looks for the .antelope/dev.json that a running ajs project dev writes, from the current directory upward. Start the backend first, run the command from inside the project, or pass -b.
Backend URL is required
✖ Backend URL is required
→ Pass -b <url> or set DMS_API_BASE_URL
start and prepare --strict never discover the backend. Pass -b, or set DMS_API_BASE_URL in the environment or in the .env of the directory you run them from. build asks no backend, so it needs no URL.
Invalid backend URL
✖ Invalid backend URL 'localhost:5010'
→ Include the scheme: -b http://localhost:5010
The URL needs its http:// or https:// scheme.
Cannot reach the backend
▲ Skipped prepare: Cannot reach the DMS backend at http://localhost:5999
Connection refused (ECONNREFUSED).
→ Start the backend (`ajs project dev` for a local one), or pass its URL with -b <url>
dev and prepare fall back to the cached manifest when the workspace has one. Without a cached manifest, dev stops and prepare warns and exits 0, or exits 1 with --strict. build never calls the backend. See Workspaces and cache.
A page loaded while the server is up but the backend is not, during a backend restart for instance, shows the error page with status 502. A 503 or 504 from the backend does the same. That page asks for itself again after half a second, then waits twice as long each time up to 8 seconds, and reloads as soon as the server answers anything else.
Secrets
DMS_SESSION_SECRET is not set, or too short
✖ DMS_SESSION_SECRET is too short: 5 characters, at least 32 needed
start signs sessions with it, so it must stay the same across restarts.
→ Create one: openssl rand -hex 32, then set it in the environment or ./.env
start needs a secret of 32 characters or more, and it must stay the same across restarts. dev generates one only when the variable is not set at all.
E-mail renders or OAuth sign-in are refused
▲ DMS_HTML_RENDER_SECRET is not set: e-mail renders will be refused
▲ DMS_OAUTH_RELAY_SECRET is not set: OAuth sign-in will be refused by the backend
→ Set them in the server's environment, with the values the backend uses
A build keeps no secret, so start reads them from the server's environment. Set DMS_HTML_RENDER_SECRET to the backend's htmlRender.serviceSecret and DMS_OAUTH_RELAY_SECRET to its oauth.relaySecret. A module's other private options go in DMS_PRIVATE_OPTIONS, as the server's secrets explains.
A module's /ai/** or /media/** calls answer 404
The module that declares the proxy was left out of the build, so its calls fall through to the pages. build warns about each module it leaves out. A module is left out when it is not installed in the project, which ajs project build fixes. A module is also left out when it ships frontend-vue/ without a dmsFrontend declaration in its package.json.
Builds and modules
A module does not run on this release
✖ These frontend modules do not run on @antelopejs/dms-frontend 0.6.1
template-dms-demo-frontend-vue (./frontend-vue) supports >=0.5.0 <0.6.0
→ Install a @antelopejs/dms-frontend release in their ranges, or upgrade the modules
A module's engines["@antelopejs/dms-frontend"] excludes the installed loader. Install a loader in that range, as Compatibility explains, or upgrade the module. See Supported releases.
No production build
✖ No production build to serve
./.dms-frontend has no built server or client.
→ Build it first: ajs dms build
start serves <project>/.dms-frontend, or --workspace <dir>. Run build from the same project, with the same --workspace.
A build step fails
The step's error, or the last lines of its output, point at the file in the frontend module rather than at its copy in the workspace. Fix the source and run the command again. --verbose shows every line of every step. When the workspace itself looks broken, run the command again with --force to reinstall the workspace dependencies.
The server
The port is busy
✖ Port 3007 is already in use
→ Stop the process listening on it, or pass another port: -p <port>
start stops on a busy port. dev moves to the next free one and says so. -p 0 asks for any free port.
The dashboard is unreachable from another machine
ajs dms dev listens on 127.0.0.1. Set HOST=0.0.0.0 to open it to the network.
Sign-in does not stick
start sets Secure cookies, which a browser only sends over HTTPS. Serve it behind TLS, or set DMS_COOKIE_SECURE=false for a plain-HTTP test. Behind several processes, use sticky routing, because session refresh is single-flight within one process only. See Production.
A backend route answers 404 from the browser
The frontend server only proxies the prefixes the modules declare. Every other path is a page, and a write to a page path answers 404. In development, the x-dms-route-owner header names who answered. Declare the prefix with registerBackendProxy, backendProxies or DMS_BACKEND_PROXIES. See Routing and the backend proxy.
Workspaces
The disk fills up
Each workspace under ~/.antelopejs/dms-frontend holds its own node_modules, manifest cache and build output. ajs dms workspaces lists them with their size and last use. ajs dms clean -b <url> removes the workspace of one backend URL, and ajs dms clean --all removes every one after a confirmation. ajs dms dev without -b creates a workspace of its own, keyed on the project directory, so each project you run it in adds one.