update-narwhals-testing
Skill9.8k starsChanged 4 months agoApache-2.0View on GitHub
Use when updating Narwhals for cudf-polars and cudf testing in CI
- Installs packages
Trending
Quiet since October.thin dataabout the whole repository
Who's talking about NVIDIA/cudf
- NVIDIA/cudf-spark-jni“[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot]”GitHub · Oct 5, 2026 · 1 reactions
- NVIDIA/cudf-spark-jni“[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot]”GitHub · Oct 4, 2026 · 1 reactions
- NVIDIA/cudf-spark-jni“[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot]”GitHub · Oct 2, 2026 · 1 reactions
- NVIDIA/cudf-spark-jni“[submodule-sync] bot-submodule-sync-release/26.10 to release/26.10 [skip ci] [bot]”GitHub · Oct 1, 2026 · 1 reactions
- NVIDIA/cudf-spark-jni“[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot]”GitHub · Oct 1, 2026 · 1 reactions
The biggest 5 of 9 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 9
Talked about on GitHub (9 times).
On GitHub · 9
- Oct 5, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Oct 4, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Oct 2, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Oct 1, 2026[submodule-sync] bot-submodule-sync-release/26.10 to release/26.10 [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Oct 1, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
4 more on GitHub
- Oct 1, 2026Seed pre-commit cache from main builds — rapidsai/cugraph-gnn1 reaction · 2 comments
- Oct 1, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Sep 30, 2026[submodule-sync] bot-submodule-sync-main to main [skip ci] [bot] — NVIDIA/cudf-spark-jni1 reaction · 3 comments
- Sep 22, 2026Support cached broadcast semi/anti joins via reusable FilteredJoin [databricks] — NVIDIA/cudf-spark1 reaction · 5 comments
In this repository9 other files it gives its agents.
- build-test-cudf-javaSkill
- build-test-cudfSkill
- debug-cudf-pandasSkill
- perf-compare-cudfSkill
- reproduce-ciSkill
- review-cudf-polars-expressionsSkill
- review-cudfSkill
- accelerated-computing-cudfSkill
- cudf-query-engine-builderSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 27
Ensure the Narwhals Git source tree is checked-out to the target upgrade version before installing.
- Very specific: line 58
Before running Narwhals unit tests, review each TESTS_TO_SKIP and EXPECTED_FAILURES in the plugin files and remove entries where the pytest …
- Very specific: line 65
If a test is failing because it exercises behavior that cannot be supported in cudf or cudf-polars, add a key, value pair to the …
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Narwhals testing for cudf-polars and cudf
This rule describes the procedure for updating Narwhals unit testing for cudf-polars
and cudf in CI. A successful update involves verifying locally that the variations of Narwhals unit test run in ci/test_narwhals.sh all pass.
Prerequisites
- Prompt the user for a suitable development environment that contains both cudf and cudf-polars.
- Prompt the user for the target Narwhals version for the upgrade.
Notes on the development environment:
- The environment must also have
pytest-envinstalled (it is a CI-only dependency and is often missing from local dev environments). Without it, the runs fail withImportError: Error importing plugin "env". - The environment may contain extra packages that the
test_python_narwhalsCI job does not install (for exampledask). Such packages can cause spurious local-only failures (for exampletests/tpch_q1_test.py::test_q1[dask], whichpytest.importorskips away in CI). Do not add these to a plugin; confirm a failure is reproducible in CI's dependency set before recording it.
Step 1. Bump Narwhals in dependencies.yaml
In the depends_on_narwhals section in dependencies.yaml, change the narwhals== version pinning to the target Narwhals version
Step 2. Install Narwhals from a local repository
Identify a directory that contains the Narwhals repository to install it into the development environment. If it is not provided by the user or one cannot be identified, clone it to a temporary location.
Ensure the Narwhals Git source tree is checked-out to the target upgrade version before installing.
Recent Narwhals versions use the uv_build build backend, so the editable install requires uv and uv-build in the environment and must be run with --no-build-isolation.
For example, to clone Narwhals and install it in a fictional, conda development environment named "cudf-dev"
NARWHALS_VERSION="v2.24.0"
git clone https://github.com/narwhals-dev/narwhals.git --single-branch --branch $NARWHALS_VERSION /tmp/narwhals
cd /tmp/narwhals
conda run -n cudf-dev pip install uv uv-build
conda run -n cudf-dev pip install -U -e . --no-build-isolationStep 3. Iterate and classify test failures from pytest invocations in ci/test_narwhals.sh
Next, iterate through the various Narwhals unit test invocations in ci/test_narwhals.sh via pytest until there are no test failures.
Currently 3 variations of Narwhals unit tests are run:
- With cudf through setting
--constructors=cudf - With cudf-polars through setting the
NARWHALS_POLARS_GPU=1environment variable and--constructors=polars[lazy] - With cudf.pandas through setting the
NARWHALS_DEFAULT_CONSTRUCTORS=pandasenvironment variable and-p cudf.pandas
Each of these variations has an accompanying pytest plugin to mark tests to skip or as expected to fail before the tests are run.
- The cudf test run uses
ci/narwhals_cudf_test_plugin.pyvia-p narwhals_cudf_test_plugin - The cudf.polars test run uses
ci/narwhals_cudf_polars_test_plugin.pyvia-p narwhals_cudf_polars_test_plugin - The cudf.pandas test run uses
ci/narwhals_cudf_pandas_test_plugin.pyvia-p narwhals_cudf_pandas_test_plugin
The TESTS_TO_SKIP and EXPECTED_FAILURES dictionaries in each file contain keys that are valid pytest test identifiers and values that are the reasons for skipping or failure of the test respectively.
Before running Narwhals unit tests, review each TESTS_TO_SKIP and EXPECTED_FAILURES in the plugin files and remove entries where the pytest test identifier no longer points to a test in Narwhals, as tests may have been removed in a newer Narwhals version.
Next, for each variation of Narwhals unit tests:
- Run the exact
pytestcommand found inci/test_narwhals.shfor the test variation and pipe the output to a file. Run it from within the cloned Narwhals repository (the CI script doespushd narwhalsfirst) and setPYTHONPATHto theci/directory so the-p narwhals_*_test_pluginplugins can be imported, e.g.PYTHONPATH="<repo>/ci" .... Node ids in this working directory are of the formtests/...py::<test>[...], which is exactly the dictionary key format. - Review the test output file and collect the failing tests.
- For each failing test:
- If a test is failing because it exercises behavior that cannot be supported in cudf or cudf-polars, add a key, value pair to the
TESTS_TO_SKIPdictionary where the key is in the format<path>::<pytest_node_id>and the value is a short reason for skipping. - If a test is failing because of a bug in cudf or cudf-polars, or a bug or bad assumption in Narwhals, add a key, value pair to the
EXPECTED_FAILURESdictionary where the key is in the format<path>::<pytest_node_id>and the value is a short reason for failure. - If a test reports
[XPASS(strict)](Narwhals marks itxfail(strict=True)for the constructor but it now passes), it must go inTESTS_TO_SKIP, notEXPECTED_FAILURES. Adding anxfailmarker does not override Narwhals' own strict marker, so the strict XPASS would still fail; skipping is the equivalent of the old deselection.
- If a test is failing because it exercises behavior that cannot be supported in cudf or cudf-polars, add a key, value pair to the
- Repeat the process until the test output file reports no failures.
Importantly when evaluating failing tests, do not attempt to fix cudf or cudf-polars to solve the failures. This is out of scope.
Once all variations of Narwhals unit tests pass, report the new test failures for each variation.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

