Forgecroft Docs
Guides

Troubleshooting

Common failure patterns, how to diagnose them, and how to fix them.

First Things to Check

When something goes wrong, start here:

  1. Is the workspace configured correctly?GET /workspaces/{id} and verify source_repo_url, source_branch, source_root, execution_target
  2. Are credentials valid?POST /credential-configs/{id}/verify to test
  3. Is the state backend reachable? — Check state_backend_config_id is set and the bucket exists
  4. Is the run stuck or failed?GET /workspaces/{workspaceId}/runs/{runId} to check status and error_summary

Plan Fails Immediately

Symptoms: Run transitions to failed within seconds, no plan output.

Likely CauseHow to VerifyHow to Fix
Wrong repo URL or branchCheck workspace source_repo_url and source_branchPATCH /workspaces/{id} with correct values
Source root doesn’t existCheck source_root matches directory in repoUpdate source_root to correct path
Invalid credentialsPOST /credential-configs/{id}/verify returns valid: falseUpdate or re-create credentials
State backend unreachableCheck state_backend_config_id and bucket permissionsVerify bucket exists and credentials have access
Wrong tool typeCheck effective_tool_type on workspaceSet correct tool_type via PATCH

Plan Fails Mid-Run

Symptoms: Run starts but fails during terraform plan or tofu plan.

Likely CauseHow to VerifyHow to Fix
Terraform syntax errorCheck logs for parse errorsFix code in repo and re-run
Provider auth failureLogs show provider-specific auth errorCheck credential config for that provider
State lock conflictLogs show “state lock held by…”Force unlock if no other process is writing
Out of memoryRunner killed by OOMReduce plan scope or use agent mode with more resources

Run Stuck in Queued

Symptoms: Run status stays queued for an extended period.

Likely CauseHow to VerifyHow to Fix
Managed environment provisioning delayWait 1-2 minutesNormal for first run in an org
Org job limit reachedCheck if other runs are in progress for same orgWait for other runs to complete (default: 3 per org)
Agent not running (agent mode)Workspace execution_target is agentStart your Forgecroft Agent and verify it’s polling
Billing inactiveGET /billing shows inactive subscriptionComplete checkout or contact support

Run Stuck in In-Progress

Symptoms: Run status is in_progress for longer than expected.

Likely CauseHow to VerifyHow to Fix
Long-running plan (large state)Check logs for progressWait — large plans can take many minutes
Runner crashed or lost connectionNo new log lines for several minutesAbort the run and re-run
Network timeout to state backendLogs show timeout errorsCheck state backend connectivity

Aborting a Run

POST /workspaces/{workspaceId}/runs/{runId}/abort

Works for runs in queued, in_progress, pending_policy, or pending_approval status. Returns 409 if already terminal.

Webhook Not Triggering

Symptoms: Pushing to GitHub doesn’t create a run.

Likely CauseHow to VerifyHow to Fix
No VCS integration configuredGET /vcs-integrations returns emptyCreate a VCS integration or install GitHub App
Webhook not installedCheck GitHub repo settings → WebhooksRe-install GitHub App or manually add webhook
Path filtering excludes changesChanged files don’t match workspace source_rootCheck source_root and extra_checkout_paths
Branch doesn’t matchPush is to a branch that doesn’t match source_branch or pr_base_branchUpdate workspace branch config
Invalid webhook signatureForgecroft returns 400 to GitHubCheck VCS integration secret/token

Approval Not Received

Symptoms: Run is pending_approval but no notification was received.

Likely CauseHow to VerifyHow to Fix
No notification channel configuredCheck workspace notification_config_idsAdd a notification config
User notification preference is noneGET /me/notification-preferencesPUT /me/notification-preferences with email or slack_dm
Slack not connectedGET /slack-connections returns emptyConnect Slack via OAuth flow
Email not configuredNo Resend API key on server sideUse Slack or check server config

Re-notifying Approvers

POST /workspaces/{workspaceId}/runs/{runId}/renotify

Re-sends approval notifications. Rate-limited to once per 5 minutes.

API Key Not Working

Symptoms: 401 or 403 responses when using an API key.

Likely CauseHow to VerifyHow to Fix
Key is suspendedGET /api-keys/{id} shows suspended: truePATCH /api-keys/{id} with {"suspended": false}
Key has expiredGET /api-keys/{id} shows past expires_atCreate a new key
Key scope doesn’t match resourceKey is workspace-scoped but you’re accessing a different workspaceCreate an org- or project-scoped key
Missing capability scopeKey has scoped capabilities but lacks the needed oneCreate a new key with required capabilities
Wrong auth headerUsing cookie instead of Bearer tokenUse Authorization: Bearer fc_live_...