fix(experiments): fall back to the GPU label when the name cell is blank - #882
Open
ANIRUDDHA ADAK (aniruddhaadak80) wants to merge 1 commit into
Conversation
`??` only catches null and undefined, so a row whose name cell is empty took the empty string and rendered a blank label instead of "GPU". The same parser already treats a blank temperature cell as absent, so the name now uses the same test.
ANIRUDDHA ADAK (aniruddhaadak80)
requested review from
Aayam Bansal (aayambansal) and
Ishaan Gangwani (ishaan1124)
as code owners
October 2, 2026 02:51
|
ANIRUDDHA ADAK (@aniruddhaadak80) is attempting to deploy a commit to the InkVell Team on Vercel. A member of the Team first needs to authorize it. |
This branch has not been deployed
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.
What does this PR do, and why?
GpuInventory.parseinbackend/cli/src/experiments/gpu.tsreads rows ofnvidia-smioutput and builds aGpuper row. The name fell back like this:??only coversnullandundefined.nvidia-smireports an unnamed slot asan empty cell, which is
"", so"" ?? "GPU"is""— the row produced aGpuwhosenameis the empty string. That satisfiesz.string(), so nothingdownstream complained, and the GPU rendered with a blank label instead of
GPU.The same function already gets this right four lines below:
so a blank temperature correctly reads as absent while a blank name did not.
This change gives the name the same treatment rather than leaving the two
inconsistent.
Linked issue
small fix, no issue
How did you verify it?
Bun 1.3.14, at
main=23fdd654.GpuInventory.parseis a pure exportedfunction, so no server or
Instanceharness is involved.The new test fails on the unmodified tree:
and passes with the fix:
The other two tests are there to hold the behaviour that was already correct:
a real name is still kept, and a blank temperature still reads as
null. Bothpass before and after, so the change is scoped to the blank name.
Formatting was checked against the repo's own config
(
prettier --config package.json --end-of-line lf --check): clean.Checklist
bun run checkis green (format, typecheck, backend + frontend/ui + SDK tests)bun run --cwd frontend/workspace buildsucceeds if I touchedfrontend/workspaceorfrontend/ui./tooling/repo/generate.tswas run and thetooling/sdkoutput committed if I changedbackend/cli/src/serverfrontend/docs/src/content/openscience/is updated if behavior changedpackage.jsonversions and tags are written by the release workflow)installandfrontend/landing/public/installare still byte-identical if I touched eitherNot applicable: this does not touch
frontend/workspace,frontend/uiorbackend/cli/src/server, so no workspace build and no SDK regeneration.On the first box: I ran the new test file with the same runner and timeout the
repo's own script uses (
bun run --cwd backend/cli testadds--timeout 15000). I did not run the fullbun run checkacross everyworkspace — this checkout is a worktree with a borrowed
node_modulesratherthan a full
bun run setup, so I will not claim a result I did not observe.tsgoreports no error in either file this PR changes.