Files
codex/codex-rs/core-plugins
T
jameswt-oai 4c1c9bf327 [codex] Preserve remote plugin directory order (#28395)
## Summary

- preserve the plugin directory endpoint's response order while merging
installed state
- append unmatched installed-only plugins afterward when requested
- add focused coverage for directory order and installed-only placement

## Why

The remote marketplace merge currently reconstructs plugins through
ordered maps and sets, then sorts the result alphabetically by display
name. That discards any ordering supplied by the plugin directory
endpoint before the list reaches Desktop.

## Implementation

Directory plugin IDs are unique, so the merge now iterates the directory
vector directly in response order. For each directory plugin, it removes
matching installed state from an ID-indexed map and builds the summary.
Any entries left in the installed map are installed-only plugins and are
appended when `include_installed_only` is enabled.

There is no separate rank field, rank map, or final sort. Desktop
therefore receives directory order—including any backend ranking—and can
preserve it within its existing stable UI state tiers.

## Testing

- `just test -p codex-core-plugins` (225 passed)
4c1c9bf327 · 2026-06-15 16:09:43 -07:00
History
..