Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PY3] Unit test CondCore/SiStripPlugins #28837

Closed
silviodonato opened this issue Jan 31, 2020 · 8 comments · Fixed by #28842
Closed

[PY3] Unit test CondCore/SiStripPlugins #28837

silviodonato opened this issue Jan 31, 2020 · 8 comments · Fixed by #28842

Comments

@silviodonato
Copy link
Contributor

@mmusich @ggovi
A unit test of CondCore/SiStripPlugins is crashing in Python3 since CMSSW_11_1_PY3_X_2020-01-28-2300 because of #28761 .

===== Test "testSiStripPayloadInspector" ====
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
ImportError: No module named site

---> test testSiStripPayloadInspector had ERRORS
 
^^^^ End Test testSiStripPayloadInspector ^^^^

The problems is related to boost::python used in the
CondCore/SiStripPlugins/test/testSiStripPayloadInspector.cpp

I tried to remove boost::python (see #28836) and the test is ok also in python3.
The problem arises from the method PlotBase::setInputParamValues(const boost::python::dict& values) that was integrated in CMSSW with #28648.

@davidlange6 is it allowed to use boost::python? Is there a way to make it compatible to both python 2 and 3?

@cmsbuild
Copy link
Contributor

A new Issue was created by @silviodonato Silvio Donato.

@Dr15Jones, @smuzaffar, @silviodonato, @makortel, @davidlange6, @fabiocos can you please review it and eventually sign/assign? Thanks.

cms-bot commands are listed here

@silviodonato
Copy link
Contributor Author

assign db

@cmsbuild
Copy link
Contributor

New categories assigned: db

@ggovi you have been requested to review this Pull request/Issue and eventually sign? Thanks

@silviodonato
Copy link
Contributor Author

assign core

@cmsbuild
Copy link
Contributor

New categories assigned: core

@Dr15Jones,@smuzaffar,@makortel you have been requested to review this Pull request/Issue and eventually sign? Thanks

@mmusich
Copy link
Contributor

mmusich commented Jan 31, 2020

@silviodonato

The problems is related to boost::python

as far as I can see the problem is not due to boost::python in itself but rather to the Py_Initialize(), which is necessary to in order to avoid a segfault with the boost::python::dict.
Some search around in cmssw brought me to the solution at #28842 , but I am definitely not an expert so if someone with better python-fu can cross-check I would be glad.

@davidlange6
Copy link
Contributor

naively we should not set PYTHONHOME by hand. Seems a missing dependency in the Buildfile?

@mmusich
Copy link
Contributor

mmusich commented Feb 3, 2020

as far as I can see @smuzaffar did the same here: aff1edc ...

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

Successfully merging a pull request may close this issue.

4 participants