Skip to content

Support featured plugins#15042

Open
alexsong-oai wants to merge 17 commits intomainfrom
alexs/plugins-featured
Open

Support featured plugins#15042
alexsong-oai wants to merge 17 commits intomainfrom
alexs/plugins-featured

Conversation

@alexsong-oai
Copy link
Collaborator

No description provided.

error = %err,
"plugin/list featured plugin fetch failed; returning empty featured ids"
);
Vec::new()
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO: emit failure metric

@alexsong-oai
Copy link
Collaborator Author

@codex review

@chatgpt-codex-connector
Copy link
Contributor

@alexsong-oai
Copy link
Collaborator Author

@codex review

@alexsong-oai alexsong-oai requested a review from xl-openai March 18, 2026 08:46
Copy link
Contributor

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 39be8e1ead

ℹ️ 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".

.any(|marketplace| marketplace.name == OPENAI_CURATED_MARKETPLACE_NAME)
{
let auth = self.auth_manager.auth().await;
match fetch_remote_featured_plugin_ids(&config_for_featured, auth.as_ref()).await {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Don't block plugin/list on remote featured lookup

plugin/list now awaits fetch_remote_featured_plugin_ids whenever openai-curated is present, even when forceRemoteSync is false. This turns a local listing RPC into a network-bound call; the fetch helper uses a 30s timeout, so unreachable/slow chatgpt_base_url can stall every list request and UI flow before returning. This is a significant latency regression.

Useful? React with 👍 / 👎.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have to wait for the featured plugins for directory page. Considering use a 5s timeout

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to run this in parallel with list_marketplaces_for_config?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another approach is to cache this result. we are not going to change featured plugin that often so we could cache this result.

config: &Config,
auth: Option<&CodexAuth>,
) -> Result<Vec<String>, RemotePluginFetchError> {
if !plugins_feature_enabled_from_stack(&config.config_layer_stack) {
Copy link
Collaborator

@xl-openai xl-openai Mar 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use config.feature.enabled. I have a PR to fix/remove plugins_feature_enabled_from_stack.

thread_manager
.plugins_manager()
.maybe_start_curated_repo_sync_for_config(&config, &thread_manager.session_source());
codex_message_processor.spawn_featured_plugin_ids_cache_warmup(Arc::clone(&config));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could merge this into maybe_start_curated_repo_sync_for_config and rename it to something like run_plugin_startup_jobs

.maybe_start_curated_repo_sync_for_config(
&config,
&thread_manager.session_source(),
&auth_manager,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think you can pass auth_manager.clone() directly.

let config = config.clone();
let auth_manager = auth_manager.clone();
let manager = Arc::clone(self);
tokio::spawn(async move {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should put the entire maybe_start_curated_repo_sync_for_config in a tokio::spawn

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.

2 participants