{"record":{"id":"0cd048f2c8ffa610","repo":"remotion-dev/remotion","slug":"region-is-not-a-valid-gcp-region-must-be-one-o","errorCode":null,"errorMessage":"${region} is not a valid GCP region. Must be one of: ${GCP_REGIONS.join(', ')}","messagePattern":"(.+?) is not a valid GCP region\\. Must be one of: (.+?)","errorType":"validation","errorClass":"TypeError","httpStatus":null,"severity":"error","filePath":"packages/cloudrun/src/shared/validate-gcp-region.ts","lineNumber":8,"sourceCode":"import type {GcpRegion} from '../pricing/gcp-regions';\nimport {GCP_REGIONS} from '../pricing/gcp-regions';\n\nexport function validateGcpRegion(\n\tregion: unknown,\n): asserts region is GcpRegion {\n\tif (!GCP_REGIONS.includes(region as GcpRegion)) {\n\t\tthrow new TypeError(\n\t\t\t`${region} is not a valid GCP region. Must be one of: ${GCP_REGIONS.join(\n\t\t\t\t', ',\n\t\t\t)}`,\n\t\t);\n\t}\n}\n","sourceCodeStart":1,"sourceCodeEnd":15,"githubUrl":"https://github.com/remotion-dev/remotion/blob/78fe4bb3fdb5a2cd68724393d63cb223db333fa7/packages/cloudrun/src/shared/validate-gcp-region.ts#L1-L15","documentation":"Thrown by validateGcpRegion() (an asserts-narrowing function) when the supplied region is not in the GCP_REGIONS list. Used to ensure region values passed to deploy/render APIs are valid Google Cloud regions Remotion supports. The message enumerates the full set of valid regions.","triggerScenarios":"Passing a region string not in GCP_REGIONS (e.g., 'us-east-1' which is AWS, a typo like 'us-east11', or a region Remotion does not yet list), or a non-string value that happens to slip through to the includes() check.","commonSituations":"Confusing AWS region names with GCP ones; using a brand-new GCP region not yet in the list; typo in config; copy-pasting from a Lambda example.","solutions":["Use a region from the printed list, e.g. 'us-east1', 'europe-west1', 'asia-east1'.","Upgrade @remotion/cloudrun if your GCP region was added after your installed version.","Copy the exact region string from the GCP console."],"exampleFix":"// before\nawait deployService({ region: 'us-east-1', ... }); // AWS name\n// after\nawait deployService({ region: 'us-east1', ... }); // GCP name","handlingStrategy":"validation","validationCode":"import { GCP_REGIONS } from '@remotion/cloudrun/pricing/gcp-regions';\nif (!GCP_REGIONS.includes(region as never)) {\n  throw new Error(`Invalid GCP region. Valid: ${GCP_REGIONS.join(', ')}`);\n}","typeGuard":"import { GCP_REGIONS } from '@remotion/cloudrun/pricing/gcp-regions';\nfunction isValidGcpRegion(v: unknown): boolean {\n  return typeof v === 'string' && (GCP_REGIONS as readonly string[]).includes(v);\n}","tryCatchPattern":"// Validate once at config load; do not retry on invalid region.","preventionTips":["Use a typed region constant from your config schema.","Cross-check region names against the GCP console (not AWS).","Upgrade @remotion/cloudrun to pick up newly supported regions."],"tags":["cloudrun","validation","region","gcp"],"backgroundTag":null,"analyzedSha":"78fe4bb3fdb5a2cd68724393d63cb223db333fa7","analyzedAt":"2026-08-12T17:18:50.444Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}