component/pandas: fix versions
version 0.25.3 is not python2 compatible. Use version 0.24.2 as it is compatible with both python2 and python3.7 (even though we have no reason to use python3.7 nowadays). See https://pypi.org/project/pandas/0.24.2/
-
Owner
I see some tests ( for example https://erp5js.nexedi.net/#/test_result_module/20221216-D813B01 ) are stuck with errors like :
2022-12-16 11:34:50,072 INFO Traceback (most recent call last): 2022-12-16 11:34:50,073 INFO File "/srv/slapgrid/slappart16/t/ata/soft/ccf6aba12cda52f78c00e8ead64e361a/bin/runTestSuite", line 304, in <module> 2022-12-16 11:34:50,073 INFO import Products.ERP5Type.tests.runTestSuite 2022-12-16 11:34:50,073 INFO File "/srv/slapgrid/slappart16/t/ata/soft/ccf6aba12cda52f78c00e8ead64e361a/parts/erp5/product/ERP5Type/__init__.py", line 92, in <module> 2022-12-16 11:34:50,073 INFO from . import ZopePatch 2022-12-16 11:34:50,073 INFO File "/srv/slapgrid/slappart16/t/ata/soft/ccf6aba12cda52f78c00e8ead64e361a/parts/erp5/product/ERP5Type/ZopePatch.py", line 30, in <module> 2022-12-16 11:34:50,073 INFO from Products.ERP5Type.patches import Restricted 2022-12-16 11:34:50,073 INFO File "/srv/slapgrid/slappart16/t/ata/soft/ccf6aba12cda52f78c00e8ead64e361a/parts/erp5/product/ERP5Type/patches/Restricted.py", line 492, in <module> 2022-12-16 11:34:50,073 INFO allow_type(pd.indexes.range.RangeIndex)
is this was this change is fixing ?
if yes, can you please merge master in 1.0 so that we have the fix in 1.0 ?
-
Owner
mmmh the test is already on using slapos master branch, not 1.0 so there might still be something wrong.
But maybe it's just that we need to make the testnode reinstall the software from scratch, my guess is that this testnode had installed 0.25.4 and is not downgrading to 0.24.2. I'm not sure but there might be a bug like this when updating softwares "in place" like testnodes do
-
Owner
I tried to force ERP5.CodingStyleTest-Master to use a different software, we'll see if it makes the problem disappear
-
Owner
Please note that ERP5 was always using 0.19.2 (from jupyter-py2 component), then Xavier changed pandas component which was overwriting the version of pandas to 0.25.3 which was not working in python2. So I did this commit.
Also, in order to remove the confusion with the versions, I totally removed the other pandas versions in 431eed50
Maybe the fix is to reuse version 0.19.2 for ERP5.
-
Owner
I suggest this patch:
$ git diff diff --git a/stack/erp5/buildout.cfg b/stack/erp5/buildout.cfg index e80eac4df..20c64e4ce 100644 --- a/stack/erp5/buildout.cfg +++ b/stack/erp5/buildout.cfg @@ -865,3 +865,4 @@ strict-rfc3339 = 0.7 webcolors = 1.10 rfc3987 = 1.3.8 jsonpointer = 2.2 +pandas = 0.19.2
-
Owner
numpy was not
mmmh maybe I misunderstood.
In https://erp5js.nexedi.net/#/test_result_module/20221216-4A0A3D65/96 we have some failures related to numpy:
====================================================================== ERROR: testNumpy (erp5.component.test.erp5_version.testRestrictedPythonSecurity.TestRestrictedPythonSecurity) ---------------------------------------------------------------------- Traceback (most recent call last): File "<portal_components/test.erp5.testRestrictedPythonSecurity>", line 486, in testNumpy expected=["int32", 8] File "<portal_components/test.erp5.testRestrictedPythonSecurity>", line 63, in createAndRunScript self.assertEqual(self.runScript(script_container, name, kwargs.get('kwargs', {})), expected) File "<portal_components/test.erp5.testRestrictedPythonSecurity>", line 53, in runScript return func(**kwargs) File "/srv/slapgrid/slappart37/t/aai/soft/b048b75d6f500a14b26028c49507f7c1/parts/erp5/product/ERP5Type/patches/PythonScript.py", line 179, in __call__ return self._orig_bindAndExec(args, kw, None) File "/srv/slapgrid/slappart37/t/aai/soft/b048b75d6f500a14b26028c49507f7c1/eggs/Zope2-2.13.30-py2.7.egg/Shared/DC/Scripts/Bindings.py", line 359, in _bindAndExec return self._exec(bound_data, args, kw) File "/srv/slapgrid/slappart37/t/aai/soft/b048b75d6f500a14b26028c49507f7c1/parts/erp5/product/ERP5Type/tests/ERP5TypeTestCase.py", line 1625, in _exec return PythonScript_exec(self, *args) File "/srv/slapgrid/slappart37/t/aai/soft/b048b75d6f500a14b26028c49507f7c1/eggs/Products.PythonScripts-2.13.2-py2.7.egg/Products/PythonScripts/PythonScript.py", line 344, in _exec result = f(*args, **kw) File "Script (Python)", line 2, in 91fe8070-7d44-11ed-94d6-fe19219e6fb4 File "/srv/slapgrid/slappart37/t/aai/soft/b048b75d6f500a14b26028c49507f7c1/parts/erp5/product/ERP5Type/patches/Restricted.py", line 389, in guarded_import raise Unauthorized(fromname) Unauthorized: You are not allowed to access '__doc__' in this context
did we change numpy version ?
-
Owner
did we change numpy version ?
yes, we changed from 1.13.1 to 1.16.5, let me know if yo want to revert this too for erp5 or you want to see what is the problem in the test ?
-
mentioned in merge request !1355 (merged)