重要提示: 此中文文档针对的是 Yarn 的最新版本。
有关 1.x 版本的中文文档,请点击进入 classic.yarnpkg.cn。
Yarn
ArchitectureContributingError CodesLexiconLifecycle ScriptsPlugin TutorialPnP APIPnP SpecificationPnPifyRulebookTelemetry

Telemetry

Edit this page on GitHub

Why does Yarn need some telemetry?

As maintainers, it's sometimes difficult to know what we should prioritize. Are large monorepos the most common situation our users encounter? What packageExtensions are the most common? How many people opted-out to the nm linker? Etc.

Additionally, because of the lack of telemetry, some projects also had trouble taking us seriously. Various threads in the Node docker image repositories suggested to remove Yarn from the Docker image, citing Yarn as a fringe tool. Our team doesn't have time to spend collecting the various polls from the surface of the earth, nor should we have to.

Will my information go to Facebook?

No. Yarn is not a Facebook project, and Facebook won't receive any amount of data collected this way, and neither will Google, or Microsoft.

The data we collect are stored on Datadog, a trusted large-scale monitoring company with a heavy focus on security.

Which information are we talking about?

As of today, we collect the following:

  • The Yarn version
  • Which command name is used (but not its arguments)
  • The active plugin names (only for our own plugins; yours are hidden)
  • The number of installs run during the week
  • The number of different projects having been installed
  • How many installs for the nm linker
  • The number of workspaces
  • The number of dependencies
  • The packageExtensions field (name of extended + name of the extra dependency)
  • The IP address (most providers unfortunately don't let us remove that)

Data are sent via batches, roughly every seven days. This prevents us from tracking your usage with a too high granularity, leaving us only the most useful information to do our job efficiently.

How can I disable it?

Note that, regardless of the configuration, the telemetry won't ever run on CI.

  • To disable it on a project (including for anyone who would clone it), run yarn config set enableTelemetry 0. This will make our life ever so slightly more difficult, so please consider whether it's really what you want to do.

  • To disable it on your whole machine (but not for anyone else), run yarn config set --home enableTelemetry 0.