code: def test_invalid_utf8(tmp_path: Path) -> None:
      tmp_path.mkdir(exist_ok=True)
  
      np.random.seed(1)
      bts = bytes(np.random.randint(0, 255, 200))
  
      file_path = tmp_path / "nonutf8.csv"
      file_path.write_bytes(bts)
  
      a = pl.read_csv(
          file_path, has_header=False, encoding="utf8-lossy"
      )
      b = pl.scan_csv(
          file_path, has_header=False, encoding="utf8-lossy"
      ).collect()
  
      assert_frame_equal(a, b)
  
imports: from __future__ import annotations
  from collections import OrderedDict
  from typing import TYPE_CHECKING
  import numpy
  import pytest
  import polars
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 5 for calling a global function with example usage: test_invalid_utf8(tmp_path) without return types