Skip to content

Server-managed  enabledPlugins  does not persist auto-installed plugin enablement #4283

Description

@thecrockster

Describe the bug

A server-managed enabledPlugins entry successfully installs a plugin, but does not enable it in the local persisted plugin state. As a result, plugin hooks are not detected on subsequent CLI starts.

Our enterprise-managed settings include:

{ "enabledPlugins": {
    "example@agentic-marketplace": true }
}

The CLI fetches this policy successfully from the server-managed settings endpoint. However, after auto-install,  ~/.copilot/config.json  records the plugin with:

{ "name": "example", "marketplace": "agentic-marketplace", "enabled": false
}

Meanwhile, the local  ~/.copilot/settings.json  contains:

{ "enabledPlugins": {}
}

Because the local empty object is treated as an authoritative allow-list, the plugin remains disabled and its  sessionStart  hook is not loaded.

Affected version

1.0.75

Steps to reproduce the behavior

  1. Configure an enterprise or organization server-managed settings file with:

"enabledPlugins": {
"example@agentic-marketplace": true
}
2. Ensure the local  ~/.copilot/settings.json  contains:
"enabledPlugins": {} }
3. Start Copilot CLI and allow the managed plugin to be auto-installed.
4. Run  copilot plugin list  or inspect  ~/.copilot/config.json .

Actual behavior

The plugin is installed but shown as  [disabled] , with  enabled: false  persisted in  config.json . Its hook is not detected on a new CLI session.

Expected behavior

A server-managed  enabledPlugins  value of  true  should enable the plugin, including during auto-install and persisted-state reconciliation. Server-managed policy should not be overridden by an empty local  enabledPlugins  object.

Additional context

The managed settings policy is received successfully. The problem appears to be that the plugin reconciler derives the desired enabled state from the local  enabledPlugins  map rather than the effective managed-merged settings.

A temporary local workaround is to add the same plugin identifier to  ~/.copilot/settings.json :

{ "enabledPlugins": {
    "example@agentic-marketplace": true }
}

Related: #3637  documents that  enabledPlugins  is a global persisted allow-list that can be clobbered by CLI sessions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:configurationConfig files, instruction files, settings, and environment variablesarea:enterpriseGitHub Enterprise (GHE/GHES) support, org policies, and enterprise settingsarea:pluginsPlugin system, marketplace, hooks, skills, extensions, and custom agents

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions