class_docstr: Filesystem implementation for accessing workflow storage.
  
  We do not repeat the same comments for abstract methods in the base class.
class_docstr_tok: ["Filesystem","implementation","for","accessing","workflow","storage",".","We","do","not","repeat","the","same","comments","for","abstract","methods","in","the","base","class","."]
code: def __init__(self, workflow_root_dir: str):
      self._workflow_root_dir = pathlib.Path(workflow_root_dir)
      if self._workflow_root_dir.exists():
          if not self._workflow_root_dir.is_dir():
              raise ValueError(
                  f"storage path {workflow_root_dir} must be a directory."
              )
      else:
          self._workflow_root_dir.mkdir(parents=True)
  
file_path: ray/python/ray/workflow/storage/filesystem.py
imports: import os
  import contextlib
  import json
  import shutil
  import pathlib
  from typing import Any, List
  import uuid
  from ray.workflow.storage.base import Storage, KeyNotFoundError
  import ray.cloudpickle
label_desc: Use image node_id 1 to create a new FilesystemStorageImpl object from inherited base classes: Storage with example: obj = FilesystemStorageImpl(workflow_root_dir)