remotion-dev/remotion · error · Error
No permissions returned from the testIamPermissions call.
Error message
No permissions returned from the testIamPermissions call.
What it means
Thrown by testPermissions() when the Resource Manager testIamPermissions call returns no permissions array. This is an abnormal GCP API response: a successful call should always return a permissions array (possibly empty). A missing array signals an API or auth problem rather than a permissions failure.
Source
Thrown at packages/cloudrun/src/api/iam-validation/testPermissions.ts:51
fs.readFileSync(
path.join(__dirname, '../../shared/sa-permissions.json'),
'utf-8',
),
);
const permissionList: string[] = saPermissions.list.map(
(permission: {name: string; reason: string}) => permission.name,
);
const response = await resourceManagerClient.testIamPermissions({
resource: `projects/${getProjectId()}`,
permissions: permissionList,
});
const returnedPermissions = response[0].permissions;
if (!returnedPermissions) {
throw new Error(
'No permissions returned from the testIamPermissions call.',
);
}
const results: TestResult[] = [];
saPermissions.list.forEach((permission: {name: string; reason: string}) => {
if (returnedPermissions.includes(permission.name)) {
const thisResult = {decision: true, permissionName: permission.name};
results.push(thisResult);
params?.onTest(thisResult);
} else {
const thisResult = {decision: false, permissionName: permission.name};
results.push(thisResult);
params?.onTest(thisResult);
}
});
View on GitHub (pinned to 78fe4bb3fd)
Solutions
- Re-run gcloud auth application-default login to refresh credentials.
- Verify the project ID from getProjectId() is correct.
- Retry the call; if persistent, check GCP status and IAM API availability.
- Ensure the Resource Manager API is enabled in the project.
Example fix
// no code fix; this is a GCP environment/auth issue // run: gcloud auth application-default login // then retry testPermissions()
Defensive patterns
Strategy: retry
Try / catch
for (let attempt = 0; attempt < 3; attempt++) {
try {
return await testPermissions({region, onTest});
} catch (e) {
if (e.message.includes('No permissions returned') && attempt < 2) continue;
throw e;
}
} Prevention
- Keep Application Default Credentials fresh: gcloud auth application-default login.
- Enable the Resource Manager API in the target project.
- Retry transient GCP API anomalies before surfacing the error.
When it happens
Trigger: Calling testPermissions() where response[0].permissions is undefined/null after resourceManagerClient.testIamPermissions() resolves.
Common situations: GCP API version mismatch, expired or misconfigured Application Default Credentials, or an unexpected transient API error returning a malformed response.
Related errors
- You have multiple buckets (${remotionBuckets .map((b) =>
- Bucket creation is required, but no region has been passed.
- Service ${serviceName} not found
- Either cloudRunUrl or serviceName must be provided
- Either cloudRunUrl or serviceName must be provided, not both
AI-assisted analysis of remotion-dev/remotion@78fe4bb3fd (2026-08-12).
Data as JSON: /api/errors/f23920ca3c304d77.
Report an issue: GitHub.