Skip to content

[CI][Python] test_arrow_cogrouped_map and test_arrow_grouped_map from pyspark fail on integration job #44986

Open

Description

@raulcd

Describe the bug, including details regarding any error messages, version, and platform.

As seen here:
#44981 (comment)
When I tried to run "pyspark.sql.tests.arrow.test_arrow_grouped_map" and "pyspark.sql.tests.arrow.test_arrow_cogrouped_map" they fail due to missing pandas:

 Traceback (most recent call last):
  File "/spark/python/pyspark/sql/tests/arrow/test_arrow_grouped_map.py", line 264, in test_self_join
    df2 = df.groupby("k").applyInArrow(arrow_func, schema="x long, y long")
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/spark/python/pyspark/sql/pandas/group_ops.py", line 809, in applyInArrow
    udf = pandas_udf(
          ^^^^^^^^^^^
  File "/spark/python/pyspark/sql/pandas/functions.py", line 372, in pandas_udf
    require_minimum_pandas_version()
  File "/spark/python/pyspark/sql/pandas/utils.py", line 43, in require_minimum_pandas_version
    raise PySparkImportError(
pyspark.errors.exceptions.base.PySparkImportError: [PACKAGE_NOT_INSTALLED] Pandas >= 2.0.0 must be installed; however, it was not found.

Those tests were never executed in the past but might be worth to include them on the job as they are arrow related.

Component(s)

Continuous Integration, Python

Activity

  1. thisisnic commented on Nov 25, 2026

    @thisisnic
    Member

    I used an AI agent to look into the cause, and I've reviewed the results.


    🤖 :

    pandas looks to be missing from the image because of the order of steps in ci/docker/conda-python-spark.dockerfile: it installs pandas, then runs mamba uninstall -q -y numpy before install_numpy.sh. pandas depends on numpy, so the uninstall most likely removes it too.

    In the 2026-11-24 nightly (test-conda-python-3.11-spark-master):

    The uninstall runs with -q, so the log doesn't show pandas being removed; that part is inferred from it being installed and then absent.

    Installing pandas after install_numpy.sh should let the two excluded modules be re-enabled. I haven't been able to test that, because the nightly currently fails earlier: Spark master now requires JDK 21 and the image has 17.

  2. added
    Status: confirmed
    on Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions