code: def test_sort_by_bools() -> None:
      # tests dispatch
      df = pl.DataFrame(
          {
              "foo": [1, 2, 3],
              "bar": [6.0, 7.0, 8.0],
              "ham": ["a", "b", "c"],
          }
      )
      out = df.with_columns(
          (pl.col("foo") % 2 == 1).alias("foo_odd")
      ).sort(by=["foo_odd", "foo"])
      assert out.rows() == [
          (2, 7.0, "b", False),
          (1, 6.0, "a", True),
          (3, 8.0, "c", True),
      ]
      assert out.shape == (3, 4)
  
imports: from __future__ import annotations
  from datetime import datetime, timedelta
  from typing import Any
  import numpy
  import pandas
  import polars
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 1 for calling a global function with example usage: test_sort_by_bools() without return types