Hyphenated action names fail Semantic Kernel loading silently; add permission-aware recovery in both chat UIs
I maintainer di solito rispondono entro 1 giorno
@paullizer ci sta già lavorando.
Dal 19/10/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Issue
SimpleChat accepts action names containing hyphens, but passes those names directly to Semantic Kernel as plugin identifiers. Semantic Kernel rejects them. The selected agent can then continue without its assigned actions, producing a misleading response such as “I cannot create calendar events” rather than explaining that an action failed to load.
This was observed while comparing a working personal Microsoft 365 agent with a FED-harness-created agent. The harness correctly assigned a source-specific calendar action by ID. The failure is not a special-case restriction to an agent named m365.
Steps to Reproduce
- Create a source-specific Microsoft 365 calendar action with a schema-valid name such as
calendar-demoand enable the calendar-create capability. - Assign that action to an otherwise valid local agent.
- Select the agent in chat and request a calendar draft. Do not approve or send any event for this reproduction.
- Observe action registration fail with
KernelFunction failed to initialize: Failed to create KernelFunctionMetadata. - Compare with an action named
m365_calendar: kernel registration succeeds.
A network-free reproduction is to call KernelPlugin.from_object with an inert decorated method and the two plugin names; no calendar operation needs to execute.
Expected Behavior
- Any authorized agent can use its assigned actions regardless of schema-supported action naming, subject to normal capability, authentication, and approval policies.
- User-facing names and stable scoped action identities remain unchanged. Runtime-only plugin identifiers must meet SDK/provider requirements without colliding.
- A failed action is identified clearly before the user proceeds with an incomplete agent.
- Both V2 and classic chat offer equivalent confirmation and remediation flows.
Actual Behavior
static/json/schemas/plugin.schema.jsonallows^[A-Za-z0-9_-]+$.- Semantic Kernel's
PLUGIN_NAME_REGEXis^[0-9A-Za-z_]+$; its agent-name regex separately permits hyphens. - The logged loader and legacy fallback both pass the stored action name into kernel registration.
- In the affected chat, telemetry shows the correct agent selected, its single action manifest resolved, both registration attempts failed, and zero tool invocations. Chat nevertheless produced an ordinary assistant answer.
- The working comparison registered
m365_calendarand successfully invokedcreate_calendar_invite. - The same registration error was also found for FED email, OneDrive, and SharePoint actions.
Impact
Schema-valid actions can be unusable even when correctly assigned and authorized. Harness failures look like capability or Microsoft 365 configuration problems. Users cannot distinguish missing capability from a broken action or determine who can remediate it. Fixing only harness naming would conceal the application boundary mismatch.
Priority: P1 (user-selected). Size: L (shared runtime, permissions, notifications, and two chat interfaces).
Notes
Confirmed cause and evidence
Read-only Application Insights and App Service console investigation confirmed the registration sequence and fallback failure. No live actions, credentials, or configuration were changed.
An offline probe using locally installed Semantic Kernel 1.35.0 produced:
m365_calendar: registration passes.- A FED-style hyphenated action name: registration fails; the chained Pydantic error identifies
plugin_nameand^[0-9A-Za-z_]+$. - The same name using underscores: registration passes.
The repository pins semantic-kernel==1.39.4; the same plugin-name restriction was separately verified in that version's published source:
- https://github.com/microsoft/semantic-kernel/blob/python-1.39.4/python/semantic_kernel/utils/validation.py
- https://github.com/microsoft/semantic-kernel/blob/python-1.39.4/python/semantic_kernel/functions/kernel_function_metadata.py
Relevant application code:
application/single_app/semantic_kernel_plugins/logged_plugin_loader.py: registration and swallowed failure results.application/single_app/semantic_kernel_plugins/msgraph_plugin.py:get_kernel_pluginforwards the supplied name.application/single_app/semantic_kernel_loader.py: selected-action resolution, legacy fallbacks, captured-agent invariants, and continuation after load failure.application/single_app/functions_orchestration_actions.py: shared action-loader consumer.application/single_app/static/json/schemas/plugin.schema.json: accepted action-name contract.
Agreed recovery behavior
- Identify the affected agent and action(s), explain which capabilities are unavailable, and ask whether to continue without those failed actions. Do not silently degrade or permanently remove assignments.
- Offer an action-edit link for personal/group actions only when current server-side permissions allow editing. Otherwise offer remediation guidance and Notify owner/admin.
- For global actions, notify the responsible application administrators; authorized administrators may receive the existing admin editor link. Route remediation by the action's actual scope, not merely the agent's scope.
- Notify owner/admin is user-triggered, in-app, and deduplicated. Do not automatically notify on every failure. Reports contain only safe action identifiers, failure category, and diagnostic correlation—not prompts, tool outputs, secrets, or raw exception text.
- Reuse existing credential/sign-in/approval recovery for supported authentication failures, including rejected credentials. A generic failure must not be mislabeled as a bad password, and credentials cannot be verified for every connector merely by selecting an agent.
- Preserve current work while remediation is performed. Recheck action revision, membership, and policy before continuation. Never automatically replay a calendar/email write or treat continuing without an action as consent to any operation.
- Apply equivalent behavior in V2 and classic chat, with accessible confirmation, status, and navigation.
Acceptance Criteria
- A schema-valid hyphenated action registers through the shared loader and applicable fallback paths; valid existing runtime names remain compatible.
- Runtime aliases are deterministic and collision-safe, including dash/underscore variants, duplicate names across scopes, long names, and collisions with core plugins.
- Stored action names/IDs, secret lookup identities, assignments, M365 approval provenance, and orchestration capture boundaries remain intact.
- Calendar/email/OneDrive/SharePoint and representative non-M365 actions are covered by registration tests with external I/O blocked.
- Failed actions produce a safe, structured, request-bound recovery state instead of an ordinary model response hiding the failure.
- V2 and classic users can review failures, cancel/change agent, remediate/recheck, or explicitly continue with only the remaining authorized actions.
- Personal/group/global remediation links and notification recipients are permission-checked server-side, including permission changes during recovery.
- Notification retries do not duplicate reports or reset recipient read/dismissal state.
- Supported credential rejection/sign-in paths retain existing recovery behavior; policy/approval denials and uncertain write outcomes cannot be bypassed or blindly retried.
- Add functional, route-policy, and Azure Playwright UI coverage; update documentation, chat-control inventory where applicable, and application patch version.
Validation already performed
python -m pytest -q -p no:cacheprovider functional_tests\test_m365_provider_core.py::test_calendar_and_email_default_kernel_names_are_source_specific functional_tests\test_m365_provider_core.py::test_all_typed_plugins_register_without_source_access_or_execution_context
Passed: 2 tests, with existing dependency deprecation warnings. These tests use safe default names and do not cover the reported naming failure. The offline hyphenated-name probe separately reproduced that failure.
Investigation/planning only so far; implementation and deployment are not yet approved.
- Lingua principale
- Python
- Stelle
- 157
- Fork
- 117
- Merge medio
- 4h 15m
- PR unite (30g)
- 208
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoft/simplechat
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
microsoft/simplechat#1491 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
microsoft/simplechat#1370 ·
I maintainer di solito rispondono entro 1 giorno
-
Simple Chat - NLRAperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 55/100
microsoft/simplechat#1804 ·
I maintainer di solito rispondono entro 1 giorno
-
Simple Chat - NLRAperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 48/100
microsoft/simplechat#1803 ·
I maintainer di solito rispondono entro 1 giorno
-
V2: triage multi-turn UI failures and make saved-memory orchestration validation reliableForse già presa @paullizer l’ha presa 2 giorni fa. Apertabug P1
microsoft/simplechat#1785 · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di microsoft/simplechat
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
zach-blumenfeld/aip#13 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
nathanmarlor/foxess_modbus#1287 ·
I maintainer di solito rispondono entro 4 giorni
-
bug good first issue help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
OpenLakeForge/openlakeforge#498 ·
I maintainer di solito rispondono entro 1 giorno
-
good first issue hacktoberfest help wanted python
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 69/100
pollen-robotics/reachy_mini#1493 ·
I maintainer di solito rispondono entro 1 giorno