remotion-dev/remotion · error · Error
${endpointEnvName}, ${entryPointEnvName}, and ${sessionIdEnv
Error message
${endpointEnvName}, ${entryPointEnvName}, and ${sessionIdEnvName} must be set together What it means
In development builds, the bundler activates React Scan instrumentation only when REMOTION_REACT_SCAN_ENDPOINT, REMOTION_REACT_SCAN_ENTRY_POINT, and REMOTION_REACT_SCAN_SESSION_ID are all set (all-unset cleanly disables it by returning null; production builds always return null). If some but not all three are present, the configuration is inconsistent and getReactScanEntryPoint throws rather than guessing.
Source
Thrown at packages/bundler/src/react-scan-entry-point.ts:21
const sessionIdEnvName = 'REMOTION_REACT_SCAN_SESSION_ID';
export const getReactScanEntryPoint = (
environment: 'development' | 'production',
) => {
if (environment === 'production') {
return null;
}
const endpoint = process.env[endpointEnvName];
const entryPoint = process.env[entryPointEnvName];
const sessionId = process.env[sessionIdEnvName];
if (!endpoint && !entryPoint && !sessionId) {
return null;
}
if (!endpoint || !entryPoint || !sessionId) {
throw new Error(
`${endpointEnvName}, ${entryPointEnvName}, and ${sessionIdEnvName} must be set together`,
);
}
return entryPoint;
};
View on GitHub (pinned to 10db9de073)
Solutions
- Set all three variables together: REMOTION_REACT_SCAN_ENDPOINT, REMOTION_REACT_SCAN_ENTRY_POINT, REMOTION_REACT_SCAN_SESSION_ID
- Unset all three to disable React Scan cleanly
- Let Remotion Studio launch the bundler itself so it sets the triple consistently instead of exporting by hand
- Check shell profiles and .env files for a stale leftover variable
Example fix
# before: partial configuration export REMOTION_REACT_SCAN_ENDPOINT=http://localhost:8080 # after: set all three, or none export REMOTION_REACT_SCAN_ENDPOINT=http://localhost:8080 export REMOTION_REACT_SCAN_ENTRY_POINT=./react-scan-entry.ts export REMOTION_REACT_SCAN_SESSION_ID=session-1
Defensive patterns
Strategy: validation
Validate before calling
const names = ['REMOTION_REACT_SCAN_ENDPOINT', 'REMOTION_REACT_SCAN_ENTRY_POINT', 'REMOTION_REACT_SCAN_SESSION_ID'] as const;
const values = names.map((n) => process.env[n]);
if (values.some((v) => v) && !values.every((v) => v)) {
throw new Error(`Set all of ${names.join(', ')} together, or none of them`);
} Type guard
type ReactScanEnv =
| {enabled: false}
| {enabled: true; endpoint: string; entryPoint: string; sessionId: string};
const readReactScanEnv = (): ReactScanEnv => {
const endpoint = process.env.REMOTION_REACT_SCAN_ENDPOINT;
const entryPoint = process.env.REMOTION_REACT_SCAN_ENTRY_POINT;
const sessionId = process.env.REMOTION_REACT_SCAN_SESSION_ID;
if (!endpoint && !entryPoint && !sessionId) return {enabled: false};
if (endpoint && entryPoint && sessionId) return {enabled: true, endpoint, entryPoint, sessionId};
throw new Error('REMOTION_REACT_SCAN_* variables must be set together');
}; Prevention
- Treat the three REMOTION_REACT_SCAN_* variables as one unit - set all or none
- Let Studio spawn the bundler so it injects the triple consistently
- Audit shell profiles and .env files for stale react-scan variables before debugging bundler startup
When it happens
Trigger: Starting a development bundler process where only a subset of the three environment variables is exported - e.g. manually exporting only REMOTION_REACT_SCAN_ENDPOINT, or a stale variable leaking from a previous Studio session while the others were cleared.
Common situations: Hand-configuring React Scan and forgetting two of the three variables; a shell profile or .env exporting leftovers; wrapping Studio's bundler launch in custom tooling that forwards only part of the environment.
Understand the failure class
Background: "environment variable is not set" and "Missing keys in environment" errors: what missing required env var messages mean and how to fix them — this error's family across 28 libraries.
Related errors
- You passed ${entryPoint} as your entry point, but this file
- The public directory was specified as "${p}", which is the r
- The public directory was specified as "${p}", and while this
- The public directory was specified as "${p}", but this folde
- You have multiple buckets (${remotionBuckets .map((b) =>
AI-assisted analysis of remotion-dev/remotion@10db9de073 (2026-08-22).
Data as JSON: /api/errors/99a36fa0c974a585.
Report an issue: GitHub.