code: def from_env(cls) -> "WorkerConfig":
      env = Env(expand_vars=True)
      with env.prefixed("WORKER_"):
          return cls(
              content_max_bytes=env.int(
                  name="CONTENT_MAX_BYTES",
                  default=WORKER_CONTENT_MAX_BYTES,
              ),
              difficulty_max=env.int(
                  name="DIFFICULTY_MAX", default=WORKER_DIFFICULTY_MAX
              ),
              difficulty_min=env.int(
                  name="DIFFICULTY_MIN", default=WORKER_DIFFICULTY_MIN
              ),
              heartbeat_interval_seconds=env.float(
                  name="HEARTBEAT_INTERVAL_SECONDS",
                  default=WORKER_HEARTBEAT_INTERVAL_SECONDS,
              ),
              job_types_blocked=env.list(
                  name="JOB_TYPES_BLOCKED", default=get_empty_str_list()
              ),
              job_types_only=env.list(
                  name="JOB_TYPES_ONLY", default=get_empty_str_list()
              ),
              kill_long_job_interval_seconds=env.float(
                  name="KILL_LONG_JOB_INTERVAL_SECONDS",
                  default=WORKER_KILL_LONG_JOB_INTERVAL_SECONDS,
              ),
              kill_zombies_interval_seconds=env.float(
                  name="KILL_ZOMBIES_INTERVAL_SECONDS",
                  default=WORKER_KILL_ZOMBIES_INTERVAL_SECONDS,
              ),
              max_job_duration_seconds=env.float(
                  name="MAX_JOB_DURATION_SECONDS",
                  default=WORKER_MAX_JOB_DURATION_SECONDS,
              ),
              max_load_pct=env.int(
                  name="MAX_LOAD_PCT", default=WORKER_MAX_LOAD_PCT
              ),
              max_memory_pct=env.int(
                  name="MAX_MEMORY_PCT", default=WORKER_MAX_MEMORY_PCT
              ),
              max_missing_heartbeats=env.int(
                  name="MAX_MISSING_HEARTBEATS",
                  default=WORKER_MAX_MISSING_HEARTBEATS,
              ),
              sleep_seconds=env.float(
                  name="SLEEP_SECONDS", default=WORKER_SLEEP_SECONDS
              ),
              state_file_path=env.str(
                  name="STATE_FILE_PATH", default=WORKER_STATE_FILE_PATH
              ),  # this environment variable is not expected to be set explicitly, it's set by the worker executor
          )
  
imports: from dataclasses import dataclass, field
  from typing import Optional
  from environs import Env
  from libcommon.config import AssetsConfig, CacheConfig, CommonConfig, LogConfig, ParquetMetadataConfig, QueueConfig, RowsIndexConfig, S3Config
label_desc: Use image node_id 1 for calling the WorkerConfig obj's underlying member method code with example usage: obj.from_env(cls) and returns: cls