azure-search-documents 12.0.0 GA release for API version 2026-04-01#45810
azure-search-documents 12.0.0 GA release for API version 2026-04-01#45810
Conversation
ee9633c to
b2ab9d7
Compare
There was a problem hiding this comment.
Pull request overview
Major-version GA release update for azure-search-documents, regenerating from the Search data-plane TypeSpec and aligning the Python surface area with the 2026-04-01 API (including removal of preview-only types/features not promoted to GA).
Changes:
- Regenerated SDK and bumped package version to
12.0.0with default API version2026-04-01. - Removed preview-only models/enums/parameters (notably several search/debug/hybrid/vector threshold and SharePoint-related types) and updated tests accordingly.
- Updated model serialization/deserialization helpers and streaming response handling (added
decompressoption gatingiter_bytes()vsiter_raw()).
Reviewed changes
Copilot reviewed 43 out of 45 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| sdk/search/azure-search-documents/tsp-location.yaml | Updates TypeSpec source commit used for generation. |
| sdk/search/azure-search-documents/tests/test_search_client.py | Updates facet aggregation test expectations to match GA model shape. |
| sdk/search/azure-search-documents/tests/test_knowledge_source_remote_sharepoint_live.py | Removes live tests for SharePoint knowledge source types that are no longer in GA. |
| sdk/search/azure-search-documents/tests/test_knowledge_base_live.py | Removes service statistics runtime test tied to removed types. |
| sdk/search/azure-search-documents/tests/test_knowledge_base_configuration_live.py | Updates knowledge base config tests to match removed reasoning effort shape. |
| sdk/search/azure-search-documents/tests/async_tests/test_knowledge_source_remote_sharepoint_live_async.py | Removes async live tests for removed SharePoint knowledge source types. |
| sdk/search/azure-search-documents/tests/async_tests/test_knowledge_base_live_async.py | Mirrors sync test removals for async knowledge base tests. |
| sdk/search/azure-search-documents/tests/async_tests/test_knowledge_base_configuration_live_async.py | Mirrors sync reasoning-effort test updates for async. |
| sdk/search/azure-search-documents/azure/search/documents/models/_models.py | Removes preview-only models/properties (debug info, hybrid search, facet metrics, vector thresholds, etc.). |
| sdk/search/azure-search-documents/azure/search/documents/models/_enums.py | Removes preview-only enums (query language/speller/rewrites, vector threshold kinds, etc.). |
| sdk/search/azure-search-documents/azure/search/documents/models/init.py | Updates public exports to match removed models/enums. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/models/_models.py | Aligns knowledgebase models with GA API (removes SharePoint variants; adds sync error model; renames max output size field). |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/models/_enums.py | Removes preview-only enum values and entire output-mode enum. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/models/init.py | Updates knowledgebases public exports (adds KnowledgeSourceSynchronizationError, removes SharePoint-related exports). |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/aio/_operations/_operations.py | Removes query-source auth kwarg; adds streaming raw/decompressed selection. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/aio/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/aio/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/_utils/model_base.py | Improves model equality and XML deserialization behavior. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/_operations/_operations.py | Removes query-source auth header support; adds streaming raw/decompressed selection. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/knowledgebases/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/models/_patch.py | Removes preview-only IndexerPermissionOption plumbing from patched models. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/models/_enums.py | Adds/removes enum members per GA API (e.g., entity/sentiment languages; removes SharePoint-related enums). |
| sdk/search/azure-search-documents/azure/search/documents/indexes/models/init.py | Updates public exports to align with removed/added models/enums. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/aio/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/aio/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/_utils/model_base.py | Mirrors model equality and XML deserialization updates. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/indexes/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/aio/_operations/_patch.py | Updates default API version and removes preview-only search kwargs passthroughs. |
| sdk/search/azure-search-documents/azure/search/documents/aio/_operations/_operations.py | Adds streaming raw/decompressed selection; removes preview-only query params. |
| sdk/search/azure-search-documents/azure/search/documents/aio/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/aio/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/_version.py | Bumps package version to 12.0.0. |
| sdk/search/azure-search-documents/azure/search/documents/_utils/model_base.py | Mirrors model equality and XML deserialization updates. |
| sdk/search/azure-search-documents/azure/search/documents/_operations/_patch.py | Updates default API version and removes preview-only search kwargs passthroughs. |
| sdk/search/azure-search-documents/azure/search/documents/_operations/_operations.py | Removes security header/query params from builders; adds streaming raw/decompressed selection. |
| sdk/search/azure-search-documents/azure/search/documents/_configuration.py | Updates endpoint docstring + default API version to 2026-04-01. |
| sdk/search/azure-search-documents/azure/search/documents/_client.py | Updates endpoint docstring + API version docs to 2026-04-01. |
| sdk/search/azure-search-documents/apiview-properties.json | Updates APIView name mappings for removed/added public types. |
| sdk/search/azure-search-documents/_metadata.json | Updates tracked service API version to 2026-04-01. |
| sdk/search/azure-search-documents/CHANGELOG.md | Adds GA 12.0.0 entry and enumerates added/removed API surface. |
Comments suppressed due to low confidence (5)
sdk/search/azure-search-documents/azure/search/documents/knowledgebases/_operations/_operations.py:210
decompressis popped from kwargs before callingpipeline.run, so the decode/decompression policy will never see a caller-provideddecompress=False. This can lead to inconsistent behavior (e.g., response may still be decompressed whileiter_raw()is returned). Prefer readingdecompresswithkwargs.get(...)(or passing it through) so the pipeline and the streaming iterator stay consistent.
_decompress = kwargs.pop("decompress", True)
_stream = kwargs.pop("stream", False)
pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access
_request, stream=_stream, **kwargs
)
sdk/search/azure-search-documents/azure/search/documents/knowledgebases/aio/_operations/_operations.py:178
decompressis popped from kwargs before callingpipeline.run, so a caller-provideddecompress=Falsewon't reach the pipeline decode/decompression policy. This can makeiter_raw()/iter_bytes()selection inconsistent with what actually happened in the pipeline. Preferkwargs.get("decompress", True)(without popping) or otherwise ensure the flag is passed through topipeline.run.
sdk/search/azure-search-documents/azure/search/documents/aio/_operations/_operations.py:92decompressis popped from kwargs before callingpipeline.run, which prevents a caller-provideddecompress=Falsefrom reaching the pipeline decode/decompression policy. This can result in returningiter_raw()even though the response was already decompressed (or vice versa). Prefer readingdecompresswithout removing it from kwargs, or pass it through explicitly topipeline.run.
_decompress = kwargs.pop("decompress", True)
_stream = kwargs.pop("stream", False)
pipeline_response: PipelineResponse = await self._client._pipeline.run( # type: ignore # pylint: disable=protected-access
_request, stream=_stream, **kwargs
)
sdk/search/azure-search-documents/azure/search/documents/_operations/_operations.py:480
decompressis popped from kwargs before callingpipeline.run, so a caller-provideddecompress=Falsewill never reach the pipeline decode/decompression policy. That can make the returned streaming iterator (iter_bytes()vsiter_raw()) inconsistent with how the pipeline handled the response. Preferkwargs.get("decompress", True)(no pop) and pass the flag through topipeline.run.
_decompress = kwargs.pop("decompress", True)
_stream = kwargs.pop("stream", False)
pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access
_request, stream=_stream, **kwargs
)
sdk/search/azure-search-documents/azure/search/documents/_operations/_operations.py:76
- The generated search request builders no longer accept/serialize the document-security headers (
x-ms-query-source-authorization,x-ms-enable-elevated-read). As a result, passing the existingx_ms_query_source_authorization/x_ms_enable_elevated_readkwargs (used in current tests and mentioned in earlier changelog entries) will have no effect on outgoing requests. If these headers are still supported in the GA API, please re-add plumbing via kwargs->headers or theheaderskwarg; otherwise, the docs/tests/changelog should be updated to reflect their removal.
def build_search_search_get_request( # pylint: disable=too-many-locals,too-many-statements,too-many-branches
index_name: str,
*,
search_text: Optional[str] = None,
include_total_result_count: Optional[bool] = None,
facets: Optional[list[str]] = None,
filter: Optional[str] = None,
|
|
||
| - Search query and result enhancements: | ||
| - Added `RescoringOptions` model for result rescoring support. | ||
| - Added `query_source_authorization` and `enable_elevated_read` keyword arguments to `SearchClient.search`. |
There was a problem hiding this comment.
CHANGELOG says "Added query_source_authorization and enable_elevated_read keyword arguments to SearchClient.search", but the generated request builders no longer serialize the corresponding x-ms headers and the public SearchClient.search customization doesn't expose these kwargs. Either re-introduce/plumb these parameters through to the REST headers (or document the correct supported kwargs), or remove this bullet to avoid misleading customers.
| - Added `query_source_authorization` and `enable_elevated_read` keyword arguments to `SearchClient.search`. |
| class FacetResult(_Model): | ||
| """A single bucket of a facet query result. Reports the number of documents with a field value | ||
| falling within a particular range or having a particular value or interval. | ||
|
|
||
| :ivar count: The approximate count of documents falling within the bucket described by this |
There was a problem hiding this comment.
Facet aggregation metric fields (avg, min, max, cardinality, etc.) were removed from FacetResult, but there are still existing tests (e.g., tests/async_tests/test_search_client_async.py) that set/assert these attributes. Update the remaining references/tests to align with the new GA model shape, otherwise the test suite will fail (or validate behavior that is no longer supported).
b2ab9d7 to
d691066
Compare
API Change CheckAPIView identified API level changes in this PR and created the following API reviews |
| # Release History | ||
|
|
||
| ## 11.7.0b3 (Unreleased) | ||
| ## 12.0.0 (2026-04-01) |
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2839d1a to
ce821c5
Compare
Do Not Merge
This is a GA release branch. It will be published directly from the branch and should not be merged into main. Main tracks the preview release path.
Major version bump for GA release. Regenerated SDK from TypeSpec spec commit 8be754a4. Removed preview-only types not promoted to GA. Updated CHANGELOG to follow established GA convention.
Description
Please add an informative description that covers that changes made by the pull request and link all relevant issues.
If an SDK is being regenerated based on a new API spec, a link to the pull request containing these API spec changes should be included above.
All SDK Contribution checklist:
General Guidelines and Best Practices
Testing Guidelines