GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — fix(mcp): remove writeEnabled from Start() to prevent readonly state desync by Elvand-Lie · Pull Request #3758 · knative/func Conversation
Contributor
SummaryFixes #3755 The If a caller passes inconsistent values, the MCP instructions will tell the agent it is in read-only mode while the server actually permits deploy and delete operations, or vice versa. Changes
Testing
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
|
There was an error while loading. Please reload this page.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@ ## main #3758 +/- ## ========================================== + Coverage 56.83% 56.86% +0.03% ========================================== Files 185 185 Lines 21739 21738 -1 ========================================== + Hits 12355 12362 +7 + Misses 8132 8124 -8 Partials 1252 1252
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
cfb26fb to
9e70d90
Compare
|
/lgtm |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Elvand-Lie, lkingland The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…desync The Server.Start() method unconditionally overrides the readonly state that was already set by WithReadonly() during construction. This creates a dual source of truth: instructions are computed from the readonly flag at construction time (in New()), but the actual enforcement value is overridden at Start() time. If a caller passes inconsistent values, the MCP instructions will tell the agent it is in read-only mode while the server actually permits deploy and delete operations, or vice versa. Fix by removing the writeEnabled parameter from Start() entirely. The readonly state is now set exclusively via WithReadonly() at construction time, which is also when instructions are computed. This ensures a single source of truth. Signed-off-by: Elvand Lie <[email protected]>
9e70d90 to
03ab530
Compare
|
/lgtm |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
bug(mcp): Server.Start() unconditionally overrides readonly state set by WithReadonly()
There was an error while loading. Please reload this page.