Skip to content

Keep PR NuGet cache isolation within valid GitHub Actions contexts #90

Description

@wieslawsoltes

Problem

After WebScene PR #71 merged, the NuGet package workflow was rejected before any job started. The consumer job declared a job-level environment value using runner.temp. GitHub does not expose the runner context while it evaluates job-level env, so the workflow was invalid.

Failing run: https://github.com/SceneTech/WebScene/actions/runs/35015568525

actionlint reported:

context "runner" is not allowed here

Proposed fix

Use github.workspace plus a run-, attempt-, and RID-specific path for NUGET_PACKAGES. This keeps same-version PR package restores isolated on persistent self-hosted runners while using a context valid at job evaluation time. Keep the cache under artifacts so its lifecycle is bounded by the runner workspace cleanup.

Acceptance

  • actionlint accepts native-runtime-packages.yml.
  • The workflow creates all expected jobs instead of failing at definition time.
  • macOS and Linux package consumers restore and run using isolated per-run package roots.
  • No package cache is uploaded as release output.

Implemented on the open Code OSS integration branch in commit 59c3e09; keep the fix in draft PR #76 until its full package matrix passes.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions