scylladb / scylla-cluster-tests

Tests for Scylla Clusters
GNU Affero General Public License v3.0
57 stars 95 forks source link

hydra failed with ModuleNotFoundError: No module named '_pytest._py' #8639

Closed asias closed 2 months ago

asias commented 2 months ago

Issue description

Steps to Reproduce

On fedora 40.

[asias@hjpc2 scylla-cluster-tests]$ git log -1
commit 9950447888bb4d1c09864e5e08f591a7459b6a27 (HEAD -> m20240911, origin/master, origin/HEAD)
Author: Israel Fruchter <[fruch@scylladb.com](mailto:fruch@scylladb.com)>
Date:   Mon Sep 9 09:44:59 2024 +0300

    fix(fips): switch fips check to be based on sct configuration

    since we have cases we'll want to run ubuntu pro (EOL versions as
    example), that won't have fips enable, the assumption that ubuntu pro
    mean only the fips images, isn't valid anymore.

    in this change we introduce a new configuration option, that
    would help us list the distro features we expect, so the test
    would be able to verify those on installation.

[asias@hjpc2 scylla-cluster-tests]$ sudo sh ./install-hydra.sh
Docker version 26.1.1, build 4cf5afa
Docker is installed.
'/usr/local/bin/hydra' -> '/home/asias/src/cloudius-systems/scylla-cluster-tests/docker/env/hydra.sh'
Hydra installed.
aws-cli/2.17.6 Python/3.12.5 Linux/6.10.3-200.fc40.x86_64 source/x86_64.fedora.40
AWS CLI installed.
==================================     NOTES      =================================================
To check that Hydra is installed, run 'hydra bash' anywhere in bash.
It will create a SCT Docker container and connect to its bash.
When running Hydra for the first time it will build the SCT Docker image. Please be patient!
===================================================================================================
Please run 'aws configure' to configure AWS CLI
[asias@hjpc2 scylla-cluster-tests]$ hydra investigate show-logs c44328c3-8dfd-4e00-a8c9-e8bc6c57c52a
There is scylladb/hydra:v1.75-event-collect-argus-0.12.7 in local cache, using it.
Going to run './sct.py  investigate show-logs c44328c3-8dfd-4e00-a8c9-e8bc6c57c52a'...
Traceback (most recent call last):
  File "/home/asias/src/cloudius-systems/scylla-cluster-tests/./sct.py", line 34, in <module>
    import pytest
  File "/home/asias/.local/lib/python3.10/site-packages/pytest/__init__.py", line 5, in <module>
    from _pytest.assertion import register_assert_rewrite
  File "/home/asias/.local/lib/python3.10/site-packages/_pytest/assertion/__init__.py", line 9, in <module>
    from _pytest.assertion import rewrite
  File "/home/asias/.local/lib/python3.10/site-packages/_pytest/assertion/rewrite.py", line 30, in <module>
    import py
  File "/usr/local/lib/python3.10/site-packages/py.py", line 6, in <module>
    import _pytest._py.error as error
ModuleNotFoundError: No module named '_pytest._py'

Impact

How frequently does it reproduce?

100%

Installation details

sct: 9950447888bb4d1c09864e5e08f591a7459b6a27

Logs

fruch commented 2 months ago

@asias

things in /home/asias/.local/ are seems to be in conflict to what's running inside hydra