Open kloczek opened 2 years ago
I forgot aboit one thing. tests/test_tracer.py requires eviltracer
module which I cannot find on pypi
+ /usr/bin/pytest -ra tests/test_tracer.py
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.12, pytest-6.2.5, py-1.11.0, pluggy-1.0.0
benchmark: 3.4.1 (defaults: timer=time.perf_counter disable_gc=False min_rounds=5 min_time=0.000005 max_time=1.0 calibration_precision=10 warmup=False warmup_iterations=100000)
rootdir: /home/tkloczko/rpmbuild/BUILD/python-hunter-3.4.3, configfile: setup.cfg
plugins: hypothesis-6.34.1, cov-3.0.0, aspectlib-1.5.2, benchmark-3.4.1
collected 0 items / 1 error
================================================================================== ERRORS ==================================================================================
__________________________________________________________________ ERROR collecting tests/test_tracer.py ___________________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/python-hunter-3.4.3/tests/test_tracer.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
tests/test_tracer.py:81: in <module>
from eviltracer import EvilTracer
E ModuleNotFoundError: No module named 'eviltracer'
========================================================================= short test summary info ==========================================================================
ERROR tests/test_tracer.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================= 1 error in 0.28s =============================================================================
And yet another small detail :P gcc warning:
/usr/bin/gcc -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fstack-protector-strong -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -D_GNU_SOURCE -fPIC -fwrapv -ffat-lto-objects -D_GNU_SOURCE -fPIC -fwrapv -O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -D_GNU_SOURCE -fPIC -fwrapv -ffat-lto-objects -O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -D_GNU_SOURCE -fPIC -fwrapv -ffat-lto-objects -O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -fPIC -Isrc/hunter -I/tmp/build-env-8vy2rl4h/include -I/usr/include/python3.8 -c src/hunter/_predicates.c -o build/temp.linux-x86_64-3.8/src/hunter/_predicates.o
src/hunter/_predicates.c:24144:18: warning: ‘__Pyx_CFunc_object____Event___to_py’ defined but not used [-Wunused-function]
24144 | static PyObject *__Pyx_CFunc_object____Event___to_py(PyObject *(*__pyx_v_f)(struct __pyx_obj_6hunter_6_event_Event *)) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ok so there are a number of issues here:
./tests
not being on the import path (import failures for eviltracer, samplesomething and so on). Some of those modules (eviltracer and some other one) require an extension build (see tests/setup.py
)line '[[]*[]] *MainThread something' not found in output
failures seem to be some weird alignment issue, I guess tests could be patched to have line '[[]*[]]*MainThread
instead of line '[[]*[]] *MainThread
- does that make the problem go away?OK. Thank you. Ad 3: why that file cannot be copied to exact location as part of the test suite?
It's correct location is too variable and more importantly I want to test that the installation is working as expected (it's a integration test after all...).
If you will have any PR which you want to test before actual merge please let me know. I would be happy to test that 😄
Sorry for asking. Any update? 🤔
BTW looks like test suite uses eviltracer
and I cannot find that module on pypi.
Just FTR pytest output of 3.6.1
BTW looks like test suite uses
eviltracer
and I cannot find that module on pypi.
Gentle ping .. ay update about that part? 🤔
That question was already answered above. It's shipped with the tests.
That question was already answered above. It's shipped with the tests.
Sorry my mistake.
Why not just build that module DSO as normal part of the build and exclude it from be a part of the wheel archive? 🤔
I'm trying to package your module as an rpm package. So I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w
Here is pytest output: