Skip to content

Commit 11437bb

Browse files
authored
update to use latest swagger (Azure#32252)
* update to use latest swagger * update * Update changelog * run black
1 parent 973d6e5 commit 11437bb

File tree

68 files changed

+1369
-617
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+1369
-617
lines changed

sdk/search/azure-search-documents/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@
66

77
### Breaking Changes
88

9+
> These changes do not impact the API of stable versions such as 11.3.0.
10+
> Only code written against a beta version such as 11.4.0b6 may be affected.
11+
- Renamed `vector_search_configuration` to `vector_search_profile` in `SearchField`.
12+
913
### Bugs Fixed
1014

1115
### Other Changes

sdk/search/azure-search-documents/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ endpoint = os.environ["SEARCH_ENDPOINT"]
310310
key = os.environ["SEARCH_API_KEY"]
311311
credential = DefaultAzureCredential(authority=AzureAuthorityHosts.AZURE_CHINA)
312312

313-
search_client = SearchClient(endpoint, index_name, crdential=credential, audience="https://search.azure.cn")
313+
search_client = SearchClient(endpoint, index_name, credential=credential, audience="https://search.azure.cn")
314314
```
315315

316316
### Retrieving a specific document from your index

sdk/search/azure-search-documents/azure/search/documents/_generated/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

sdk/search/azure-search-documents/azure/search/documents/_generated/_configuration.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

@@ -12,7 +12,7 @@
1212
VERSION = "unknown"
1313

1414

15-
class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many-instance-attributes
15+
class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many-instance-attributes,name-too-long
1616
"""Configuration for SearchIndexClient.
1717
1818
Note that all parameters used to create this instance are saved as instance
@@ -22,14 +22,14 @@ class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many
2222
:type endpoint: str
2323
:param index_name: The name of the index. Required.
2424
:type index_name: str
25-
:keyword api_version: Api Version. Default value is "2023-07-01-Preview". Note that overriding
25+
:keyword api_version: Api Version. Default value is "2023-10-01-Preview". Note that overriding
2626
this default value may result in unsupported behavior.
2727
:paramtype api_version: str
2828
"""
2929

3030
def __init__(self, endpoint: str, index_name: str, **kwargs: Any) -> None:
3131
super(SearchIndexClientConfiguration, self).__init__(**kwargs)
32-
api_version: str = kwargs.pop("api_version", "2023-07-01-Preview")
32+
api_version: str = kwargs.pop("api_version", "2023-10-01-Preview")
3333

3434
if endpoint is None:
3535
raise ValueError("Parameter 'endpoint' must not be None.")

sdk/search/azure-search-documents/azure/search/documents/_generated/_search_index_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

@@ -25,7 +25,7 @@ class SearchIndexClient: # pylint: disable=client-accepts-api-version-keyword
2525
:type endpoint: str
2626
:param index_name: The name of the index. Required.
2727
:type index_name: str
28-
:keyword api_version: Api Version. Default value is "2023-07-01-Preview". Note that overriding
28+
:keyword api_version: Api Version. Default value is "2023-10-01-Preview". Note that overriding
2929
this default value may result in unsupported behavior.
3030
:paramtype api_version: str
3131
"""

sdk/search/azure-search-documents/azure/search/documents/_generated/_serialization.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -730,6 +730,8 @@ def url(self, name, data, data_type, **kwargs):
730730

731731
if kwargs.get("skip_quote") is True:
732732
output = str(output)
733+
# https://github.com/Azure/autorest.python/issues/2063
734+
output = output.replace("{", quote("{")).replace("}", quote("}"))
733735
else:
734736
output = quote(str(output), safe="")
735737
except SerializationError:
@@ -1910,7 +1912,7 @@ def deserialize_date(attr):
19101912
if re.search(r"[^\W\d_]", attr, re.I + re.U): # type: ignore
19111913
raise DeserializationError("Date must have only digits and -. Received: %s" % attr)
19121914
# This must NOT use defaultmonth/defaultday. Using None ensure this raises an exception.
1913-
return isodate.parse_date(attr, defaultmonth=None, defaultday=None)
1915+
return isodate.parse_date(attr, defaultmonth=0, defaultday=0)
19141916

19151917
@staticmethod
19161918
def deserialize_time(attr):

sdk/search/azure-search-documents/azure/search/documents/_generated/_vendor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# --------------------------------------------------------------------------
2-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
2+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
33
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
44
# --------------------------------------------------------------------------
55

sdk/search/azure-search-documents/azure/search/documents/_generated/aio/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

sdk/search/azure-search-documents/azure/search/documents/_generated/aio/_configuration.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

@@ -12,7 +12,7 @@
1212
VERSION = "unknown"
1313

1414

15-
class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many-instance-attributes
15+
class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many-instance-attributes,name-too-long
1616
"""Configuration for SearchIndexClient.
1717
1818
Note that all parameters used to create this instance are saved as instance
@@ -22,14 +22,14 @@ class SearchIndexClientConfiguration(Configuration): # pylint: disable=too-many
2222
:type endpoint: str
2323
:param index_name: The name of the index. Required.
2424
:type index_name: str
25-
:keyword api_version: Api Version. Default value is "2023-07-01-Preview". Note that overriding
25+
:keyword api_version: Api Version. Default value is "2023-10-01-Preview". Note that overriding
2626
this default value may result in unsupported behavior.
2727
:paramtype api_version: str
2828
"""
2929

3030
def __init__(self, endpoint: str, index_name: str, **kwargs: Any) -> None:
3131
super(SearchIndexClientConfiguration, self).__init__(**kwargs)
32-
api_version: str = kwargs.pop("api_version", "2023-07-01-Preview")
32+
api_version: str = kwargs.pop("api_version", "2023-10-01-Preview")
3333

3434
if endpoint is None:
3535
raise ValueError("Parameter 'endpoint' must not be None.")

sdk/search/azure-search-documents/azure/search/documents/_generated/aio/_search_index_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
3-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].1)
3+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.9.7, generator: @autorest/[email protected].8)
44
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
55
# --------------------------------------------------------------------------
66

@@ -25,7 +25,7 @@ class SearchIndexClient: # pylint: disable=client-accepts-api-version-keyword
2525
:type endpoint: str
2626
:param index_name: The name of the index. Required.
2727
:type index_name: str
28-
:keyword api_version: Api Version. Default value is "2023-07-01-Preview". Note that overriding
28+
:keyword api_version: Api Version. Default value is "2023-10-01-Preview". Note that overriding
2929
this default value may result in unsupported behavior.
3030
:paramtype api_version: str
3131
"""

0 commit comments

Comments
 (0)