fix: do not push telemetry on non-master rank (#3438)

This commit is contained in:
NanoCode012
2026-03-02 15:31:20 +07:00
committed by GitHub
parent 7f23b302d1
commit f447bce1db

View File

@@ -156,6 +156,10 @@ class TelemetryManager:
Returns:
Boolean denoting whether telemetry is enabled or not.
"""
# Only rank 0 will send telemetry
if not is_main_process():
return False
# Parse relevant env vars
axolotl_do_not_track = os.getenv("AXOLOTL_DO_NOT_TRACK")
do_not_track = os.getenv("DO_NOT_TRACK")
@@ -169,10 +173,6 @@ class TelemetryManager:
):
return True
# Only rank 0 will send telemetry
if not is_main_process():
return False
if do_not_track is None:
do_not_track = "0"