Codex Pets overlay clips/mispositions sprite and notification tray on macOS
Summary
Codex Pets can render correctly only after dragging the floating pet overlay far away from the screen edge, but the notification tray/card remains clipped by the overlay window bounds.
This affects both built-in pets and custom pets. At first it looked like the pet sprite was missing, but dragging the floating overlay to the upper-left made the sprite visible. Mission Control shows that the pet overlay is a small fixed-size floating window, and the notification card/text is clipped inside that window instead of resizing, wrapping within bounds, or expanding the overlay window.
Environment
- Codex app:
26.429.30905 - Codex CLI:
0.128.0-alpha.1 - macOS:
26.4.1(Darwin 25.4.0) - Machine/GPU: Apple M4 Max, Metal 4
- Display: built-in Liquid Retina XDR, 3456 x 2234 Retina
- Locale/text: Japanese UI/text
Steps to reproduce
- Open the Codex macOS app.
- Wake the pet with
/petor the Wake Pet command. - Select either a built-in pet, such as
bsod, or a custom pet. - Place the pet overlay near the screen edge or bottom/right area.
- Observe that the pet may appear invisible or partially missing.
- Drag the pet overlay far toward the upper-left or more central screen area.
- Observe that the pet sprite appears, but the notification tray/card is still clipped horizontally.
- Open Mission Control and observe the floating pet overlay window bounds.
Expected behavior
The floating pet overlay window should be sized and positioned so that:
- the selected pet sprite is visible within screen bounds;
- the notification tray/card is fully visible;
- long text, including Japanese text, wraps/clamps inside the card or the overlay resizes/repositions to avoid clipping;
- screen edge placement does not cause the sprite/card to disappear behind the transparent window bounds.
Actual behavior
- Near screen edges, the pet can look invisible or clipped.
- After dragging the overlay to the upper-left, the pet sprite becomes visible, confirming the sprite loads correctly.
- The notification card remains clipped horizontally.
- Mission Control reveals a small fixed-size floating overlay window; the notification card extends beyond that window and gets clipped.
Things tried
/pettoggle- app restart
- Mac restart
- clearing saved
electron-avatar-overlay-bounds - clearing Codex GPU/drawing caches:
GPUCache,DawnGraphiteCache,DawnWebGPUCache, andCode Cache - testing both built-in pet (
bsod) and custom pet - testing custom pet spritesheet as WebP and PNG
These did not resolve the clipping. Dragging the overlay to a different part of the screen was the only thing that made the sprite visible.
Screenshots
Pet becomes visible after dragging to the upper-left:
!Pet visible after dragging upper-left
Notification card text is clipped horizontally:
Mission Control shows the overlay window clipping the card:
Wider Mission Control context:
8 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Additional reproduction from Codex Desktop on macOS.
Environment observed locally:
Observed behavior:
/petshows a large rounded rectangular overlay/frame.This appears related to the clipping/mispositioning described here. It is not a custom pet asset issue in this reproduction; the visible problem is the Desktop pet overlay layout itself. There does not appear to be a documented user-facing setting in Codex config or Settings to adjust the pet overlay/frame size.
Screenshot was observed in the local Codex thread but is not attached to this GitHub comment.
Additional data point from my external-monitor setup (Codex Desktop 26.429.61741 / Build 2429, macOS, BenQ SW321C as main display, scaling set to More Space):
This was 100% reproducible in this setup.
I ran into what looks like the same class of issue on macOS.
Environment
26.429.61741build242925.4.0arm64Symptoms
~/.codex/.codex-global-state.jsonoverlay/avatar state did not fix it.What fixed it
A full reset of the Codex Electron/Chromium app profile fixed the issue:
After restarting Codex,
/petrendered normally again.This did not require changing
~/.codex/petsor the custom pet package.Possible clue
Before resetting the profile,
~/Library/Application Support/Codex/Preferencescontained a saved Chromium zoom entry:I cannot say for sure that the zoom value was the root cause, but the full app-profile reset fixed it where display changes, pet asset changes, and overlay-state reset did not. This suggests the issue may involve stale local Electron/Chromium profile state, zoom state, or rendering/cache state in addition to overlay bounds/DPI math.
Removing
partitionformPreferencesworks for me.Also reproducing on Windows.
Environment:
This looks like the same overlay-window bounds/clipping issue, but on Windows.
Additional data point from macOS, with a narrower workaround than a full app-profile reset.
Environment:
26.506.31421/ build2620Darwin 25.2.0 arm64 armcodexpet, so this was not a custom pet atlas issue.What I observed:
~/.codex/.codex-global-state.json'selectron-avatar-overlay-boundsdid not fix the issue. After restart, Codex regenerated a similar clipped layout:Cmd+0plus app restart did not fix it. During the broken state,~/Library/Application Support/Codex/Preferencesstill contained a Chromium zoom entry:What fixed it:
After restarting Codex and using Wake Pet, the pet rendered normally again. The
Preferencesfile now haspartition: {}.Hypothesis:
The issue seems to involve persisted Electron/Chromium zoom/profile state in addition to avatar overlay bounds. The renderer appears to measure the mascot at
80x87, while the fixed overlay window/layout still clips the visual sprite near the bottom-right. This matches the previous reports that a full app-profile reset works, but in this case deletingpartition.per_host_zoom_levelsplus resetting the overlay bounds was enough.Additional reproduction on the current macOS desktop build:
26.715.52143(build5591)Steps
Actual behavior
The pet jumps upward and returns to a position immediately above the Dock. The manually selected bottom-left position is not preserved.
Expected behavior
The pet should remain where it was placed unless its actual rectangle intersects the Dock or the screen bounds.
Technical observation
Inspection of the packaged app indicates that the native overlay lays itself out against Electron's rectangular
display.workAreaand reclamps the persisted anchor during layout/window changes. With a bottom-aligned macOS Dock, that work area excludes a full-width horizontal strip, so the unoccupied bottom-left corner is treated as unavailable too.This appears to be the same screen-edge positioning family described here, with focus/window changes exposing the re-clamping behavior. Enabling Dock auto-hide or moving the Dock to a side avoids the snap, but neither is an ideal permanent workaround.
No screenshot is attached because it contains unrelated application content.