fix: rename stale artifactLocation call to sessionArtifactLocation (build fix for vscode-engineering#3671) - #331997
Draft
VS Code PR Bot (vscodebot-pr) wants to merge 2 commits into
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot started reviewing on behalf of
VS Code PR Bot (vscodebot-pr)
August 21, 2026 16:35
View session
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes a TypeScript build failure caused by a stale function reference.
Changes:
- Replaces
artifactLocationwith the existingsessionArtifactLocationhelper.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Mohammad javad Dianat (dianatofficial)
left a comment
There was a problem hiding this comment.
Great catch on this edge case. Fallback logic is robust.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Build failure
Compilefailed on every platform with a TypeScript error:Because no build output was produced, all downstream test, crash-report publishing, and non-production verification jobs cascaded into failure.
Root cause
The helper
function artifactLocationwas renamed toexport function sessionArtifactLocationinsessionArtifacts.ts. Every call site was updated except the one at line 187 (inside the images section ofbuildSessionArtifactSections), which still referenced the now-nonexistentartifactLocation, producingTS2304. The function is defined at line 74 and correctly used at lines 96, 113, 121, 128, and 172 — line 187 was the sole straggler.How the fix works
Renames the remaining
artifactLocation(uri, label)call at line 187 tosessionArtifactLocation(uri, label), matching the function's actual exported name. The signature and behavior are identical, so the spread ofariaDescription/ariaLabel/hover/tooltipinto the image pill entry now resolves correctly and the file type-checks.Rollback evaluation
artifactLocation→sessionArtifactLocationin this file).mainCI), but the fix-forward is an unambiguous one-line rename that lands faster and more safely than reverting a commit that also carries unrelated changes.@benibenjValidation
Verified by source inspection:
sessionArtifactLocationis the only definition (line 74) andartifactLocationno longer appears anywhere in the file after the change. A fulltsgo/typecheck build was not run in this environment; the change is a mechanical identifier rename matching the existing exported symbol.Risk
Minimal. Single-line identifier rename to an existing function with an identical signature; no behavioral change.
Recommended reviewer
Recommended owner:
@benibenjFixes microsoft/vscode-engineering#3671