Skip to content

[AutoPR azure-mgmt-consumption]-generated-from-SDK Generation - Python-6707979 - #48597

Open
azure-sdk-automation[bot] wants to merge 4 commits into
mainfrom
sdkauto/azure-mgmt-consumption-6705668
Open

azure-sdk-automation[bot] wants to merge 4 commits into
mainfrom
sdkauto/azure-mgmt-consumption-6705668

Conversation

@azure-sdk-automation

@azure-sdk-automation azure-sdk-automation Bot commented Aug 14, 2026 •

Copy link
Copy Markdown
Contributor

Configurations: 'specification/consumption/resource-manager/Microsoft.Consumption/Consumption/tspconfig.yaml', SDK Release Type: stable, and CommitSHA: '069ddc2a68bac3f5e5f51a9e3c4636a5316cade3' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=6707979 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release. Release plan link: https://azsdk-releaseplan-dashboard-hveph5aqhhcfhtgu.westus-01.azurewebsites.net/?releaseplan=36087 Submitted by: mraveendar@microsoft.com

….Consumption/Consumption/tspconfig.yaml', SDK Release Type: stable, and CommitSHA: 'c724dc9c81b1ab37190c0f56b0354b2d63980710' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=6705668 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release.
Copilot AI balanced review requested due to automatic review settings August 14, 2026 21:55
@azure-sdk-automation azure-sdk-automation Bot added the auto-release When merged to main, release pipelines for this PR's changed packages trigger automatically. label Aug 14, 2026
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
9 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot could not run the full agentic suite for this review because it was automatically requested on a bot-authored pull request. Request a review from Copilot under Reviewers to retry with the full agentic suite. Improved support for bot-authored pull requests is coming soon.

Updates the azure-mgmt-consumption Python SDK generation to the 2026-06-01 Consumption RP API version, adding management-group scoped reservation recommendation support and refreshing generated artifacts.

Changes:

  • Bump default API version to 2026-06-01 across request builders, metadata, and samples.
  • Add support for ManagementGroup recommendation scope (new enum member/models + new management_group_id parameter on ReservationRecommendationDetailsOperations.get).
  • Introduce an API-version gating decorator (api_version_validation) and update generated API surface/docs/versioning.

Reviewed changes

Copilot reviewed 128 out of 128 changed files in this pull request and generated 16 comments.

Show a summary per file
File Description
sdk/consumption/azure-mgmt-consumption/tsp-location.yaml Updates source commit pointer for swagger/typespec input.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_for_billing_period_by_management_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_for_billing_period_by_enrollment_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_for_billing_period_by_department.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_for_billing_period_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_filter_by_tag.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_metric_usage.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_metric_amortized_cost.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_metric_actual_cost.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_mca_invoice_section.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_mca_customer.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_mca_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_mca_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_management_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_enrollment_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_department.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/usage_details_expand.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/tags.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_transactions_list_by_enrollment_number.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_transactions_list_by_billing_profile_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_monthly_with_reservation_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_monthly_with_billing_profile_id_reservation_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_monthly_with_billing_profile_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_monthly_with_billing_account_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_monthly.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_daily_with_reservation_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_daily_with_billing_profile_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_daily_with_billing_account_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_summaries_daily.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_filter_by_subscription_for_scope_look_back_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_subscription.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_resource_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_billing_account_for_management_group.py Adds new generated sample for management-group related reservation recommendations.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_billing_account_filter_by_scope.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendations_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_pre_purchase_plan_by_subscription.py Adds new generated sample for pre-purchase plan details.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_subscription.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_resource_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_account_for_management_group.py Adds new generated sample for management-group scoped recommendation details.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_details_with_reservation_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_details_by_billing_profile_id_reservation_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_details_by_billing_profile_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_details_by_billing_account_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_details.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/price_sheet_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/price_sheet_expand.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/price_sheet.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/operation_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_list_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_management_group_list_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_management_group_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_enrollment_accounts_list_by_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_enrollment_account_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_department_list_by_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_department_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_billing_account_list_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/marketplaces_by_billing_account_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_customer_with_filters.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_customer.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account_with_filters_primary.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account_with_filters_contributor.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account_with_filters.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account_primary.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account_contributor.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/lots_list_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_list_by_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account_with_filters_primary.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account_with_filters_contributor.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account_with_filters.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account_primary.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account_contributor.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/events_get_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/ea_price_sheet_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/delete_budget.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/credit_summary_by_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/create_or_update_budget.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_for_enrollment_account_filter_by_start_end_date.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_for_department_filter_by_start_end_date.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_invoice_section_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_customer.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_profile_invoice_section.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_profile_group_by_invoice_section_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_profile.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_account_group_by_invoice_section_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_account_group_by_customer_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_account_group_by_billing_profile_id.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_list_by_modern_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_for_billing_period_by_enrollment_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/charges_for_billing_period_by_department.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/budgets_list.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/budget.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/balances_by_billing_account_for_billing_period.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/balances_by_billing_account.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/aggregated_cost_for_billing_period_by_management_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/aggregated_cost_by_management_group_filter_by_date.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/generated_samples/aggregated_cost_by_management_group.py Updates x-ms-original-file reference to 2026-06-01.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/types.py Updates public TypedDict field names and docstrings to new naming.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/operations/_patch.py Removes stray whitespace in patch file.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/operations/_operations.py Bumps default API version; adds management_group_id + API version validation decorator; extends scope docs.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/models/_patch.py Removes stray whitespace in patch file.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/models/_models.py Adds management-group scoped models and projected-usage properties; updates flattened items and suppressions.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/models/_enums.py Adds Scope.MANAGEMENT_GROUP.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/models/init.py Exports newly added models.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/aio/operations/_patch.py Removes stray whitespace in patch file.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/aio/operations/_operations.py Adds async API version validation decorator and management_group_id parameter; updates suppressions.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/aio/_patch.py Removes stray whitespace in patch file.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/aio/_configuration.py Bumps default API version and updates config docstring + pylint disables.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/aio/_client.py Updates api_version docstring + pylint disables.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_version.py Bumps library version to 11.1.0.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_validation.py Adds API version gating decorator used on operations.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_utils/serialization.py Expands serializer docstring to document constructor params.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_utils/model_base.py Enhances JSON encoder docs; adds bool-from-string deserializer support.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_patch.py Removes stray whitespace in patch file.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_configuration.py Bumps default API version and updates config docstring + pylint disables.
sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_client.py Updates api_version docstring + pylint disables.
sdk/consumption/azure-mgmt-consumption/apiview-properties.json Updates APIView mappings and cross-language version hash for new surface area.
sdk/consumption/azure-mgmt-consumption/api.metadata.yml Updates parser version and content hash for API MD.
sdk/consumption/azure-mgmt-consumption/api.md Updates API surface doc for new models/params and renamed TypedDict keys.
sdk/consumption/azure-mgmt-consumption/_metadata.json Updates tracked API version/commit and emitter/http client versions.
sdk/consumption/azure-mgmt-consumption/CHANGELOG.md Adds release notes for 11.1.0 describing new features.
Suppressed comments (1)

sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_account_for_management_group.py:1

  • This new sample calls reservation_recommendation_details.get with scope=\"ManagementGroup\" but does not pass management_group_id. The operation docstring states this value is required for ManagementGroup scope, so the sample is likely to fail at runtime. Add management_group_id=\"<management-group-id>\" (or the appropriate placeholder) to the call.

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings August 17, 2026 02:44
@ChenxiJiang333 Chenxi Jiang (ChenxiJiang333) added the mgmt-review-needed PR for Mgmt SDK is ready to review label Aug 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 128 out of 128 changed files in this pull request and generated no new comments.

@github-actions

This comment has been minimized.

….Consumption/Consumption/tspconfig.yaml', SDK Release Type: stable, and CommitSHA: '069ddc2a68bac3f5e5f51a9e3c4636a5316cade3' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=6707979 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release.
Copilot AI review requested due to automatic review settings August 17, 2026 03:15
@azure-sdk-automation azure-sdk-automation Bot changed the title [AutoPR azure-mgmt-consumption]-generated-from-SDK Generation - Python-6705668 [AutoPR azure-mgmt-consumption]-generated-from-SDK Generation - Python-6707979 Aug 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 128 out of 128 changed files in this pull request and generated 2 comments.

Suppressed comments (3)

sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_account_for_management_group.py:1

  • This sample sets scope=\"ManagementGroup\" but does not pass management_group_id, even though the generated operation docstring indicates it is required for management-group scope. Update the sample call to include management_group_id (and use a realistic management group ID value) so the sample can run successfully.
    sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_validation.py:62
  • The API-version gating logic can produce incorrect rejections in two concrete cases: (1) if client_api_version isn't present in api_versions_list (e.g., a newer service date string), _index_with_default returns -1 and the wrapper treats it as older than everything; and (2) parameters are treated as 'used' solely by presence in kwargs, so callers passing management_group_id=None explicitly can be rejected even though it won't be sent. Consider (a) comparing API versions by parsing the YYYY-MM-DD strings (or falling back to string/date comparison) when list lookup fails, and (b) only flagging a parameter when kwargs.get(parameter) is not None.
    def _index_with_default(value: str, default: int = -1) -> int:
        """Get the index of value in lst, or return default if not found.

        :param value: The value to search for in the api_versions_list.
        :type value: str
        :param default: The default value to return if the value is not found.
        :type default: int
        :return: The index of the value in the list, or the default value if not found.
        :rtype: int
        """
        try:
            return api_versions_list.index(value)
        except ValueError:
            return default

    def decorator(func):
        @functools.wraps(func)
        def wrapper(*args, **kwargs):
            try:
                # this assumes the client has an _api_version attribute
                client = args[0]
                client_api_version = client._config.api_version  # pylint: disable=protected-access
            except AttributeError:
                return func(*args, **kwargs)

            if _index_with_default(method_added_on) > _index_with_default(client_api_version):
                raise ValueError(
                    f"'{func.__name__}' is not available in API version "
                    f"{client_api_version}. Pass service API version {method_added_on} or newer to your client."
                )

            unsupported = {
                parameter: api_version
                for api_version, parameters in params_added_on.items()
                for parameter in parameters
                if parameter in kwargs and _index_with_default(api_version) > _index_with_default(client_api_version)
            }
            if unsupported:
                raise ValueError(
                    "".join(
                        [
                            f"'{param}' is not available in API version {client_api_version}. "
                            f"Use service API version {version} or newer.\n"
                            for param, version in unsupported.items()
                        ]
                    )
                )
            return func(*args, **kwargs)

sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_utils/model_base.py:356

  • _deserialize_bool_as_str assumes attr is a string when it's not already a bool. If attr is None or any non-string type, this will raise at runtime. Make this deserializer tolerant by checking isinstance(attr, str) (and handling None by returning None), and consider normalizing whitespace/casing safely.
def _deserialize_bool_as_str(attr):
    if isinstance(attr, bool):
        return attr
    return attr.lower() == "true"

Copilot AI review requested due to automatic review settings August 17, 2026 03:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 128 out of 128 changed files in this pull request and generated 3 comments.

Suppressed comments (3)

sdk/consumption/azure-mgmt-consumption/generated_samples/reservation_recommendation_details_by_billing_account_for_management_group.py:1

  • This sample calls reservation_recommendation_details.get with scope=\"ManagementGroup\" but does not pass management_group_id, which the method docstring indicates is required for ManagementGroup scope. The sample should include the management_group_id argument so it can run successfully against the service.
    sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_validation.py:50
  • The validator treats a parameter as 'used' if it exists in kwargs, even when the caller explicitly passes None (or passes through a defaulted variable). This can raise a ValueError for an API-version-gated parameter even though it is effectively not set. Consider checking both parameter in kwargs and kwargs.get(parameter) is not None (or an equivalent sentinel-based check) before flagging it as unsupported.
            unsupported = {
                parameter: api_version
                for api_version, parameters in params_added_on.items()
                for parameter in parameters
                if parameter in kwargs and _index_with_default(api_version) > _index_with_default(client_api_version)
            }

sdk/consumption/azure-mgmt-consumption/azure/mgmt/consumption/_utils/model_base.py:356

  • _deserialize_bool_as_str will raise an AttributeError if attr is neither bool nor str (e.g., an int, None, etc.). Since this is a generic deserializer path, it should defensively handle non-string inputs (e.g., isinstance(attr, str) before calling .lower()) and either return attr unchanged, coerce known alternative representations, or raise a clearer ValueError.
def _deserialize_bool_as_str(attr):
    if isinstance(attr, bool):
        return attr
    return attr.lower() == "true"

@github-actions

Copy link
Copy Markdown
Contributor
[Pilot] PR Pipeline Failure Analysis

A CI pipeline failed on this pull request. Here is an automated analysis of what went wrong and how to get the build green.

What failed

