Skip to content

Find the Run settings footer by its rule, not by div count - #15181

Merged
danielhanchen merged 1 commit into
mainfrom
ci-run-settings-footer-locator
Oct 25, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
ci-run-settings-footer-locator

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Summary

tests/studio/test_model_picker_contracts.py::test_the_run_settings_footer_does_not_reflow_under_the_pointer fails on main since #15104 (pinned Run settings footer). It shows up in Repo tests (CPU, studio) on unrelated PRs, for example #15123:

E   AssertionError:  className={cn( "mt-5", // Sticky offsets start inside the scroller's 18px padding ... variant === "page" && "sticky -bottom-4.5 ...
E   assert ('variant ===' not in ' className=...

The test found the footer as "the third <div back" from the Remember checkbox. #15104 wrapped the footer in a new sticky <div>, so that count now lands on the wrapper. The wrapper's variant === "page" condition only pins the footer to the panel edge. The footer itself is still flex flex-col gap-3.5 border-t ..., with no flex-wrap and no variant switch. So the #10216 invariant (Load must not move between mousedown and mouseup) still holds, and only the locator broke.

Change

  • Walk the <div> open and close tags before the checkbox, so only the divs that actually enclose Remember count. Sibling divs that already closed are skipped, and > inside JSX braces is handled.
  • The footer is the enclosing div that draws the rule (border-t). It must be flex flex-col, must not switch on variant, and must not wrap. The divs inside it, and the one wrapper just outside it (the sticky pin), must not carry flex-wrap either.

Verification

  • On main: fails as above. With this change: 201 passed for the whole file.
  • The model-config-page.tsx from before Studio: pinned Run settings footer, model picker on the radius scale #15104 still passes, so the check covers both layouts.
  • Sabotage, each against the current component, each makes the test fail:
    1. flex-wrap on the footer column
    2. the footer's layout switched on variant (flex flex-row for the page variant)
    3. flex flex-wrap on the sticky wrapper

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-25T01:27:04.616783Z e6a2235 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: e6a223589f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

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.

1 participant