Skip to content

[BUG]: CI with Coverage fails on some cuda_core/tests/test_build_hooks #3344

Closed

Description

@jpascucci-nv

Is this a duplicate?

Type of Bug

Runtime Error

Component

cuda.core

Describe the bug

There are two tests that are failing on both Linux and Windows.

Failing jobs

Coverage (Linux): cuda_core/tests/test_build_hooks.py#L440
TestGeneratedSourceDirIsKeyed.test_dir_is_anchored_not_relative_to_cwd AssertionError: assert False + where False = is_absolute() + where is_absolute = PosixPath('.').is_absolute
Coverage (Windows): cuda_core\tests\test_build_hooks.py#L440
TestGeneratedSourceDirIsKeyed.test_dir_is_anchored_not_relative_to_cwd AssertionError: assert False + where False = is_absolute() + where is_absolute = WindowsPath('.').is_absolute

Coverage (Linux): cuda_core/tests/test_build_hooks.py#L429
TestGeneratedSourceDirIsKeyed.test_majors_use_different_dirs AssertionError: assert PosixPath('.') != PosixPath('.')
Coverage (Windows): cuda_core\tests\test_build_hooks.py#L429
TestGeneratedSourceDirIsKeyed.test_majors_use_different_dirs AssertionError: assert WindowsPath('.') != WindowsPath('.')

How to Reproduce

Run CI: Coverage in cuda-python CDCI.

Expected behavior

Those asserts look weird, so not that.

Operating System

No response

nvidia-smi output

No response

Activity

  1. added theissue type on Nov 3, 2026
  2. added this to the cuda.core 1.3.0 milestone on Nov 3, 2026
  3. jpascucci-nv commented on Nov 3, 2026

    @jpascucci-nv
    ContributorAuthor

    Additional info from Codex Sol 6.1:

    PR #2472, “build: make Cython/extension artifacts CUDA-major aware,” merged August 27, 2026, introduced these two tests and their coverage failures. Merge commit: 9cab1db.

    I verified both exact assertion failures in the first nightly run afterward:

    The cause is a test setup oversight: coverage sets CUDA_PYTHON_COVERAGE=1, which deliberately makes build_dir=".". The new tests assume ordinary build behavior, so both CUDA majors return the same relative directory—breaking both assertions.

    These failures can coexist with green coverage jobs because the test steps use continue-on-error: true. I also confirmed them in a later successful run.

  4. jpascucci-nv commented on Nov 4, 2026

    @jpascucci-nv
    ContributorAuthor

    This should be fixed by #3354

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions