Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package azure-cli-core for openSUSE:Factory checked in at 2024-03-11 15:35:01 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/azure-cli-core (Old) and /work/SRC/openSUSE:Factory/.azure-cli-core.new.1770 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "azure-cli-core" Mon Mar 11 15:35:01 2024 rev:64 rq:1156911 version:2.58.0 Changes: -------- --- /work/SRC/openSUSE:Factory/azure-cli-core/azure-cli-core.changes 2024-02-22 20:58:39.987493692 +0100 +++ /work/SRC/openSUSE:Factory/.azure-cli-core.new.1770/azure-cli-core.changes 2024-03-11 15:43:07.170721779 +0100 @@ -1,0 +2,8 @@ +Wed Mar 6 12:12:11 UTC 2024 - John Paul Adrian Glaubitz <adrian.glaub...@suse.com> + +- New upstream release + + Version 2.58.0 + + For detailed information about changes see the + HISTORY.rst file provided with this package + +------------------------------------------------------------------- Old: ---- azure-cli-core-2.57.0.tar.gz New: ---- azure-cli-core-2.58.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ azure-cli-core.spec ++++++ --- /var/tmp/diff_new_pack.95YUZZ/_old 2024-03-11 15:43:07.626738589 +0100 +++ /var/tmp/diff_new_pack.95YUZZ/_new 2024-03-11 15:43:07.626738589 +0100 @@ -17,7 +17,7 @@ Name: azure-cli-core -Version: 2.57.0 +Version: 2.58.0 Release: 0 Summary: Microsoft Azure CLI Core Module License: MIT ++++++ azure-cli-core-2.57.0.tar.gz -> azure-cli-core-2.58.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/HISTORY.rst new/azure-cli-core-2.58.0/HISTORY.rst --- old/azure-cli-core-2.57.0/HISTORY.rst 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/HISTORY.rst 2024-02-29 03:08:20.000000000 +0100 @@ -3,6 +3,10 @@ Release History =============== +2.58.0 +++++++ +* [BREAKING CHANGE] `az login`: Replace `allow_broker` with `enable_broker_on_windows` (#27726) + 2.57.0 ++++++ * `aaz`: Handle null value when deserialize output (#28253) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/PKG-INFO new/azure-cli-core-2.58.0/PKG-INFO --- old/azure-cli-core-2.57.0/PKG-INFO 2024-01-31 06:29:52.665539000 +0100 +++ new/azure-cli-core-2.58.0/PKG-INFO 2024-02-29 03:08:47.241322000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: azure-cli-core -Version: 2.57.0 +Version: 2.58.0 Summary: Microsoft Azure Command-Line Tools Core Module Home-page: https://github.com/Azure/azure-cli Author: Microsoft Corporation diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/__init__.py new/azure-cli-core-2.58.0/azure/cli/core/__init__.py --- old/azure-cli-core-2.57.0/azure/cli/core/__init__.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/__init__.py 2024-02-29 03:08:20.000000000 +0100 @@ -4,7 +4,7 @@ # -------------------------------------------------------------------------------------------- # pylint: disable=line-too-long -__version__ = "2.57.0" +__version__ = "2.58.0" import os import sys diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/_profile.py new/azure-cli-core-2.58.0/azure/cli/core/_profile.py --- old/azure-cli-core-2.57.0/azure/cli/core/_profile.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/_profile.py 2024-02-29 03:08:20.000000000 +0100 @@ -856,13 +856,14 @@ # EXPERIMENTAL: Use core.use_msal_http_cache=False to turn off MSAL HTTP cache. use_msal_http_cache = cli_ctx.config.getboolean('core', 'use_msal_http_cache', fallback=True) - # PREVIEW: On Windows, use core.allow_broker=true to use broker (WAM) for authentication. - allow_broker = cli_ctx.config.getboolean('core', 'allow_broker', fallback=False) + # PREVIEW: On Windows, use core.enable_broker_on_windows=true to use broker (WAM) for authentication. + enable_broker_on_windows = cli_ctx.config.getboolean('core', 'enable_broker_on_windows', fallback=False) from .telemetry import set_broker_info - set_broker_info(allow_broker=allow_broker) + set_broker_info(enable_broker_on_windows) # PREVIEW: In Azure Stack environment, use core.instance_discovery=false to disable MSAL's instance discovery. instance_discovery = cli_ctx.config.getboolean('core', 'instance_discovery', True) - return Identity(*args, encrypt=encrypt, use_msal_http_cache=use_msal_http_cache, allow_broker=allow_broker, + return Identity(*args, encrypt=encrypt, use_msal_http_cache=use_msal_http_cache, + enable_broker_on_windows=enable_broker_on_windows, instance_discovery=instance_discovery, **kwargs) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/aaz/_client.py new/azure-cli-core-2.58.0/azure/cli/core/aaz/_client.py --- old/azure-cli-core-2.57.0/azure/cli/core/aaz/_client.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/aaz/_client.py 2024-02-29 03:08:20.000000000 +0100 @@ -47,12 +47,12 @@ self, **kwargs ): - from azure.core.pipeline.policies import UserAgentPolicy, HeadersPolicy, ProxyPolicy, \ + from azure.core.pipeline.policies import HeadersPolicy, ProxyPolicy, \ RetryPolicy, CustomHookPolicy, RedirectPolicy, SansIOHTTPPolicy - from azure.cli.core.sdk.policies import SafeNetworkTraceLoggingPolicy + from azure.cli.core.sdk.policies import SafeNetworkTraceLoggingPolicy, RecordTelemetryUserAgentPolicy from ._http_policy import AAZBearerTokenCredentialPolicy - self.user_agent_policy = kwargs.get('user_agent_policy') or UserAgentPolicy(**kwargs) + self.user_agent_policy = kwargs.get('user_agent_policy') or RecordTelemetryUserAgentPolicy(**kwargs) self.headers_policy = kwargs.get('headers_policy') or HeadersPolicy(**kwargs) self.proxy_policy = kwargs.get('proxy_policy') or ProxyPolicy(**kwargs) self.logging_policy = kwargs.get('logging_policy') or SafeNetworkTraceLoggingPolicy(**kwargs) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/auth/identity.py new/azure-cli-core-2.58.0/azure/cli/core/auth/identity.py --- old/azure-cli-core-2.57.0/azure/cli/core/auth/identity.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/auth/identity.py 2024-02-29 03:08:20.000000000 +0100 @@ -54,7 +54,7 @@ _service_principal_store_instance = None def __init__(self, authority, tenant_id=None, client_id=None, encrypt=False, use_msal_http_cache=True, - allow_broker=None, instance_discovery=None): + enable_broker_on_windows=None, instance_discovery=None): """ :param authority: Authentication authority endpoint. For example, - AAD: https://login.microsoftonline.com @@ -69,7 +69,7 @@ self.client_id = client_id or AZURE_CLI_CLIENT_ID self._encrypt = encrypt self._use_msal_http_cache = use_msal_http_cache - self._allow_broker = allow_broker + self._enable_broker_on_windows = enable_broker_on_windows self._instance_discovery = instance_discovery # Build the authority in MSAL style @@ -107,8 +107,8 @@ @property def _msal_public_app_kwargs(self): """kwargs for creating PublicClientApplication.""" - # allow_broker can only be used on PublicClientApplication. - return {**self._msal_app_kwargs, "allow_broker": self._allow_broker} + # enable_broker_on_windows can only be used on PublicClientApplication. + return {**self._msal_app_kwargs, "enable_broker_on_windows": self._enable_broker_on_windows} @property def _msal_app(self): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/auth/landing_pages/success.html new/azure-cli-core-2.58.0/azure/cli/core/auth/landing_pages/success.html --- old/azure-cli-core-2.57.0/azure/cli/core/auth/landing_pages/success.html 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/auth/landing_pages/success.html 2024-02-29 03:08:20.000000000 +0100 @@ -25,7 +25,7 @@ <p>[Windows only] Azure CLI is collecting feedback on using the <a href="https://learn.microsoft.com/windows/uwp/security/web-account-manager">Web Account Manager</a> (WAM) broker for the login experience.</p> <p>You may opt-in to use WAM by running the following commands:</p> <code> - az config set core.allow_broker=true<br> + az config set core.enable_broker_on_windows=true<br> az account clear<br> az login </code> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/commands/__init__.py new/azure-cli-core-2.58.0/azure/cli/core/commands/__init__.py --- old/azure-cli-core-2.57.0/azure/cli/core/commands/__init__.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/commands/__init__.py 2024-02-29 03:08:20.000000000 +0100 @@ -675,6 +675,9 @@ event_data = {'result': results} self.cli_ctx.raise_event(EVENT_INVOKER_FILTER_RESULT, event_data=event_data) + if not self.data['output'] or self.data['output'] != 'none': + self._resolve_output_sensitive_data_warning(cmd, event_data['result']) + # save to local context if it is turned on after command executed successfully if self.cli_ctx.local_context.is_on and command and command in self.commands_loader.command_table and \ command in self.parser.subparser_map and self.parser.subparser_map[command].specified_arguments: @@ -711,7 +714,6 @@ result = list(result) result = todict(result, AzCliCommandInvoker.remove_additional_prop_layer) - self._resolve_output_sensitive_data_warning(cmd_copy, result) event_data = {'result': result} cmd_copy.cli_ctx.raise_event(EVENT_INVOKER_TRANSFORM_RESULT, event_data=event_data) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/commands/client_factory.py new/azure-cli-core-2.58.0/azure/cli/core/commands/client_factory.py --- old/azure-cli-core-2.57.0/azure/cli/core/commands/client_factory.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/commands/client_factory.py 2024-02-29 03:08:20.000000000 +0100 @@ -163,6 +163,9 @@ if 'x-ms-client-request-id' in cli_ctx.data['headers']: client_kwargs['request_id'] = cli_ctx.data['headers']['x-ms-client-request-id'] + from azure.cli.core.sdk.policies import RecordTelemetryUserAgentPolicy + client_kwargs['user_agent_policy'] = RecordTelemetryUserAgentPolicy(**client_kwargs) + # Replace NetworkTraceLoggingPolicy to redact 'Authorization' and 'x-ms-authorization-auxiliary' headers. # NetworkTraceLoggingPolicy: log raw network trace, with all headers. from azure.cli.core.sdk.policies import SafeNetworkTraceLoggingPolicy diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/profiles/_shared.py new/azure-cli-core-2.58.0/azure/cli/core/profiles/_shared.py --- old/azure-cli-core-2.57.0/azure/cli/core/profiles/_shared.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/profiles/_shared.py 2024-02-29 03:08:20.000000000 +0100 @@ -194,7 +194,7 @@ 'role_definitions': '2022-05-01-preview', 'provider_operations_metadata': '2018-01-01-preview' }), - ResourceType.MGMT_CONTAINERREGISTRY: SDKProfile('2022-02-01-preview', { + ResourceType.MGMT_CONTAINERREGISTRY: SDKProfile('2023-11-01-preview', { 'agent_pools': '2019-06-01-preview', 'tasks': '2019-06-01-preview', 'task_runs': '2019-06-01-preview', @@ -261,7 +261,7 @@ ResourceType.MGMT_ARO: '2023-09-04', ResourceType.MGMT_DATABOXEDGE: '2021-02-01-preview', ResourceType.MGMT_CUSTOMLOCATION: '2021-03-15-preview', - ResourceType.MGMT_CONTAINERSERVICE: SDKProfile('2023-11-01'), + ResourceType.MGMT_CONTAINERSERVICE: SDKProfile('2024-01-01'), ResourceType.MGMT_APPCONTAINERS: '2022-10-01', }, '2020-09-01-hybrid': { @@ -441,6 +441,7 @@ 'VERSION_2020_11_01_PREVIEW': "2020-11-01-preview", 'VERSION_2021_08_01_PREVIEW': "2021-08-01-preview", 'VERSION_2022_02_01_PREVIEW': "2022-02-01-preview", + 'VERSION_2023_11_01_PREVIEW': "2023-11-01-preview", }, ResourceType.MGMT_CONTAINERSERVICE: { # src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_custom.py:50 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/sdk/policies.py new/azure-cli-core-2.58.0/azure/cli/core/sdk/policies.py --- old/azure-cli-core-2.57.0/azure/cli/core/sdk/policies.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/sdk/policies.py 2024-02-29 03:08:20.000000000 +0100 @@ -7,7 +7,7 @@ import re import types -from azure.core.pipeline.policies import SansIOHTTPPolicy +from azure.core.pipeline.policies import SansIOHTTPPolicy, UserAgentPolicy from knack.log import get_logger _LOGGER = get_logger(__name__) @@ -96,3 +96,10 @@ _LOGGER.debug(response.http_response.text()) except Exception as err: # pylint: disable=broad-except _LOGGER.debug("Failed to log response: %s", repr(err)) + + +class RecordTelemetryUserAgentPolicy(UserAgentPolicy): + def on_request(self, request): + super().on_request(request) + from azure.cli.core.telemetry import set_user_agent + set_user_agent(request.http_request.headers[self._USERAGENT]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/telemetry.py new/azure-cli-core-2.58.0/azure/cli/core/telemetry.py --- old/azure-cli-core-2.57.0/azure/cli/core/telemetry.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/telemetry.py 2024-02-29 03:08:20.000000000 +0100 @@ -70,9 +70,10 @@ self.suppress_new_event = False self.poll_start_time = None self.poll_end_time = None - self.allow_broker = None + self.enable_broker_on_windows = None self.msal_telemetry = None self.secrets_detected = None + self.user_agent = None def add_event(self, name, properties): for key in self.instrumentation_key: @@ -152,6 +153,7 @@ 'Context.Default.VS.Core.Distro.Name': _get_distro_name(), # eg. 'CentOS Linux 8' 'Context.Default.VS.Core.Distro.Id': _get_distro_id(), # eg. 'centos' 'Context.Default.VS.Core.Distro.Version': _get_distro_version(), # eg. '8.4.2105' + 'Context.Dafault.VS.Core.Istty': str(sys.stdin.isatty()), 'Context.Default.VS.Core.User.Id': _get_installation_id(), 'Context.Default.VS.Core.User.IsMicrosoftInternal': 'False', 'Context.Default.VS.Core.User.IsOptedIn': 'True', @@ -182,6 +184,7 @@ set_custom_properties(result, 'ClientRequestId', lambda: self.application.data['headers'].get('x-ms-client-request-id', '')) + set_custom_properties(result, 'UserAgent', _get_user_agent()) set_custom_properties(result, 'CoreVersion', _get_core_version) set_custom_properties(result, 'TelemetryVersion', "2.0") set_custom_properties(result, 'InstallationId', _get_installation_id) @@ -218,10 +221,10 @@ set_custom_properties(result, 'ShowSurveyMessage', str(self.show_survey_message)) set_custom_properties(result, 'RegionInput', self.region_input) set_custom_properties(result, 'RegionIdentified', self.region_identified) - set_custom_properties(result, 'AllowBroker', str(self.allow_broker)) + set_custom_properties(result, 'EnableBrokerOnWindows', str(self.enable_broker_on_windows)) set_custom_properties(result, 'MsalTelemetry', self.msal_telemetry) set_custom_properties(result, 'SecretsWarning', _get_secrets_warning_config()) - set_custom_properties(result, 'SecretsDetected', self.secrets_detected) + set_custom_properties(result, 'SecretsDetected', str(self.secrets_detected)) return result @@ -459,9 +462,9 @@ @decorators.suppress_all_exceptions() -def set_broker_info(allow_broker): - # whether customer has configured `allow_broker` to enable WAM(Web Account Manager) login for authentication - _session.allow_broker = allow_broker +def set_broker_info(enable_broker_on_windows): + # Log the value of `enable_broker_on_windows` + _session.enable_broker_on_windows = enable_broker_on_windows @decorators.suppress_all_exceptions() @@ -471,6 +474,12 @@ @decorators.suppress_all_exceptions() +def set_user_agent(user_agent): + if user_agent: + _session.user_agent = user_agent + + +@decorators.suppress_all_exceptions() def set_secrets_detected(secrets_detected): _session.secrets_detected = secrets_detected @@ -529,10 +538,12 @@ @decorators.suppress_all_exceptions() def _get_secrets_warning_config(): - show_secrets_warning = _get_config().getboolean('clients', 'show_secrets_warning', fallback=None) - if show_secrets_warning is None: + from configparser import NoSectionError, NoOptionError + try: + show_secrets_warning = _get_config().getboolean('clients', 'show_secrets_warning') + return 'on' if show_secrets_warning else 'off' + except (NoSectionError, NoOptionError): return None - return 'on' if show_secrets_warning else 'off' # internal utility functions @@ -680,6 +691,17 @@ @decorators.suppress_all_exceptions(fallback_return='') +def _get_user_agent(): + if _session.user_agent: + return _session.user_agent + from azure.cli.core.util import get_az_user_agent + agents = [get_az_user_agent()] + if 'AZURE_HTTP_USER_AGENT' in os.environ: + agents.append(os.environ['AZURE_HTTP_USER_AGENT']) + return ' '.join(agents) + + +@decorators.suppress_all_exceptions(fallback_return='') @decorators.hash256_result def _get_error_hash(): return str(sys.exc_info()[1]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure/cli/core/util.py new/azure-cli-core-2.58.0/azure/cli/core/util.py --- old/azure-cli-core-2.57.0/azure/cli/core/util.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure/cli/core/util.py 2024-02-29 03:08:20.000000000 +0100 @@ -898,6 +898,9 @@ agents.append(headers['User-Agent']) headers['User-Agent'] = ' '.join(agents) + from azure.cli.core.telemetry import set_user_agent + set_user_agent(headers['User-Agent']) + if generated_client_request_id_name: headers[generated_client_request_id_name] = str(uuid.uuid4()) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/azure_cli_core.egg-info/PKG-INFO new/azure-cli-core-2.58.0/azure_cli_core.egg-info/PKG-INFO --- old/azure-cli-core-2.57.0/azure_cli_core.egg-info/PKG-INFO 2024-01-31 06:29:52.000000000 +0100 +++ new/azure-cli-core-2.58.0/azure_cli_core.egg-info/PKG-INFO 2024-02-29 03:08:47.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: azure-cli-core -Version: 2.57.0 +Version: 2.58.0 Summary: Microsoft Azure Command-Line Tools Core Module Home-page: https://github.com/Azure/azure-cli Author: Microsoft Corporation diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/azure-cli-core-2.57.0/setup.py new/azure-cli-core-2.58.0/setup.py --- old/azure-cli-core-2.57.0/setup.py 2024-01-31 06:29:21.000000000 +0100 +++ new/azure-cli-core-2.58.0/setup.py 2024-02-29 03:08:20.000000000 +0100 @@ -8,7 +8,7 @@ from codecs import open from setuptools import setup, find_packages -VERSION = "2.57.0" +VERSION = "2.58.0" # If we have source, validate that our version numbers match # This should prevent uploading releases with mismatched versions.