The python - pullrequest pipeline (Build #6707986) failed on the Build_Windows job due to two infrastructure-related issues:

  1. Azure DevOps service unavailability: The pre-job 1ES Pipeline Templates step failed with TF10216: Azure DevOps services are currently unavailable when trying to download build tools configuration. This is a transient service-side failure.
  2. Missing script: A PowerShell task failed because ./eng/scripts/resolve-package-info.ps1 was not found (CommandNotFoundException). This may be related to the above infra failure (the checkout/setup may not have completed properly), or the script genuinely does not exist in the branch.

Both failures appear to be infrastructure in nature (service outage + agent setup failure), not caused by code changes in this PR.

Recommended next steps

  • Re-run the failing pipeline — the Azure DevOps service unavailability is transient and a retry is likely to succeed.
  • If re-running still fails with the missing script error, verify that eng/scripts/resolve-package-info.ps1 exists in the repository (it may have been removed or renamed).
  • See the CI troubleshooting guide: https://aka.ms/ci-fix
  • Push new commits to address the failures; this comment updates automatically on the next failing run.
Raw pipeline analysis (azsdk ci analyze)
Analyzing pipeline https://github.com/Azure/azure-sdk-for-python/pull/48597...
Getting failed workflow runs for commit ecd7228da00221e933f2400598372d5672e0f4cf in Azure/azure-sdk-for-python
Build: 6707986 Project: public PipelineUrl: https://dev.azure.com/azure-sdk/public/_build/results?buildId=6707986

Failed Tasks:
--> PowerShell task error:
./eng/scripts/resolve-package-info.ps1 : The term './eng/scripts/resolve-package-info.ps1' is not recognized
as a name of a cmdlet, function, script file, or executable program.
##[error]PowerShell exited with code '1'.

--> 1ES Pre-Job step error:
##[error][03:19:34.12] Failed to download configuration: TF10216: Azure DevOps services are currently
unavailable. Try again later. Activity Id: 8a750610-6f5b-4773-8f5d-6f734a5d81dd
[03:19:34.139] Installer failed with exit code 1
##[error]Python implementation failed with exit code 1

Failing checks:
  python - pullrequest [FAILURE]
    https://dev.azure.com/azure-sdk/29ec6040-b234-4e31-b139-33dc4287b756/_build/results?buildId=6707986
  python - pullrequest (Build Build_Windows) [FAILURE]
    https://dev.azure.com/azure-sdk/29ec6040-b234-4e31-b139-33dc4287b756/_build/results?buildId=6707986&view=logs&jobId=bb7c3b4b-500f-5219-8e75-c2214b322bc5

Copilot detected the failing pipeline and generated the analysis above. To have it attempt a fix automatically, reply with @copilot please fix the failing pipeline on this PR.

Generated by Pipeline Analysis - Next Steps · 23 AIC · ⌖ 6.21 AIC · ⊞ 6.6K · ◷

Copilot AI review requested due to automatic review settings August 17, 2026 04:49
@ChenxiJiang333 Chenxi Jiang (ChenxiJiang333) added mgmt-review-needed PR for Mgmt SDK is ready to review and removed mgmt-review-needed PR for Mgmt SDK is ready to review labels Aug 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 128 out of 128 changed files in this pull request and generated no new comments.

@ChenxiJiang333 Chenxi Jiang (ChenxiJiang333) added mgmt-review-needed PR for Mgmt SDK is ready to review and removed mgmt-review-needed PR for Mgmt SDK is ready to review labels Aug 17, 2026
@ChenxiJiang333

Chenxi Jiang (ChenxiJiang333) commented Aug 18, 2026 •

Copy link
Copy Markdown
Member

Hi Madhumitha Raveendar (@madhuravee27), we have approved the PR. You can move on to merge and release though the action suggestion in Release Plan.

@ChenxiJiang333 Chenxi Jiang (ChenxiJiang333) removed the mgmt-review-needed PR for Mgmt SDK is ready to review label Aug 18, 2026
@ChenxiJiang333 Chenxi Jiang (ChenxiJiang333) added the mgmt-review-needed PR for Mgmt SDK is ready to review label Aug 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Management SDK PR review

Findings: None.

Unverified checks

Unverified checks: None.

Review summary

Reviewed package sdk/consumption/azure-mgmt-consumption (PR #48597, revision d7c2103b429d6d23b486ab2b846abe6048585272 → 50e616e33e7ae893c9e818a6ee6d1c8ddd308ad9). Checks completed:

  • API version consistency: _metadata.json apiVersion 2026-06-01 unchanged between first and latest revision.
  • Version consistency: _version.py (11.1.0) matches latest CHANGELOG.md entry (## 11.1.0 (2026-08-17)).
  • Preview/stable alignment: version has no b suffix and apiVersion is not preview; pyproject.toml has is_stable = true and classifier Development Status :: 5 - Production/Stable.
  • Changelog date: 2026-08-17 is not more than 3 weeks in the future.
  • Client signature in _client.py: __init__(self, credential, subscription_id, base_url=None, ...) — correct order; subscription_id present (no no_sub flag needed).
  • Client name consistency: ConsumptionManagementClient matches across _client.py, README.md, and pyproject.toml title.
  • README code snippets: usage sample matches the actual client constructor signature.

No other files under azure/mgmt/consumption/** (other than _client.py) or generated_samples//generated_tests/ were reviewed, per scope exclusions.

@github-actions

Copy link
Copy Markdown
Contributor

Hi @azure-sdk-automation[bot]. Thank you for your interest in helping to improve the Azure SDK experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment. Otherwise, we'll close this out in 7 days.

@github-actions github-actions Bot added the no-recent-activity There has been no recent activity on this issue. label Oct 23, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-release When merged to main, release pipelines for this PR's changed packages trigger automatically. mgmt-review-needed PR for Mgmt SDK is ready to review no-recent-activity There has been no recent activity on this issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants