code: def text_gz_path(tmp_path_factory, text_path):
      import gzip
  
      path = str(tmp_path_factory.mktemp("data") / "dataset.txt.gz")
      with open(text_path, "rb") as orig_file:
          with gzip.open(path, "wb") as zipped_file:
              zipped_file.writelines(orig_file)
      return path
  
imports: import contextlib
  import csv
  import json
  import os
  import sqlite3
  import tarfile
  import textwrap
  import zipfile
  import pyarrow
  import pyarrow.parquet
  import pytest
  import datasets
  import datasets.config
label_desc: Use image node_id 29 for calling a global function with example usage: text_gz_path(tmp_path_factory, text_path) and returns: path