tags 1070672 + patch kthxbye On 2024-05-06 at 21:59:34, brian m. carlson wrote: > azure-cli prompts the user for surveys in at least some circumstances > when running `az login`. This is done using a bright blue, three-line > banner that is large and distracting, and totally unnecessary. > > The Unix philosophy is that software should be silent unless it has > something relevant to say to the user. Survey requests benefit > Microsoft, but are not actually relevant to the user, and if the user > wanted to provide feedback, it would be just as easy to find the > appropriate website to do so. In addition, terminal users do not expect > software in Debian to print lots of noisy messages to the terminal, and > in general, when software does so, it's considered a bug. > > Please disable the survey requests in Debian to keep azure-cli quiet.
I've included a Git format patch as an attachment. This is not against the Debian repository since salsa.debian.org was down at the time I was looking at this, but it's against a `git init` of the latest package. It should be pretty straightforward and easy to read. -- brian m. carlson (they/them or he/him) Toronto, Ontario, CA
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: "brian m. carlson" <sand...@crustytoothpaste.net> Date: Tue, 7 May 2024 00:58:28 +0000 Subject: [PATCH] Don't prompt user for surveys The survey message that is used is three lines and has a bright blue background and is very distracting compared to other text on the screen. In addition, the Unix philosophy states that software should avoid unnecessary output, and upstream's desire for users to complete a survey is not functionally necessary or useful for end users. Remove this prompt since it is noisy and annoying to terminal users. Users wanting to access the survey can still run `az survey` if they want. --- src/azure-cli/azure/cli/__main__.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/azure-cli/azure/cli/__main__.py b/src/azure-cli/azure/cli/__main__.py index 513e914..1b983d1 100644 --- a/src/azure-cli/azure/cli/__main__.py +++ b/src/azure-cli/azure/cli/__main__.py @@ -13,7 +13,6 @@ import uuid from azure.cli.core import telemetry from azure.cli.core import get_default_cli -from azure.cli.core.intercept_survey import prompt_survey_message from knack.completion import ARGCOMPLETE_ENV_NAME from knack.log import get_logger @@ -119,11 +118,6 @@ finally: logger.warning("Auto upgrade failed. %s", str(ex)) telemetry.set_exception(ex, fault_type='auto-upgrade-failed') - try: - prompt_survey_message(az_cli) - except Exception as ex: # pylint: disable=broad-except - logger.debug("Intercept survey prompt failed. %s", str(ex)) - telemetry.set_init_time_elapsed("{:.6f}".format(init_finish_time - start_time)) telemetry.set_invoke_time_elapsed("{:.6f}".format(invoke_finish_time - init_finish_time)) telemetry.conclude()
signature.asc
Description: PGP signature