Python: Clean up MCP HTTP resources after failed connections - #9
Closed
eavanvalkenburg wants to merge 56 commits into
Closed
Python: Clean up MCP HTTP resources after failed connections#9eavanvalkenburg wants to merge 56 commits into
eavanvalkenburg wants to merge 56 commits into
Conversation
--- updated-dependencies: - dependency-name: Aspire.Hosting dependency-version: 13.5.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ft#8035) * docs: adds missing guidance for public api analyzers updates * docs: split public API analyzer guidance Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> * docs: aligns RS017 fixture with RS016 Signed-off-by: Vincent Biret <vibiret@microsoft.com> --------- Signed-off-by: Vincent Biret <vibiret@microsoft.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: baywet <7905502+baywet@users.noreply.github.com>
…ith cold scope cache (microsoft#7976) * Fix Purview scope cache miss bypass Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Optimize Purview cold scope processing Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Run Python Purview cold requests inline Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Keep Purview scope refresh best effort Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…crosoft#8038) * Chore(deps-dev): Bump uv from 0.12.5 to 0.12.6 in /python Bumps [uv](https://github.com/astral-sh/uv) from 0.12.5 to 0.12.6. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](astral-sh/uv@0.12.5...0.12.6) --- updated-dependencies: - dependency-name: uv dependency-version: 0.12.6 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Fix lab uv pin and lockfile Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com>
microsoft#8019) Bumps [@humanfs/node](https://github.com/humanwhocodes/humanfs/tree/HEAD/packages/node) from 0.16.6 to 0.16.8. - [Release notes](https://github.com/humanwhocodes/humanfs/releases) - [Changelog](https://github.com/humanwhocodes/humanfs/blob/main/packages/node/CHANGELOG.md) - [Commits](https://github.com/humanwhocodes/humanfs/commits/node-v0.16.8/packages/node) --- updated-dependencies: - dependency-name: "@humanfs/node" dependency-version: 0.16.8 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…crosoft#8009) Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.25.3 to 4.28.8. - [Release notes](https://github.com/browserslist/browserslist/releases) - [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md) - [Commits](browserslist/browserslist@4.25.3...4.28.8) --- updated-dependencies: - dependency-name: browserslist dependency-version: 4.28.8 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…links (microsoft#7777) * Python: docs: replace the stale learn-docs placeholder with the live links * Fix the Learn tutorials link
* Stamp AG-UI checkpoint owner on every save * Validate checkpoint ownership whenever a checkpoint carries an owner The resume path only compared ownership when the checkpoint had pending request info events, so a checkpoint with an owner but no pending events skipped the check entirely. Combined with stamping ownership on every save, a caller could resume another Snapshot Scope's clean checkpoint and have subsequent saves re-stamped to themselves. Validate on owner presence instead. Checkpoints saved before ownership was recorded have no owner and continue to resume unchanged. --------- Co-authored-by: Choppaaahh <choppaaahh@users.noreply.github.com>
…on (microsoft#7855) * Wrap Anthropic and Gemini SDK exceptions in ChatClientException _inner_get_response() in the OpenAI, Mistral, Ollama, and Bedrock chat clients all translate raw provider SDK exceptions into the framework's ChatClientException hierarchy (ChatClientInvalidAuthException for auth failures, ChatClientInvalidRequestException for bad requests, ChatClientException otherwise). Mistral's test suite explicitly asserts this behavior (test_get_response_http_error_wrapped, test_get_response_network_error_wrapped). The Anthropic and Gemini clients call their SDKs directly with no try/except at all, so a raw anthropic.APIError or google.genai.errors.APIError (and subclasses) propagates unwrapped. Code that catches ChatClientException to handle chat-client failures in a provider-agnostic way - the documented purpose of that base class - silently fails to catch failures from these two providers. Wraps both the streaming and non-streaming call sites in both clients, using each SDK's real exception hierarchy (verified against the installed anthropic and google-genai packages, not assumed) to classify auth vs. bad-request vs. other errors the same way Mistral already does. Adds regression tests mirroring Mistral's existing coverage: one parametrized non-streaming test per provider covering all three exception classes, plus a streaming-path test per provider. Full anthropic and gemini unit test suites pass locally (162 and 154 tests respectively, no regressions). * Address review: classify 403 as auth, wrap non-APIError failures, cover mid-stream errors - Map HTTP 403 (Anthropic PermissionDeniedError / Gemini ClientError) to ChatClientInvalidAuthException, matching Mistral's 401/403 handling. - Replace the provider-specific except chain with a catch-all that routes every non-framework exception through a _wrap_*_error helper, so transport failures and credential-refresh errors no longer escape ChatClientException. - Re-raise AgentFrameworkException (e.g. ContentError) untouched. - Extend tests to cover 403, a non-APIError fallback, and a failure raised partway through iterating the stream (generator yields then raises).
* Python: add Magentic custom manager prompts sample * docs(samples): clarify prompt placeholders
…soft#8023) * Fix checkpoint pickling of runtime raw representations * Fix checkpoint serialization review feedback * Address checkpoint serialization review follow-up * Fix package check private imports * Fix pickle state typing --------- Co-authored-by: Evan Mattson <35585003+moonbox3@users.noreply.github.com>
* Run ownership triage for feature issues * Cancel stale issue triage after retyping
…icrosoft#8036) * Chore(deps-dev): Bump ruff from 0.16.3 to 0.16.4 in /python Bumps [ruff](https://github.com/astral-sh/ruff) from 0.16.3 to 0.16.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](astral-sh/ruff@0.16.3...0.16.4) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.16.4 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Fix Ruff pins across Python workspace Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com> Co-authored-by: moonbox3 <35585003+moonbox3@users.noreply.github.com>
* Python: move Foundry eval serialization out of core Keep provider-neutral EvalItem construction in core while moving the Foundry Evals wire conversion into agent-framework-foundry. Remove the accidental experimental converter export and migrate its tests, sample, and current package documentation. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Python: mark eval item helper experimental Preserve the EVALS feature-stage warning and metadata on the private EvalItem construction helper after removing AgentEvalConverter. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Python: normalize tools for eval items Apply the standard tool normalization path when constructing EvalItems so callable tools become FunctionTool instances. Simplify the Foundry tool-call sample to use @tool-decorated functions directly. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Python: address Foundry eval review feedback Remove the stale accepted-ADR link from the Foundry Evals module and keep the tool-call sample's decorated tools directly in the agent and eval item definitions. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Python: deprecate AgentEvalConverter compatibly Keep the experimental converter import and static methods available so released Foundry packages remain compatible with their declared core 1.x range. Warn on legacy method use while modern Foundry continues to own active wire serialization. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Python: update GitHub Copilot SDK to 1.0.11 * Fix Copilot SDK 1.0.11 permission typing * Preserve Copilot permission handler compatibility * Isolate Copilot permission context compatibility type
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: aa81fffd-c616-4b3b-bd3f-c407e5959765
* Python: Add core vector store abstractions Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Python: Address vector abstraction review feedback Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Python: Track vector store feature usage Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Python: Preserve vector model decorator typing Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Python: Refine vector store public API Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Refine vector CRUD embedding controls Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f * Clarify vector ownership and generation Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f --------- Copilot-Session: 52e1edc1-384b-4163-b8bd-f659a510ad1f
…icrosoft#8037) * Chore(deps-dev): Bump zuban from 0.9.1 to 0.9.2 in /python Bumps [zuban](https://github.com/zubanls/zubanls-python) from 0.9.1 to 0.9.2. - [Release notes](https://github.com/zubanls/zubanls-python/releases) - [Commits](zubanls/zuban@v0.9.1...v0.9.2) --- updated-dependencies: - dependency-name: zuban dependency-version: 0.9.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Fix zuban lockfile resolution Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: eavanvalkenburg <13749212+eavanvalkenburg@users.noreply.github.com>
…icrosoft#8003) * Python: fix: surface AG-UI workflow intermediate events as reasoning The AG-UI workflow runner only handled "output" and "data" workflow events, so "intermediate" events (the modern designation produced by executors listed under intermediate_output_from) fell through to the generic CustomEvent fallback instead of being converted to AG-UI reasoning events. Add "intermediate" to the handled set and route intermediate text content to text_reasoning so consumers render it as a collapsible "thinking" block rather than a final assistant message. The deprecated "data" alias is treated the same as "intermediate" (per its definition as the intermediate compatibility alias in _events.py). "output" keeps the terminal-message behavior, and non-text content (tool calls and results) still emits as its native AG-UI events. Fixes microsoft#8000 * Python: address AG-UI intermediate-reasoning review feedback Follow-up to the intermediate-reasoning change on this branch, addressing maintainer review: - Preserve protected_data when re-tagging intermediate text as reasoning so the ReasoningEncryptedValueEvent and the snapshot encryptedValue survive. - Close any open reasoning block (and assistant text message) before every terminal event (RUN_FINISHED / RUN_ERROR) and before a request_info tool call, via an idempotent _drain_open_blocks() helper. Previously the post-loop cleanup emitted the reasoning end events after the terminal event, so a client that stopped at RUN_FINISHED never saw them; a request_info tool call could likewise sit inside an unclosed reasoning block. - Keep role-less AgentResponseUpdate text (and tool content) instead of dropping it to a CUSTOM workflow_output. Explicit non-assistant roles and approval requests stay excluded.
…t#7582) Bumps [actions/github-script](https://github.com/actions/github-script) from 8.0.0 to 9.0.0. - [Release notes](https://github.com/actions/github-script/releases) - [Commits](actions/github-script@ed59741...3a2844b) --- updated-dependencies: - dependency-name: actions/github-script dependency-version: 9.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ng contract onto AgentFileStore (microsoft#7671) * .NET: [BREAKING] Add file_access_read_lines and align grep with the line editor The harness file tools were line-precise when editing (file_access_replace_lines takes 1-based line numbers and file_access_grep reports them) but all-or-nothing when reading, so there was no way to see the lines around a match without reading the whole file. Adds file_access_read_lines, rendering each row as `<n>\t<line>` with everything after the tab verbatim, including the line's own terminator, so a row feeds straight back into file_access_replace_lines. That contract only holds if grep and the line editor agree on what a line is, and they did not. The stores split on '\n' and stripped '\r'; FileEditor split on '\n', '\r\n' and a lone '\r' and kept terminators. So on a file using lone '\r' terminators, grep's line 1 addressed only part of what the model was shown and editing by that number silently changed the wrong text, and on a newline-terminated file grep could report a trailing line number the editor rejected as out of range. Both stores now use FileEditor.SplitLinesKeepEnds and report the matching line verbatim. BREAKING: FileSearchMatch.Line now includes the line's terminator, and line numbers change on content containing a lone '\r' or a trailing newline. This affects file_access_grep and file_memory_grep. The whole surface is [Experimental("MAAI001")]. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Strip the whole line terminator before matching, and name args as the schema does Addresses both review comments on microsoft#7671. TrimTrailingNewline removed only "\n", so grep matched against text such as "match\r" on CRLF and lone-CR lines and an end-anchored pattern like "match$" failed even though the line's text was exactly "match". Renamed to TrimLineTerminator and it now strips "\r\n", "\n", or a lone "\r". The file_access_read_lines description and the SliceLines failure messages referred to end_line/start_line, but the generated schema exposes the arguments as endLine/startLine, so the model could be prompted to emit an invalid argument name. Both now use the schema's names. (new_line is left as-is: FileLineEdit sets it explicitly via JsonPropertyName.) Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Cover the file-system store's search loop and scope the line-number claim FileSystemAgentFileStore carries its own copy of the search loop, and its tests asserted only a line number of 1 and Assert.Contains on the snippet — no test in that file ever asserted a FileSearchMatch.Line value. Reverting its loop to Split('\n') with TrimEnd('\r') left the whole suite green, so the store that touches real files had no coverage of anything this branch changed. Mirrors the six search tests from InMemoryAgentFileStoreTests; six of the eight new cases fail against the reverted loop, and the snippet test fails on its own if the per-line advance regains the "+ 1" that the terminator-keeping split made wrong. Also scopes the parity claim to the stores in this package. file_access_grep runs through the public AgentFileStore.SearchAsync, whose contract says nothing about how content is split or whether terminators survive, while read_lines and replace_lines split through FileEditor — which is internal, so a custom store cannot reuse it even deliberately. Promising that the numbers always agree is therefore something this provider cannot honour. FileEditor.SplitLinesKeepEnds, FileSearchMatch.Line and ReadLinesAsync now say where the guarantee holds and where it does not. The tool's [Description] is left unhedged on purpose: it is prompt text, and teaching the model to doubt the line numbers would send it back to whole-file reads, which is the cost this branch exists to remove. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Drop the parity promise from the read_lines description and stop copying every line Two findings from Copilot review 4950508867. The tool description told the model, unconditionally, that grep's line numbers match read_lines and replace_lines. That text reaches the model, and it is the sentence that licenses going straight from grep to replace_lines without reading the range — which is exactly the wrong-line edit this branch exists to prevent when the store is a custom one, since AgentFileStore.SearchAsync prescribes no split. Removed. The grep -> read_lines -> replace_lines workflow in DefaultInstructions stays: it routes through a read whose numbering shares FileEditor with the editor, so the model sees the text it is about to change. TrimLineTerminator copied every line before knowing whether it matched, so a search over a newline-heavy file allocated a second copy of nearly all its text on top of SplitLinesKeepEnds. It becomes LineContentLength, and both stores now call Regex.Match(line, 0, length), which bounds the match without copying. Verified equivalent across four line shapes and four patterns, match.Index included, so the snippet offsets are untouched. LineContentLength_BoundsAnEndAnchoredMatch pins the bound; on CRLF and lone-CR lines it fails without it, while the LF and unterminated cases pass either way because .NET's '$' already matches before a trailing newline. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: [BREAKING] Move the line-numbering contract onto AgentFileStore Mirrors the Python change in microsoft#7669 so the two SDKs keep the same contract. file_access_grep took its line numbers from the store, while read_lines and replace_lines re-counted them from ReadAsync. SearchAsync was abstract with no numbering contract, so a custom store could make "line 5" mean two different things and replace_lines would edit the wrong line, in range, reporting success. FileMemoryProvider had the same hole. The rule now lives on the base class: - SplitLines() publishes the split every line_number addresses. Per-SDK: it is not required to match Python, only to be consistent here, because a line number never crosses runtimes. - ScanContent() is the numbering primitive. Both shipped stores now report through it, which also removes the scan loop that was duplicated between them. - FindMatchingFilesAsync() is a new hook for narrowing the search to the files worth reading. The regex goes down as a hint with superset semantics: over-returning is harmless because the base re-scans, under-returning loses matches. A backend with a native index overrides it and narrows server-side. Its default works, built from ListChildrenAsync, so a store that implements nothing beyond the mandatory members now gets aligned numbers for free. - SearchAsync is no longer abstract. It reads and numbers candidates itself, and re-applies the glob and the non-recursive rule, since the hook may over-return. Overriding SearchAsync stays first-class -- a backend that can do the whole job natively should -- but then it owns numbering, and both providers verify it: each reported line is re-matched against the line the editor would touch, and the whole call is refused on a mismatch. It compares by pattern rather than by string, because a custom store is not bound to report the line verbatim and comparing text would reject correct stores. Two ways to opt out: a store sets ReportsAlignedLineNumbers, or a provider takes DisableSearchAlignmentCheck. The store flag is narrower and preferred. Both are promises rather than hints, and a test pins that hazard on purpose. FileLineEdit also gains an optional ExpectedLine. When supplied, the edit is refused unless the target line still says what the caller saw, which catches splitter drift, a stale line number, and the file changing between read and write. Two things differ from the Python half, both deliberate: No batching. Both stores already construct the regex with a match timeout, so ReDoS protection is in the engine and there is no thread offload to amortise. Python needs one; this does not. No reflection. Detecting whether a store overrides SearchAsync via GetType().GetMethod trips IL2075 and is not trim-safe, so the base implementation records that it ran instead -- which is also more accurate, being set by the call that produced the results. BREAKING: SearchAsync is no longer abstract, and a store whose line numbers disagree with SplitLines now has its grep results refused rather than silently applied. Removing abstract while keeping the member virtual passes Package Validation; verified by building the package in Release. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * .NET: Fix two holes in the search alignment check and four stale contract docs From Copilot's review of the rebased head (review 4983864371). SearchAlignment validated only the upper bound of a reported line number, so a store reporting 0 or a negative one indexed out of range and surfaced a raw ArgumentOutOfRangeException instead of the misalignment error the check exists to report. Both bounds are checked now. A RegexMatchTimeoutException on one line returned from the whole check, so every later match and file in the call was handed to the model as though it had passed verification. It now skips that match and keeps going. Python already fails closed here via asyncio.wait_for, so this was a .NET-only divergence. Four doc comments still described the design as it was before the contract commit, telling the reader the opposite of what the code now does: - FileAccessProvider read_lines remarks said grep's contract does not prescribe a split, so a custom store may report incompatible numbers. It does prescribe one, and results that disagree are refused. - FileSearchMatch said a custom store is not held to either property. It is not held to the text, but the number must address SplitLines. - FileEditor.SplitLinesKeepEnds said a custom SearchAsync is not required to use this split. It is required to; it just does not inherit it. - FindMatchingFilesAsync told implementers a dialect mismatch costs recall and nothing else, contradicting the superset rule three lines above it. Recall loss is precisely the failure the rule forbids, so it now says to widen rather than guess. The narrowing test deliberately under-returns from the hook, which is the very violation the contract names. That is the only way to prove the hook decided what got read, and the comment now says so rather than appearing to bless it. Two new tests, each confirmed to fail without its fix. Reaching the timeout path needs a budget shorter than the five-second default, so ThrowIfMisalignedAsync takes an optional per-line timeout; nothing outside the tests passes it. Two findings from the same review are deliberately not actioned. The expected_line mismatch message reveals the current line, which is a read oracle where write tools are auto-approved and read tools are not; removing it defeats the message's purpose, and Python carries the identical text, so that is a maintainer call. The ADR request is likewise left open: the requirement is stated in .github/copilot-instructions.md rather than CONTRIBUTING.md, and the process needs deciders an external contributor cannot nominate. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Mo3qRizH73Gtpviqf5BjP7 * .NET: State the line-counting rule in the tools and give memory its own refusal Mirrors the Python changes in microsoft#7669, which came out of @westey-m's review there. The tool descriptions never said how lines are counted. A model that reads a whole file with file_access_read and then edits by number has to count them itself, and nothing told it the rule. read, read_lines, replace_lines and grep now state it, as do the two memory tools that take or report line numbers. The rule is deliberately not the one Python states, and the wording must not be copied between the two SDKs. Here a lone \r terminates a line and content ending in a terminator has no trailing empty line; in Python neither is true. Taken from the cases FileEditorTests already pins rather than from reading the splitter. SearchAlignment's refusal is shared by both providers and names read_lines, which FileMemoryProvider does not register -- there is no file_memory_read_lines at all. ThrowIfMisalignedAsync now takes the message from the caller, defaulting to the existing wording, and the memory provider passes one naming file_memory_read. CreateToolsAsync in the memory tests was typed to InMemoryAgentFileStore, which is sealed, so a skewed double could not be passed to it. Widened to AgentFileStore. The new test was confirmed to fail against the file-access wording. Removing the call argument instead only breaks the build, which shows the constant has one consumer but not that the assertion discriminates. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Mo3qRizH73Gtpviqf5BjP7 * .NET: Make the base-results trust marker prove integrity, not just provenance From Copilot review 4985186414. BaseSearchResults marked a list as numbered by the base SearchAsync, and IsTrusted skipped verification on the strength of the type alone. Everything in the payload is mutable -- the list itself, FileSearchResult.FileName and MatchingLines, FileSearchMatch.LineNumber -- so an override could await base.SearchAsync, renumber the results in place, and return the very same instance. The marker survived, verification was skipped, and the wrong-line edit it exists to prevent was reachable again. This is not only a hostile-store concern. A store that prepends a header in ReadAsync and "corrects" the base's numbers to compensate is the same shape as the Python defect fixed in microsoft#7669, and it would have kept full trust here. The marker now snapshots the file names and line numbers it was constructed with, and IsUnmodified re-checks them before trust is granted. The tag says who built the list; the snapshot says the numbers in it are still theirs. Comparison is exact rather than hashed, because a collision would mean false trust, which is the one direction this must not fail in. A modified list drops to verification rather than failing outright, matching the conservative posture elsewhere. FileSearchMatch.Line is deliberately excluded. A custom store may report the text differently -- that is why the check matches by pattern rather than by string -- so covering it would reject stores doing something the contract permits. The type's own documentation claimed an override that post-processes the base results loses the tag. That was true only of post-processing into a new list, and is corrected here. Python needs no equivalent: _numbers_are_trusted keys on the store type and the identity of the base search function, neither of which a store can mutate. This gap existed only because .NET routes around GetType().GetMethod for trim-safety. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Mo3qRizH73Gtpviqf5BjP7 * .NET: Replace the runtime alignment check with a documented contract From @westey-m's review. Policing implementations that are not per spec is not worth the cost at runtime; the expectation belongs on the type an implementer is reading when they get it wrong. A conformance test library, which is the real answer for checking an implementation, is tracked separately as microsoft#7931. SearchAlignment and BaseSearchResults are deleted, along with ReportsAlignedLineNumbers and its two overrides and DisableSearchAlignmentCheck on both provider options. SearchAsync returns its results directly instead of a tagged list, and neither provider verifies what a store reports. The contract those types enforced now sits on SearchAsync itself: a store overriding it must number FileSearchMatch.LineNumber as a 1-based coordinate into SplitLines of the content ReadAsync returns, ScanContent builds that correctly, and numbering against anything else is a bug whose failure mode is silent -- the search looks right, and the damage appears when a later line edit applies to a line the caller never saw. Two doc comments elsewhere still said the tools verify the numbering, which is no longer true of either. The FileSearchMatch and FileEditor remarks also scoped the rule to the stores shipped here rather than stating what implementers owe; both now read as expectations, which the same review asked for. Descriptions that state the line-counting rule now also say the numbers are 1-based, so a model counting lines from a whole-file read knows where to start. Eight tests went with the check: seven alignment cases and their six helper stores in AgentFileStoreContractTests, and the memory-refusal test with its skewed store in FileMemoryProviderTests. Nothing exercised the removed types otherwise; the remaining 2099 unit tests pass. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Drop two usings left dead by the alignment-check removal From Copilot review 5051570368. Both are fallout from 72a1f03 rather than pre-existing: removing SkewedMemoryStore took the last CancellationToken out of FileMemoryProviderTests, and removing the shipped-stores trust test took the last Path.GetTempPath() out of AgentFileStoreContractTests, leaving System.Threading and System.IO imported for nothing. Neither surfaced in the build because unused usings are not an error here. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Pin the snippet offset for every terminator, and drop a stale test rationale From Copilot review 5052352338. SearchFiles_SnippetIsAnchoredAtTheMatch exercised the per-line offset with LF only, so it would have passed had ScanContent advanced by content length plus one rather than by the line's own length -- correct for LF and a lone CR, a character short for CRLF. It is now a theory over all three, and the expected snippet derives from the terminator length instead of hardcoding 49 padding characters. Confirmed by making that exact substitution in ScanContent: the CRLF case fails and the other two pass, which is what the single-Fact version could not see. The comment above the mirrored filesystem search tests still said that store carries its own copy of the search loop. It does not: both stores now number through AgentFileStore.ScanContent, which was one of the goals of this PR, so the rationale contradicted the code. Reworded as what those tests actually add -- the same rules exercised against real files, where content arrives through a decoded read rather than an in-memory string. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Cover the read_lines approval group in the isolated option tests From the suppressed comment on Copilot review 5053203365. DisableReadOnlyToolApproval_ReadOnlyToolsNotWrapped and its write counterpart enumerated read, ls and grep on one side and the four store-modifying tools on the other, but never read_lines. Nothing else discriminated which group it is wired into: the auto-approval theory covers a different mechanism, and DisableBothToolApprovals only counts tools. Wiring read_lines to writeRequiresApproval would therefore have reversed the approval boundary for a read tool with every test still green. Both tests now assert it alongside the other read-only tools. Confirmed by making that substitution in FileAccessProvider: both fail, and the other 2114 tests pass, which is what makes the gap the finding describes visible rather than theoretical. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Say which part of a numbered read expected_line takes From the suppressed comment on Copilot review 5053896798. The expected_line description told the caller to use the text "as reported by grep or read_lines". read_lines prefixes each line with its number and a tab, so a model following that literally can pass the whole row, which never matches: the editor compares the line's own text. It now says to give the line text only and names the prefix it must not include. read_lines is also the wrong tool to name here at all. FileLineEdit is shared by FileAccessProvider and FileMemoryProvider, and the memory provider registers no read_lines tool, so half the callers were pointed at something that does not exist for them. grep is named instead, which both providers do register. The XML doc above the property carried the same gap and now states the rule too, since that is what an implementer reads rather than the tool description. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: State the hook's case semantics, and stop claiming containment on a mismatch From the two suppressed comments on Copilot review 5058964476. FindMatchingFilesAsync took the regex and the glob as hints without saying how either is compared. SearchAsync builds its regex with RegexOptions.IgnoreCase and StorePaths.CreateGlobMatcher uses OrdinalIgnoreCase, so a backend pushing either hint into a case-sensitive index returns only case-exact candidates and drops matches before the base ever re-scans. That is the under-return the superset rule exists to forbid, and nothing in the contract warned against it. Both parameters now state the comparison and require widening when the backend cannot reproduce it. The expected_line mismatch said the line "does not contain the expected text" while the check is exact equality after trimming terminators. For actual foobar and expected foo the line does contain it, so the model was handed a diagnostic that contradicts what it can see and would send it re-reading a file that had not changed. It now says the line does not match, and the contract test that pinned the old wording follows. Confirmed the assertion discriminates by putting the old wording back: ApplyReplaceLines_ExpectedLineDiffering_Throws fails and the other 2115 pass. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Say what FindMatchingFilesAsync narrows on, and why a store would override it From @westey-m's review. The summary described the hook by the regex alone, which reads as though the glob were someone else's concern. It now names both: files that may contain text matching the pattern, and whose names may match the glob. Taken from the suggestion, with the missing space after </em> restored. The remarks said what the default implementation does but never why anyone would replace it. They now state the purpose: override when the backing store can answer either question more cheaply -- a name index for the glob, a content or full-text index for the regex -- with the store doing the narrowing it is good at and the base keeping the scanning and the line numbering. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Declare this PR's API surface for the new public API analyzers Build fix, not a change in behaviour. The analyzers landed on main in 0822dd7 after this branch was last built, so every member this PR adds or changes was undeclared: RS0016 for the seven new symbols, and RS0017 for the shipped abstract SearchAsync, which this PR made virtual and which therefore no longer exists as declared. All eight are recorded in PublicAPI.Unshipped.txt for the five target frameworks, which stay byte-identical to each other as they were before. The retired signature is marked with *REMOVED* rather than deleted from PublicAPI.Shipped.txt. That is the analyzer's own mechanism for retiring a shipped member, and it keeps the abstract-to-virtual change visible as a line in this PR's diff instead of a silent deletion from a shipped baseline. Nothing in the repo has needed it before, since the analyzers are three days old. Reproduced locally first: the same eighty RS001x errors CI reported, now zero in both Debug and Release, with 2116 unit tests passing. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Stop the default tree walk when the token is already cancelled From Copilot review 5110306826. FindMatchingFilesAsync passed the token to ListChildrenAsync but never checked it itself, so a store whose listing ignores the token kept the walk going after cancellation, one listing per directory. The contract-test store is exactly that shape: it takes a CancellationToken and never reads it. SearchAsync then threw on its first candidate, which hid the wasted work behind a correct-looking exception. The walk now checks before each listing and before each entry. BaseSearch_StopsWalkingWhenCancelledEvenIfTheStoreIgnoresTheToken pins it by counting listings rather than by asserting an exception: with the fix zero listings happen, and without it twenty-one. The first version of this test asserted only that OperationCanceledException was thrown and passed against the unfixed code, because SearchAsync throws either way -- the exception was never the thing worth measuring. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * .NET: Guard ScanContent's fileName alongside its other parameters From the suppressed comment on Copilot review 5110771736. ScanContent validated content and regex and left fileName alone, so a null went through and landed in FileSearchResult.FileName, which is a non-nullable string. The gap only shows when the scan matches: with no match the method returns null and the bad argument never surfaces, which is why nothing had caught it on a member this PR makes public. ScanContent_NullFileName_Throws pins it with a pattern that does match, for that reason. Without the guard it fails on "No exception was thrown" rather than on a wrong exception type, which is the defect rather than a near miss. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* Bump Anthropic from 12.42.0 to 12.43.0 --- updated-dependencies: - dependency-name: Anthropic dependency-version: 12.43.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Implement Anthropic beta organization interface Co-authored-by: rogerbarreto <19890735+rogerbarreto@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: rogerbarreto <19890735+rogerbarreto@users.noreply.github.com>
…8027) * Bump AgentMemory.AgentFramework from 1.4.1 to 1.5.0 --- updated-dependencies: - dependency-name: AgentMemory.AgentFramework dependency-version: 1.5.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Bump AgentMemory to 1.5.0 to match AgentMemory.AgentFramework Co-authored-by: rogerbarreto <19890735+rogerbarreto@users.noreply.github.com> * Add dependabot group for AgentMemory packages Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: rogerbarreto <19890735+rogerbarreto@users.noreply.github.com> Co-authored-by: baywet <7905502+baywet@users.noreply.github.com>
Bumps [actions/labeler](https://github.com/actions/labeler) from 6.1.0 to 7.0.0. - [Release notes](https://github.com/actions/labeler/releases) - [Commits](actions/labeler@f27b608...bf12e9b) --- updated-dependencies: - dependency-name: actions/labeler dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…icrosoft#8067) Bumps [github/codeql-action/analyze](https://github.com/github/codeql-action) from 4.37.3 to 4.37.9. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@e4fba86...cdf488f) --- updated-dependencies: - dependency-name: github/codeql-action/analyze dependency-version: 4.37.9 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…crosoft#8066) Bumps [github/codeql-action/init](https://github.com/github/codeql-action) from 4.37.3 to 4.37.9. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@e4fba86...cdf488f) --- updated-dependencies: - dependency-name: github/codeql-action/init dependency-version: 4.37.9 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* backup * .NET: Always create A2A agent run options Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 1a876988-01c0-4110-9517-77aba4bf41a8 * .NET: Decouple A2A run mode from agent options Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 1a876988-01c0-4110-9517-77aba4bf41a8 * .NET: Clarify dynamic A2A run mode scope Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 1a876988-01c0-4110-9517-77aba4bf41a8 * .NET: Remove redundant run mode assertion Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 1a876988-01c0-4110-9517-77aba4bf41a8 --------- Co-authored-by: SergeyMenshykh <SergeMenshikh@outlook.com> Copilot-Session: 1a876988-01c0-4110-9517-77aba4bf41a8
) Bumps [dorny/paths-filter](https://github.com/dorny/paths-filter) from 4.0.2 to 4.0.3. - [Release notes](https://github.com/dorny/paths-filter/releases) - [Changelog](https://github.com/dorny/paths-filter/blob/master/CHANGELOG.md) - [Commits](dorny/paths-filter@7b450ff...ceb8a2b) --- updated-dependencies: - dependency-name: dorny/paths-filter dependency-version: 4.0.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* ci: switches to dedicated identity for promotion PRs Signed-off-by: Vincent Biret <vibiret@microsoft.com> * security: trims permissions because we're using a dedicate identity now Signed-off-by: Vincent Biret <vibiret@microsoft.com> * ci: aligns tasks permissions with application declaration Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * ci: use app bot identity for API promotion commits Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --------- Signed-off-by: Vincent Biret <vibiret@microsoft.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: baywet <7905502+baywet@users.noreply.github.com>
…#8077) Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.6.0 to 7.0.0. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](actions/setup-python@a26af69...5fda3b9) --- updated-dependencies: - dependency-name: actions/setup-python dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps the codeql-actions group with 1 update in the / directory: [github/codeql-action/autobuild](https://github.com/github/codeql-action). Updates `github/codeql-action/autobuild` from 4.37.0 to 4.37.9 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@99df26d...cdf488f) --- updated-dependencies: - dependency-name: github/codeql-action/autobuild dependency-version: 4.37.9 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: codeql-actions ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* docs: clarify declarative workflow input serialization * docs: add workflows namespace to serialization snippet
…osoft#7984) * .NET: Preserve streamed response annotations Capture annotations delivered separately from text and emit supported citation types through hosted Responses streams. Add local and live streaming and non-streaming coverage for web search and Azure AI Search. Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf * .NET: Refine streamed annotation correlation Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf * .NET: Align annotation event with OpenAI 2.12 Use the renamed output text annotation event so item correlation remains available after the SDK upgrade. Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf * .NET: Update annotation integration tests for SDK changes Use the renamed strongly typed annotation event and unwrap project connection results after the Projects 3 upgrade. Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf * .NET: Use hosted Search index in CI Use the dedicated hosted-agent Search index configuration for Foundry hosted integration tests. Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf --------- Copilot-Session: 0c67da26-d12e-47ab-aac4-53e251ef6edf
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.4.0 to 7.0.0. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](actions/setup-node@48b55a0...8207627) --- updated-dependencies: - dependency-name: actions/setup-node dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
) Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.4.0 to 7.0.0. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](actions/setup-node@v4.4.0...8207627) --- updated-dependencies: - dependency-name: actions/setup-node dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…client path (microsoft#8095) A2AAgent(url=..., http_client=mine) never set _close_http_client, so exiting the async context manager raised AttributeError instead of leaving the caller's client alone. Default the flag to False up front; the two paths that create the client still flip it to True. Fixes microsoft#7950 Signed-off-by: Yufeng He <40085740+he-yufeng@users.noreply.github.com>
…icrosoft#8090) * Docs: fix broken external links in Python samples and docs * Docs: align Toolbox overview description with target page content
* Python: Document anonymous Parallel Search MCP usage * Python: Avoid duplicate MCP sample output and guard entry point
Co-authored-by: UniversePeak <UniversePeak@users.noreply.github.com>
…crosoft#8062) * Chore(deps-dev): Bump ty from 0.0.72 to 0.0.75 in /python Bumps [ty](https://github.com/astral-sh/ty) from 0.0.72 to 0.0.75. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](astral-sh/ty@0.0.72...0.0.75) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.75 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Python: Update lockfile for ty 0.0.75 Co-authored-by: moonbox3 <35585003+moonbox3@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: moonbox3 <35585003+moonbox3@users.noreply.github.com>
* ci: adds python dependabot groups * ci: add pyright Dependabot group Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> * Group basic Python dependencies Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…soft#7835) An MCPTool handed to ClaudeAgent or GitHubCopilotAgent was silently dropped: no error, no warning, and none of its tools reached the model. Both SDKs connect to MCP servers themselves and take their own mcp_servers config, so the framework cannot honor a framework-managed MCPTool there. It is now refused with the native configuration to write instead.
* Python: Scope MCP HTTP headers per tool Keep provider header processing associated with the MCP tool that issued each request, including when HTTP clients are shared. Clean up request hooks on close and preserve redirect handling. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4fca7430-5806-4fb4-a190-729e2473c5bb * Python: Refresh MCP headers across redirects Remove previously injected provider headers before applying the latest set so redirected requests retain only current provider output. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4fca7430-5806-4fb4-a190-729e2473c5bb * Python: Defer MCP hook cleanup until teardown Keep the request hook attached while lifecycle-owner transport cleanup runs, including when the caller awaiting close is cancelled. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4fca7430-5806-4fb4-a190-729e2473c5bb * Python: Preserve active MCP hook iteration Replace the shared request-hook list during cleanup so in-flight HTTPX hook iteration is not disrupted. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4fca7430-5806-4fb4-a190-729e2473c5bb --------- Copilot-Session: 4fca7430-5806-4fb4-a190-729e2473c5bb
…crosoft#8100) Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release) from 3.0.2 to 3.0.3. - [Release notes](https://github.com/softprops/action-gh-release/releases) - [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md) - [Commits](softprops/action-gh-release@3d0d988...efb3536) --- updated-dependencies: - dependency-name: softprops/action-gh-release dependency-version: 3.0.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [azure/login](https://github.com/azure/login) from 2.3.0 to 3.0.2. - [Release notes](https://github.com/azure/login/releases) - [Commits](Azure/login@a457da9...7ddb5af) --- updated-dependencies: - dependency-name: azure/login dependency-version: 3.0.2 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…icrosoft#8112) Bumps [azure/login](https://github.com/azure/login) from 2.3.0 to 3.0.2. - [Release notes](https://github.com/azure/login/releases) - [Commits](Azure/login@a457da9...7ddb5af) --- updated-dependencies: - dependency-name: azure/login dependency-version: 3.0.2 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [azure/login](https://github.com/azure/login) from 2.3.0 to 3.0.2. - [Release notes](https://github.com/azure/login/releases) - [Commits](Azure/login@a457da9...7ddb5af) --- updated-dependencies: - dependency-name: azure/login dependency-version: 3.0.2 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Register header-hook and owned HTTP client cleanup on the MCP session exit stack so failed initialization, cancellation, reconnects, and shutdown release resources without closing caller-owned clients. Preserve the request-scoping and redirect behavior from microsoft#8039 and cover shared-client declarative cache reuse and eviction. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
eavanvalkenburg
had a problem deploying
to
github-app-auth
September 7, 2026 14:28 — with
GitHub Actions
Failure
eavanvalkenburg
had a problem deploying
to
github-app-auth
September 7, 2026 14:28 — with
GitHub Actions
Failure
eavanvalkenburg
had a problem deploying
to
github-app-auth
September 7, 2026 14:29 — with
GitHub Actions
Failure
eavanvalkenburg
temporarily deployed
to
integration
September 7, 2026 14:30 — with
GitHub Actions
Inactive
eavanvalkenburg
temporarily deployed
to
integration
September 7, 2026 14:30 — with
GitHub Actions
Inactive
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation & Context
The request-scoping fix in microsoft#8039 preserves per-tool headers when MCP tools share an HTTP client. Connection failures still leave request hooks attached until callers explicitly close the tool, and HTTP clients allocated by the framework are not closed with the MCP session.
This follow-up ties those resources to the existing session exit stack, covering unsuccessful initialization and cancellation as well as normal shutdown and reconnects. It preserves the merged request-ownership and redirect protections rather than replacing them.
Description & Review Guide
Related Issue
N/A — no public issue is linked. Follow-up to the merged microsoft#8039, limited to remaining resource-lifecycle gaps and regression coverage. The open microsoft#7892 adds static connect-time headers and addresses a different concern.
Contribution Checklist
breaking changelabel (or add "[BREAKING]" to the title prefix, before or after any language prefix) — a workflow keeps the label and the title prefix in sync automatically.