From 6eb69010d7f71d765f0e9ca43b34f3edf5d90752 Mon Sep 17 00:00:00 2001 From: Dmitry Sorokin Date: Mon, 29 Jul 2024 16:03:35 +0100 Subject: [PATCH] Update readme.md after opt-out Signed-off-by: Dmitry Sorokin --- kedro-telemetry/README.md | 47 ++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 25 deletions(-) diff --git a/kedro-telemetry/README.md b/kedro-telemetry/README.md index c5ca2f816..689178e44 100644 --- a/kedro-telemetry/README.md +++ b/kedro-telemetry/README.md @@ -20,42 +20,39 @@ for further information on the intent of the data collection and what data is co For technical information on how the telemetry collection works, you can browse [the source code of `kedro-telemetry`](https://github.com/kedro-org/kedro-plugins/tree/main/kedro-telemetry). -## How do I consent to the use of Kedro-Telemetry? +## How do I withdraw consent? -Kedro-Telemetry is a Python plugin. To install it: +To withdraw consent, you have a few options: -```console -pip install kedro-telemetry -``` +1. **Set Environment Variables**: + Set the environment variables `DO_NOT_TRACK` or `KEDRO_DISABLE_TELEMETRY` to any value. The presence of these environment variables will disable telemetry for all Kedro projects in that environment. -> _Note:_ If you are using an official [Kedro project template](https://kedro.readthedocs.io/en/stable/02_get_started/06_starters.html) then `kedro-telemetry` is included in the [project-level `requirements.txt`](https://kedro.readthedocs.io/en/stable/04_kedro_project_setup/01_dependencies.html#kedro-install) of the starter. `kedro-telemetry` is activated after you have a created a new project with a [Kedro project template](https://kedro.readthedocs.io/en/stable/02_get_started/06_starters.html) and have run `kedro install` from the terminal. +2. **CLI Option When Creating a New Project**: + When creating a new project, you can use the command: -When you next run the Kedro CLI you will be asked for consent to share usage analytics data for the purposes explained in the privacy notice, and a `.telemetry` YAML file will be created in the project root directory. The variable `consent` will be set according to your choice in the file, e.g. if you consent: + ```console + kedro new --telemetry=yes/no + ``` + This will create a `.telemetry` file inside the new project's folder with `consent: true/false` accordingly. This file will be used when executing Kedro commands within that project folder. Note that telemetry data about the execution of the `kedro new` command will still be sent if telemetry has not been disabled using environment variables. -```yaml -consent: true -``` + >*Note:* The `.telemetry` file should not be committed to `git` or packaged in deployment. In `kedro>=0.17.4` the file is git-ignored. ->*Note:* The `.telemetry` file should not be committed to `git` or packaged in deployment. In `kedro>=0.17.4` the file is git-ignored. - -## How do I withdraw consent? +3. **Modify or Create the `.telemetry` File**: + If the `.telemetry` file exists in the root folder of your Kedro project, set the `consent` variable to `false`. If the file does not exist, create it with the following content: + ```yaml + consent: false + ``` -To withdraw consent, you can change the `consent` variable to `false` in `.telemetry` YAML by editing the file in the following way: +4. **Uninstall the Plugin**: + Remove the `kedro-telemetry` plugin: -```yaml -consent: false -``` -You can also set `DO_NOT_TRACK` or `KEDRO_DISABLE_TELEMETRY` environment variable to `True`. - -Or you can uninstall the plugin: - -```console -pip uninstall kedro-telemetry -``` + ```console + pip uninstall kedro-telemetry + ``` ## What happens when I withdraw consent? -Data will only be collected if consent is given. Otherwise, if consent was explicitly denied or withdrawn, the message below will be printed out on every Kedro CLI invocation. If you explicitly deny consent from the beginning, no data will be collected. If you withdraw consent later, the processing of data will be stopped from that moment on. +Data collection for telemetry is enabled by default. If consent was explicitly denied or withdrawn, the message below will be printed out on every Kedro CLI invocation. If you explicitly deny consent from the beginning, no data will be collected. If you withdraw consent later, the processing of data will be stopped from that moment on. ``` Kedro-Telemetry is installed, but you have opted out of sharing usage analytics so none will be collected.