From b054ba408871546bfa3c7111043145a187d0ccfd Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Sun, 23 Aug 2020 01:05:18 +0300 Subject: [PATCH] No offline mode when running remotely --- trains/backend_interface/task/task.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/trains/backend_interface/task/task.py b/trains/backend_interface/task/task.py index 48cd18d4..66e0214a 100644 --- a/trains/backend_interface/task/task.py +++ b/trains/backend_interface/task/task.py @@ -1806,9 +1806,10 @@ class Task(IdObjectBase, AccessMixin, SetupUploadMixin): :param offline_mode: If True, offline-mode is turned on, and no communication to the backend is enabled. :return: """ - ENV_OFFLINE_MODE.set(offline_mode) - InterfaceBase._offline_mode = bool(offline_mode) - Session._offline_mode = bool(offline_mode) + if not running_remotely(): + ENV_OFFLINE_MODE.set(offline_mode) + InterfaceBase._offline_mode = bool(offline_mode) + Session._offline_mode = bool(offline_mode) @classmethod def is_offline(cls):