- 22 Oct, 2024 30 commits
-
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
Prevent generating wrong urls for now
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
romain_dev: forum romain_dev: forum use html viewer romain_dev: forum improve post rendering romain_dev: thread reader use page language inqtead of local romain_dev: forum set expected link on the listbox cells romain_dev: thread fixup romain_dev: thread use line separator instead of background color romain_dev: thread paginate romain_dev: forum link to last page romain_dev: thread simplify conf from erp5form romain_dev: forum attachment romain_dev: thread force white background
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
This reverts commit e50d05af.
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
Do not access form submission REQUEST from the listbox list method, as it is rendered asynchronously in ERP5JS
-
Romain Courteaud authored
-
Romain Courteaud authored
Allow edition in the new UI
-
Romain Courteaud authored
-
Romain Courteaud authored
This make everything slow as hell and prevent to quickly save.
-
Romain Courteaud authored
Example: <h2 class="foo">bar</h2> => <h3 class="foo">bar</h3>
-
Romain Courteaud authored
-
Romain Courteaud authored
erp5_web_renderjs_ui: keep previous focus color
-
Romain Courteaud authored
-
Romain Courteaud authored
-
Romain Courteaud authored
Change max age to 1 hour and 1 day
-
Romain Courteaud authored
If user group are recalculated before changing the workflow state, it will only return the same security group See nexedi/erp5@c00c3636
-
Romain Courteaud authored
-
- 16 Oct, 2024 5 commits
-
-
Jérome Perrin authored
`sender@customer.com <sender@customer.com>` used in the test is not a valid email address. We have updated to python3.9.20 which comes with a fix for CVE-2023-27043 and no longer allow this kind of broken addresses. Replace the address with a similar valid address, `"sender@customer.com" <sender@customer.com>`, that was probably the original intention of this test.
-
Jérome Perrin authored
On python3, the type of selected columns depend on the data type from mariadb side, VARCHAR will be str, BINARY/BLOB will be bytes, etc These SQL method select path that is first evaluated from a variable that is NULL and in that case, mariadb seems to select LONGBLOB as data type: MariaDB [test]> set @defined_as_null=null; drop table if exists tmp; create table tmp as (select @defined_as_null); show create table tmp; +-------+------------------------------------------------------------------------------------------------------------------------------------+ | Table | Create Table | +-------+------------------------------------------------------------------------------------------------------------------------------------+ | tmp | CREATE TABLE `tmp` ( `@defined_as_null` longblob DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci | +-------+------------------------------------------------------------------------------------------------------------------------------------+ By casting to CHAR in SQL, on the python side we always have the str that we expect here, because this is used as path attribute of a SQL brain.
-
Jérome Perrin authored
-
Jérome Perrin authored
This is similar to 18deb716 (ProcessingNodeTestCase: also setRequest in processing_node, 2023-05-02), as said in that commit message, timerserver loop calls setRequest, but before entering the loop, we wait for the portal to be created with: 447 │ try: 448 │ self.portal = self.app[self.app.test_portal_name] 449 │ except (AttributeError, KeyError): 450 │ continue While accessing like this, this will load classes and initialize dynamic modules, on python2 this was OK, but on python3 this was raising an error because `getRequest` returned None: File "./parts/erp5/product/ERP5Type/dynamic/component_package.py", line 449, in load_module return self.__load_module(fullname) File "./parts/erp5/product/ERP5Type/dynamic/component_package.py", line 416, in __load_module erp5.component.ref_manager.add_module(module) File "./parts/erp5/product/ERP5Type/dynamic/dynamic_module.py", line 86, in add_module self.add_request(get_request()) File "./parts/erp5/product/ERP5Type/dynamic/dynamic_module.py", line 64, in add_request self.setdefault(last_sync, (WeakSet(), set()))[0].add(request_obj) File "./lib/python3.9/_weakrefset.py", line 89, in add self.data.add(ref(item, self._remove)) TypeError: cannot create weak reference to 'NoneType' object On python2, this was actually raising as well, but this error is hidden by a `hasattr`, because on python2 `hasattr` ignores all exceptions and on python3 it only ignores only `AttributeError`. File "./parts/erp5/product/ERP5Type/Core/PropertySheet.py", line 61, in createAccessorHolder self.applyOnAccessorHolder(accessor_holder, expression_context, portal) File "./parts/erp5/product/ERP5Type/Core/PropertySheet.py", line 175, in applyOnAccessorHolder for property_definition in self.contentValues(): File "./parts/erp5/product/ERP5Type/Core/Folder.py", line 1570, in contentValues portal_type_id_list = self._getTypesTool().listContentTypes() File "./parts/erp5/product/ERP5Type/Tool/TypesTool.py", line 173, in listContentTypes provider_value = _getOb(provider, None) File "./eggs/Zope-4.8.7-py2.7.egg/OFS/ObjectManager.py", line 323, in _getOb if id[:1] != '_' and hasattr(aq_base(self), id): File "./parts/erp5/product/ERP5Type/dynamic/lazy_class.py", line 120, in __getattribute__ self.__class__.loadClass()
-
Nicolas Wavrant authored
-
- 15 Oct, 2024 5 commits
-
-
Nicolas Wavrant authored
And simplify just a bit the code
-
Jérome Perrin authored
FutureWarning: This search incorrectly ignores the root element, and will be fixed in a future version. If you rely on the current behaviour, change it to './/role'.
-
Arnaud Fontaine authored
py3: TestTradeModelLineMixin inherited from UserDict() to store values on the class direcly (!1751). This does not work with py3: File "parts/erp5/Products/ERP5Type/tests/runUnitTest.py", line 941, in main result = runUnitTestList(test_list=args, File "parts/erp5/Products/ERP5Type/tests/runUnitTest.py", line 703, in runUnitTestList result = TestRunner(verbosity=verbosity).run(suite) [...] File "parts/python3/lib/python3.9/unittest/runner.py", line 184, in run test(result) [...] File "parts/python3/lib/python3.9/unittest/suite.py", line 84, in __call__ return self.run(*args, **kwds) File "parts/python3/lib/python3.9/unittest/suite.py", line 111, in run if _isnotsuite(test): File "parts/python3/lib/python3.9/unittest/suite.py", line 369, in _isnotsuite iter(test) File "parts/python3/lib/python3.9/collections/__init__.py", line 1067, in __iter__ return iter(self.data) AttributeError: 'TestComplexTradeModelLineUseCaseSale' object has no attribute 'data' Use a dedicated dict() to store these values as there was no strong reasons to inherit from UserDict() here and this makes test implementation easier too...
-
Jérome Perrin authored
group_id is used as key of OOBtree and as documented, it's not possible to mix keys that can not be compared, so we can not have a mix of string and bytes, for consistency with other BTrees, such as the ones used for OFS. group_id is also used in a SQL column which is BINARY, this is problematic on py3 because the selected values will be returned as bytes, but we expect str here. Because we don't want to run a data migration, we adjust the select methods to convert to str while selecting. Since years there was a warning that id_group must be a string, now we make it a bit stricter, we also enforce that the id_group is valid UTF-8. A few more tests and assertions were also added.
-
Jérome Perrin authored
Since Zope commit 020685087 (`Allow ZPublisher to handle a query string together with a request body (#1124)`, 2023-05-15) Zope tries to process all XML HTTP requests as XML-RPC and we need to tell that these SOAP requests are not XML-RPC.
-