From 985ade4b59dc9b9e788fe3738447b751ab805e7e Mon Sep 17 00:00:00 2001 From: Krista Pratico Date: Wed, 22 Jun 2022 13:57:05 -0700 Subject: [PATCH 1/2] remove maxpagesize through regeneration --- .../authoring/_operations/_operations.py | 135 ++---------------- .../authoring/aio/_operations/_operations.py | 76 +--------- 2 files changed, 18 insertions(+), 193 deletions(-) diff --git a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py index fd3ae0412989..925977a1dc27 100644 --- a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py +++ b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py @@ -40,9 +40,7 @@ _SERIALIZER.client_side_validation = False -def build_list_projects_request( - *, top: Optional[int] = None, skip: Optional[int] = None, maxpagesize: Optional[int] = None, **kwargs: Any -) -> HttpRequest: +def build_list_projects_request(*, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -57,8 +55,6 @@ def build_list_projects_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -236,12 +232,7 @@ def build_train_request(project_name: str, **kwargs: Any) -> HttpRequest: def build_list_deployments_request( - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -262,8 +253,6 @@ def build_list_deployments_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -481,12 +470,7 @@ def build_get_import_project_job_status_request(project_name: str, job_id: str, def build_list_trained_models_request( - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -507,8 +491,6 @@ def build_list_trained_models_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -574,7 +556,6 @@ def build_list_model_evaluation_results_request( string_index_type: str, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) @@ -598,8 +579,6 @@ def build_list_model_evaluation_results_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -638,12 +617,7 @@ def build_get_model_evaluation_summary_request( def build_list_training_jobs_request( - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -664,8 +638,6 @@ def build_list_training_jobs_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -749,12 +721,7 @@ def build_get_project_deletion_job_status_request(job_id: str, **kwargs: Any) -> def build_list_supported_languages_request( - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -771,8 +738,6 @@ def build_list_supported_languages_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -787,7 +752,6 @@ def build_list_supported_prebuilt_entities_request( multilingual: Optional[bool] = None, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) @@ -808,8 +772,6 @@ def build_list_supported_prebuilt_entities_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -819,12 +781,7 @@ def build_list_supported_prebuilt_entities_request( def build_list_training_config_versions_request( - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -841,8 +798,6 @@ def build_list_training_config_versions_request( _params["top"] = _SERIALIZER.query("top", top, "int") if skip is not None: _params["skip"] = _SERIALIZER.query("skip", skip, "int") - if maxpagesize is not None: - _params["maxpagesize"] = _SERIALIZER.query("maxpagesize", maxpagesize, "int") _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") # Construct headers @@ -853,9 +808,7 @@ def build_list_training_config_versions_request( class ConversationAuthoringClientOperationsMixin(MixinABC): # pylint: disable=too-many-public-methods @distributed_trace - def list_projects( - self, *, top: Optional[int] = None, skip: Optional[int] = None, maxpagesize: Optional[int] = None, **kwargs: Any - ) -> Iterable[JSON]: + def list_projects(self, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any) -> Iterable[JSON]: """Lists the existing projects. :keyword top: The maximum number of resources to return from the collection. Default value is @@ -864,9 +817,6 @@ def list_projects( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -914,7 +864,6 @@ def prepare_request(next_link=None): request = build_list_projects_request( top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -2524,13 +2473,7 @@ def get_long_running_output(pipeline_response): @distributed_trace def list_deployments( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the deployments belonging to a project. @@ -2542,9 +2485,6 @@ def list_deployments( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -2581,7 +2521,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -3949,13 +3888,7 @@ def get_import_project_job_status(self, project_name: str, job_id: str, **kwargs @distributed_trace def list_trained_models( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the trained models belonging to a project. @@ -3967,9 +3900,6 @@ def list_trained_models( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4005,7 +3935,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -4175,7 +4104,6 @@ def list_model_evaluation_results( string_index_type: str, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Gets the detailed results of the evaluation for a trained model. This includes the raw @@ -4194,9 +4122,6 @@ def list_model_evaluation_results( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4257,7 +4182,6 @@ def prepare_request(next_link=None): string_index_type=string_index_type, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -4448,13 +4372,7 @@ def get_model_evaluation_summary(self, project_name: str, trained_model_label: s @distributed_trace def list_training_jobs( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the non-expired training jobs created for a project. @@ -4466,9 +4384,6 @@ def list_training_jobs( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4579,7 +4494,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -5085,13 +4999,7 @@ def get_project_deletion_job_status(self, job_id: str, **kwargs: Any) -> JSON: @distributed_trace def list_supported_languages( - self, - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the supported languages for the given project type. @@ -5104,9 +5012,6 @@ def list_supported_languages( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -5137,7 +5042,6 @@ def prepare_request(next_link=None): project_kind=project_kind, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -5191,7 +5095,6 @@ def list_supported_prebuilt_entities( multilingual: Optional[bool] = None, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the supported prebuilt entities that can be used while creating composed entities. @@ -5209,9 +5112,6 @@ def list_supported_prebuilt_entities( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -5242,7 +5142,6 @@ def prepare_request(next_link=None): multilingual=multilingual, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -5290,13 +5189,7 @@ def get_next(next_link=None): @distributed_trace def list_training_config_versions( - self, - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> Iterable[JSON]: """Lists the support training config version for a given project type. @@ -5309,9 +5202,6 @@ def list_training_config_versions( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.paging.ItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -5342,7 +5232,6 @@ def prepare_request(next_link=None): project_kind=project_kind, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, diff --git a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py index 349e501601f3..1d67becdc53d 100644 --- a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py +++ b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py @@ -70,7 +70,7 @@ class ConversationAuthoringClientOperationsMixin(MixinABC): # pylint: disable=too-many-public-methods @distributed_trace def list_projects( - self, *, top: Optional[int] = None, skip: Optional[int] = None, maxpagesize: Optional[int] = None, **kwargs: Any + self, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the existing projects. @@ -80,9 +80,6 @@ def list_projects( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -130,7 +127,6 @@ def prepare_request(next_link=None): request = build_list_projects_request( top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -1746,13 +1742,7 @@ def get_long_running_output(pipeline_response): @distributed_trace def list_deployments( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the deployments belonging to a project. @@ -1764,9 +1754,6 @@ def list_deployments( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -1803,7 +1790,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -3182,13 +3168,7 @@ async def get_import_project_job_status(self, project_name: str, job_id: str, ** @distributed_trace def list_trained_models( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the trained models belonging to a project. @@ -3200,9 +3180,6 @@ def list_trained_models( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -3238,7 +3215,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -3408,7 +3384,6 @@ def list_model_evaluation_results( string_index_type: str, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Gets the detailed results of the evaluation for a trained model. This includes the raw @@ -3427,9 +3402,6 @@ def list_model_evaluation_results( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -3490,7 +3462,6 @@ def prepare_request(next_link=None): string_index_type=string_index_type, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -3681,13 +3652,7 @@ async def get_model_evaluation_summary(self, project_name: str, trained_model_la @distributed_trace def list_training_jobs( - self, - project_name: str, - *, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, project_name: str, *, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the non-expired training jobs created for a project. @@ -3699,9 +3664,6 @@ def list_training_jobs( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -3812,7 +3774,6 @@ def prepare_request(next_link=None): project_name=project_name, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -4319,13 +4280,7 @@ async def get_project_deletion_job_status(self, job_id: str, **kwargs: Any) -> J @distributed_trace def list_supported_languages( - self, - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the supported languages for the given project type. @@ -4338,9 +4293,6 @@ def list_supported_languages( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4371,7 +4323,6 @@ def prepare_request(next_link=None): project_kind=project_kind, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -4425,7 +4376,6 @@ def list_supported_prebuilt_entities( multilingual: Optional[bool] = None, top: Optional[int] = None, skip: Optional[int] = None, - maxpagesize: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the supported prebuilt entities that can be used while creating composed entities. @@ -4443,9 +4393,6 @@ def list_supported_prebuilt_entities( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4476,7 +4423,6 @@ def prepare_request(next_link=None): multilingual=multilingual, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, @@ -4524,13 +4470,7 @@ async def get_next(next_link=None): @distributed_trace def list_training_config_versions( - self, - *, - project_kind: str, - top: Optional[int] = None, - skip: Optional[int] = None, - maxpagesize: Optional[int] = None, - **kwargs: Any + self, *, project_kind: str, top: Optional[int] = None, skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable[JSON]: """Lists the support training config version for a given project type. @@ -4543,9 +4483,6 @@ def list_training_config_versions( :keyword skip: An offset into the collection of the first resource to be returned. Default value is None. :paramtype skip: int - :keyword maxpagesize: The maximum number of resources to include in a single response. Default - value is None. - :paramtype maxpagesize: int :return: An iterator like instance of JSON object :rtype: ~azure.core.async_paging.AsyncItemPaged[JSON] :raises ~azure.core.exceptions.HttpResponseError: @@ -4576,7 +4513,6 @@ def prepare_request(next_link=None): project_kind=project_kind, top=top, skip=skip, - maxpagesize=maxpagesize, api_version=self._config.api_version, headers=_headers, params=_params, From dbdfff4b5c98caab02f16885db67bbda34671bd5 Mon Sep 17 00:00:00 2001 From: Krista Pratico Date: Wed, 22 Jun 2022 14:15:17 -0700 Subject: [PATCH 2/2] regen with latest DPG again --- .../authoring/_operations/_operations.py | 49 ++++++++++++++++--- .../authoring/aio/_operations/_operations.py | 49 ++++++++++++++++--- 2 files changed, 82 insertions(+), 16 deletions(-) diff --git a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py index 925977a1dc27..4f96bb04ebef 100644 --- a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py +++ b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/_operations/_operations.py @@ -8,6 +8,7 @@ # -------------------------------------------------------------------------- import sys from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, cast, overload +from urllib.parse import parse_qs, urljoin, urlparse from azure.core.exceptions import ( ClientAuthenticationError, @@ -876,7 +877,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -2533,7 +2538,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -3947,7 +3956,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -4194,7 +4207,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -4506,7 +4523,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -5054,7 +5075,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -5154,7 +5179,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -5244,7 +5273,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True diff --git a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py index 1d67becdc53d..e023ff47ad92 100644 --- a/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py +++ b/sdk/cognitivelanguage/azure-ai-language-conversations/azure/ai/language/conversations/authoring/aio/_operations/_operations.py @@ -8,6 +8,7 @@ # -------------------------------------------------------------------------- import sys from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, cast, overload +from urllib.parse import parse_qs, urljoin, urlparse from azure.core.async_paging import AsyncItemPaged, AsyncList from azure.core.exceptions import ( @@ -139,7 +140,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -1802,7 +1807,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -3227,7 +3236,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -3474,7 +3487,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -3786,7 +3803,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -4335,7 +4356,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -4435,7 +4460,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True @@ -4525,7 +4554,11 @@ def prepare_request(next_link=None): request.url = self._client.format_url(request.url, **path_format_arguments) # type: ignore else: - request = HttpRequest("GET", next_link) + # make call to next link with the client's api-version + _parsed_next_link = urlparse(next_link) + _next_request_params = case_insensitive_dict(parse_qs(_parsed_next_link.query)) + _next_request_params["api-version"] = self._config.api_version + request = HttpRequest("GET", urljoin(next_link, _parsed_next_link.path), params=_next_request_params) path_format_arguments = { "Endpoint": self._serialize.url( "self._config.endpoint", self._config.endpoint, "str", skip_quote=True