code: def test_open(self, temp_workdir):
      project = Project()
      with open("foo.txt", "w") as f:
          f.write("foo")
  
      with open("keepsake.yaml", "w") as f:
          f.write("repository: file://.keepsake/")
  
      exp = project.experiments.create(
          path=".", params={"foo": "bar"}, disable_heartbeat=True
      )
      with open("bar.txt", "w") as f:
          f.write("bar")
      chk = exp.checkpoint(
          path="bar.txt", metrics={"accuracy": "awesome"}
      )
  
      chk_tar_path = os.path.join(
          ".keepsake/checkpoints", chk.id + ".tar.gz"
      )
      wait(
          lambda: os.path.exists(chk_tar_path),
          timeout_seconds=5,
          sleep_seconds=0.01,
      )
      time.sleep(0.1)  # wait to finish writing
  
      # test with already existing checkpoint
      assert chk.open("foo.txt").read().decode() == "foo"
      assert chk.open("bar.txt").read().decode() == "bar"
  
      # test with checkpoint from keepsake.experiments.list()
      exp = project.experiments.list()[0]
      chk = exp.checkpoints[0]
      assert chk.open("foo.txt").read().decode() == "foo"
      assert chk.open("bar.txt").read().decode() == "bar"
  
file_path: keepsake/python/tests/test_checkpoint.py
imports: import datetime
  import time
  import os
  import pytest
  from waiting import wait
  from keepsake.checkpoint import Checkpoint, CheckpointList
  from keepsake.exceptions import DoesNotExist
  from keepsake.project import Project
  from tests.factories import experiment_factory, checkpoint_factory
label_desc: Use image node_id 4 for calling the TestCheckpoint obj's underlying member method code with example usage: obj.test_open(temp_workdir) without return types