Skip to content

Allow temporary IDs for all project operations#19573

Merged
pelikhan merged 8 commits intomainfrom
copilot/add-temporary-ids-support
Mar 7, 2026
Merged

Allow temporary IDs for all project operations#19573
pelikhan merged 8 commits intomainfrom
copilot/add-temporary-ids-support

Conversation

Copy link
Contributor

Copilot AI commented Mar 4, 2026

  • Fix TypeScript typecheck error in create_project.cjs (normalizeTemporaryId(temporaryId ?? ""))
  • Fix parameter order in create_project.cjs handler: (message, resolvedTemporaryIds, temporaryIdMap) to match manager convention
  • Fix parameter order in create_project_status_update.cjs handler
  • Add instanceof Map guards on all temporaryIdMap read/write operations for safety
  • Update tests to use correct calling convention (message, Object.fromEntries(temporaryIdMap), temporaryIdMap)
  • All 16 JS tests pass, TypeScript typecheck passes
  • Sync action_pins.json with origin/main (adds docker/login-action@v4, docker/setup-buildx-action@v4, updates setup-dotnet to v5.2.0, etc.)
  • Fix action_pins_logging_test.go: update setup-dotnet test case to v5.2.0
  • Fix action_pins_test.go: update pin count expectation from 32 to 34

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 3 commits March 4, 2026 09:33
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
@mnkiefer
Copy link
Contributor

mnkiefer commented Mar 4, 2026

@copilot fix js tests

Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Mar 4, 2026

@copilot fix js tests

Fixed in 8cb353f. The TypeScript strict null check was failing because normalizeTemporaryId expects string but the JSDoc cast /** @type {string} */ (without parentheses) doesn't survive prettier's TypeScript parser — it gets stripped, leaving the type as string | null. Changed line 463 to normalizeTemporaryId(temporaryId ?? "") which satisfies TypeScript and is formatter-stable. The ?? "" fallback never triggers at runtime since the early return at line 350–356 already handles the null case.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • https://api.github.com/repos/github/gh-aw/contents/.github%2Fworkflows%2Faudit-workflows.md
    • Triggering command: /opt/hostedtoolcache/node/24.13.1/x64/bin/node /opt/hostedtoolcache/node/24.13.1/x64/bin/node --conditions node --conditions development --experimental-import-meta-resolve --require /home/REDACTED/work/gh-aw/gh-aw/actions/setup/js/node_modules/vitest/suppress-warnings.cjs /home/REDACTED/work/gh-aw/gh-aw/actions/setup/js/node_modules/vitest/dist/workers/forks.js m k/gh-aw/node_mod-- git push�� -u origin k/gh-aw/gh-aw/actions/node_modules/.bin/git it git _modules/.bin/git git (http block)

If you need me to access, download, or install something from one of these locations, you can either:

@mnkiefer mnkiefer marked this pull request as ready for review March 5, 2026 06:48
Copilot AI review requested due to automatic review settings March 5, 2026 06:48
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for referencing newly-created GitHub Projects via temporary IDs (e.g. aw_... / #aw_...) so subsequent project operations can resolve the real project URL.

Changes:

  • Store a temporary-id → project URL mapping when create_project succeeds.
  • Resolve temporary project IDs from the shared temporaryIdMap in create_project_status_update.
  • Add unit tests covering temporary project ID resolution and not-found behavior for status updates.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
actions/setup/js/create_project_status_update.test.cjs Adds tests validating temporary project ID resolution (with and without #) and failure behavior.
actions/setup/js/create_project_status_update.cjs Resolves output.project when it’s a temporary ID by looking up projectUrl in the shared temp-id map.
actions/setup/js/create_project.cjs Stores the created project URL in the shared temp-id map and returns temporaryId in the result.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…ager convention

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
@pelikhan
Copy link
Contributor

pelikhan commented Mar 7, 2026

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Mar 7, 2026

@copilot fix test in https://github.com/github/gh-aw/actions/runs/22747364765/job/66023925715

Fixed in 2fa0350. The CI failure was caused by our branch being out of sync with origin/mainaction_pins.json on main had been updated (setup-dotnet v5.2.0, plus 2 new docker v4 entries bringing the total to 34). Updated action_pins.json to match main, and fixed the corresponding test expectations in action_pins_logging_test.go (v5.1.0 → v5.2.0) and action_pins_test.go (32 → 34).

@pelikhan pelikhan merged commit bac1f8a into main Mar 7, 2026
79 checks passed
@pelikhan pelikhan deleted the copilot/add-temporary-ids-support branch March 7, 2026 01:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants