{"record":{"id":"a023157b71367803","repo":"remotion-dev/remotion","slug":"sitename-trim-was-not-found-in-region","errorCode":null,"errorMessage":"${siteName.trim()} was not found in ${region}.","messagePattern":"(.+?) was not found in (.+?)\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/cloudrun/src/cli/commands/sites/rm.ts","lineNumber":51,"sourceCode":"\tconst region = getGcpRegion();\n\tconst infoOutput = CliInternals.createOverwriteableCliOutput({\n\t\tquiet: CliInternals.quietFlagProvided(),\n\t\tcancelSignal: null,\n\t\tupdatesDontOverwrite: false,\n\t\tindent: false,\n\t\tlogLevel,\n\t});\n\tinfoOutput.update(`Checking ${region} for sites...`, false);\n\n\tconst deployedSites = await getSites(region);\n\n\tfor (const siteName of args) {\n\t\tinfoOutput.update('Getting site info...', false);\n\n\t\tconst site = deployedSites.sites.find((s) => s.id === siteName.trim());\n\t\tif (!site) {\n\t\t\tinfoOutput.update('', false);\n\t\t\tthrow new Error(`${siteName.trim()} was not found in ${region}.`);\n\t\t}\n\n\t\tinfoOutput.update(displaySiteInfo(site), false);\n\t\tLog.info({indent: false, logLevel});\n\t\tLog.info({indent: false, logLevel});\n\n\t\tconst confirmDelete = await confirmCli({\n\t\t\tdelMessage: 'Delete? (Y/n)',\n\t\t\tallowForceFlag: true,\n\t\t});\n\n\t\tif (!confirmDelete) {\n\t\t\tLog.info({indent: false, logLevel}, 'Aborting.');\n\t\t\treturn;\n\t\t}\n\n\t\tawait deleteSite({\n\t\t\tbucketName: site.bucketName,","sourceCodeStart":33,"sourceCodeEnd":69,"githubUrl":"https://github.com/remotion-dev/remotion/blob/78fe4bb3fdb5a2cd68724393d63cb223db333fa7/packages/cloudrun/src/cli/commands/sites/rm.ts#L33-L69","documentation":"Thrown by the `remotion cloudrun sites rm` CLI command when a site name passed as an argument is not found among the deployed sites returned by getSites(region). The site must exist before it can be removed.","triggerScenarios":"Running `remotion cloudrun sites rm <siteName>` where <siteName> does not match any s.id in the deployed sites list for the target region.","commonSituations":"Typo in the site name, the site was already deleted, or the site exists in a different region than the one targeted.","solutions":["List deployed sites first: npx remotion cloudrun sites ls --region=<region>.","Copy the exact site ID from the listing into the rm command.","Verify the --region flag matches the region where the site was created."],"exampleFix":"# before\nnpx remotion cloudrun sites rm wrong-id --region=us-central1\n# after\nnpx remotion cloudrun sites ls --region=us-central1\n# then use the exact id:\nnpx remotion cloudrun sites rm <exact-id> --region=us-central1","handlingStrategy":"validation","validationCode":"const sites = await getSites(region);\nconst exists = args.every(name => sites.sites.some(s => s.id === name.trim()));\nif (!exists) throw new Error('One or more site IDs do not exist in the region');","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Run `remotion cloudrun sites ls` before `rm` to copy exact IDs.","Match the --region flag to the region where the site was created."],"tags":["cloudrun","gcp","cli","sites","not-found"],"backgroundTag":null,"analyzedSha":"78fe4bb3fdb5a2cd68724393d63cb223db333fa7","analyzedAt":"2026-08-12T17:18:50.444Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}