Why Azure DevOps pytest execution pipeline does not recognize my python module?

Gharaei Ali, MSRD6, BUZ 0 Reputation points
2023-10-19T11:24:24.99+00:00

I am running a pytest pipeline on Azure DevOps for my python project. It produces the error below despite adding init.py

Is it a bug in Azure DevOps? How can I resolve this issue?

ImportError while importing test module '/home/vsts/work/1/s/test_wago_plc_connection.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.10/importlib/__init__.py:126: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
test_wago_plc_connection.py:6: in 
Community Center Not monitored
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.