runner icon indicating copy to clipboard operation
runner copied to clipboard

Composite actions can't see or use org or repo vars

Open NicoForce opened this issue 2 years ago • 5 comments

Describe the bug Composite actions can't see org or repo vars.

To Reproduce Steps to reproduce the behavior:

  1. Create a composite action
  2. Use the vars context somewhere.
  3. Use composite action
  4. See error Unrecognized named-value: 'vars'.

Expected behavior Expected composite actions to be able to read org/repo variables.

Runner Version and Platform

Ubuntu latest.

OS of the machine running the runner? Ubuntu

What's not working?

Error: /runner/_work/xxx/xxx/./scripts/github-actions/deploy/exec-deployment/action.yml (Line: 34, Col: 11): Unrecognized named-value: 'vars'. Located at position 29 within expression: env.ENV != 'prod' && !vars.ALLOW

NicoForce avatar Apr 17 '23 20:04 NicoForce

We encountered this issue as well. Is there a suggested workaround?

ivan-kolisnyk avatar Apr 21 '23 19:04 ivan-kolisnyk

Really hard to understand why it behaves this way. For now my workflow config has to be in repo secrets I guess.

dmckernanacv avatar Jan 18 '24 15:01 dmckernanacv

This issue is stale because it has been open 365 days with no activity. Remove stale label or comment or this will be closed in 15 days.

github-actions[bot] avatar Feb 17 '25 00:02 github-actions[bot]

This is still an issue. Our solution was to stop using custom composite actions altogether, although this issue was not the only reason for that.

Sebastian-0 avatar Feb 21 '25 14:02 Sebastian-0