code: def test_list_to_array_wrong_lengths() -> None:
      s = pl.Series([[1.0, 2.0], [3.0, 4.0]], dtype=pl.List(pl.Float32))
      with pytest.raises(
          pl.ComputeError,
          match="not all elements have the specified width",
      ):
          s.list.to_array(3)
  
imports: from __future__ import annotations
  from datetime import date, datetime
  import numpy
  import pytest
  import polars
  from polars.testing import assert_frame_equal, assert_series_equal
label_desc: Use image node_id 43 for calling a global function with example usage: test_list_to_array_wrong_lengths() without return types