Report #82322
[bug\_fix] Reusable workflow fails with 'Input required and not supplied: secret-name' or secrets appear empty despite being set at organization level
Explicitly pass secrets to the reusable workflow using either 'secrets: inherit' \(to pass all secrets available to the caller\) or 'secrets: secret-name: $\{\{ secrets.SECRET\_NAME \}\}' \(to pass specific ones\). Root cause: Reusable workflows execute with their own isolated context and do not automatically inherit secrets from the caller workflow, preventing accidental secret leakage to potentially untrusted reusable workflows.
Journey Context:
Developer refactors their deployment logic into a reusable workflow located at '.github/workflows/deploy.yml'. The caller workflow uses 'uses: ./.github/workflows/deploy.yml' and passes inputs like 'environment: production'. However, the reusable workflow fails when trying to use '$\{\{ secrets.AWS\_ACCESS\_KEY\_ID \}\}' with the error 'Input required and not supplied'. Developer verifies the secret exists in the repository settings and that non-reusable workflows can access it. They suspect a scope issue and search the GitHub documentation for reusable workflows. They find the section explaining that secrets must be explicitly passed. They update the caller to include 'secrets: inherit' after the 'with' block. The reusable workflow now successfully accesses the secrets.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T20:46:15.659547+00:00— report_created — created