- 28 Jan, 2022 1 commit
-
-
Kirill Smelkov authored
Pygolang installs import hooks for pytest and ipython, to add exception-chaining support into them(*) _iff_ (if and only if) those modules are actually used. This works via Importing[1] which pre-installs artificial modules into sys.modules that catch __getattribute__ and try to import corresponding module for real on first access. Usually everything is fine. But with pylint/astroid, if the checker code happens to run with those LazyModules installed, and the checked code has `import sys` somewhere, astroid eventually delves into processing sys, then sys.modules and wants to represent that sys.modules dict as dict of constant. Then, when e.g. sys.modules['_pytest'] is processed, corresponding module object is checked for .__class__, which raises ImportError if pytest is not actually available: ( https://erp5js.nexedi.net/#/test_result_module/20220127-129289AE2/33 ) ... File ".../eggs/astroid-1.3.8-py2.7.egg/astroid/node_classes.py", line 553, in __init__ for k, v in items.items()] File ".../eggs/astroid-1.3.8-py2.7.egg/astroid/node_classes.py", line 962, in const_factory return CONST_CLS[value.__class__](value) File ".../eggs/Importing-1.10-py2.7.egg/peak/util/imports.py", line 254, in __getattribute__ _loadModule(self) File ".../eggs/Importing-1.10-py2.7.egg/peak/util/imports.py", line 222, in _loadModule reload(module) ImportError: No module named _pytest -> Fix it by detecting those lazy modules and not letting them go through normal const_factory not to crash. /cc @jerome, @arnau [1] https://pypi.org/project/Importing/ (*) see: https://lab.nexedi.com/nexedi/pygolang/blob/pygolang-0.1-0-g7b72d41/golang/_patch/__init__.py https://lab.nexedi.com/nexedi/pygolang/blob/pygolang-0.1-0-g7b72d41/golang/_patch/pytest_py2.py#L48-51 https://lab.nexedi.com/nexedi/pygolang/blob/pygolang-0.1-0-g7b72d41/golang/_patch/ipython_py2.py#L45-48
-
- 18 Jan, 2022 4 commits
-
-
Rafael Monnerat authored
See merge request nexedi/erp5!1534
-
Jérome Perrin authored
Only catch exceptions, we don't need a bare except here. In case of exception, log the traceback instead of being silent.
-
Jérome Perrin authored
Since https://github.com/zopefoundation/Zope/commit/2da2c2c28a8b21e78e8ef93aa17da926e3102c26 SERVER_PORT is assumed to be convertible to int. The value of this port is not really supposed to be used because TimerServer requests does not have a server (for example in CMFActivity we recreate the initial request), so put a value of -1 to prevent accidental use.
-
Jérome Perrin authored
When running with ZServer, TimerServer will be started by ZConfig machinery, because ZServer comes with some ZConfig data types for server factory which start servers. One Zope 2, ZServer was imported from zopeschema: https://github.com/zopefoundation/Zope/blob/2.13.30/src/Zope2/Startup/zopeschema.xml#L10 and ZConfig used the TimerServerFactory to create a TimerService. On Zope 4, ZServer is not imported anymore in the new wsgischema: https://github.com/zopefoundation/Zope/blob/4.6.3/src/Zope2/Startup/wsgischema.xml so the ZConfig data type can not be used to create the server. Instead of relying on ZServer's ZConfig, we create the server directly from the startup script, the logic to attach to waitress is already here and startup and factory just called create, so the only difference is that we no longer use zope.conf to configure TimerService, but configure from the script. SlapOS profile also needs to be modified in order to not include ZConfig bits for timerserver and to pass the timerserver interval in the wrapper to this script.
-
- 05 Jan, 2022 3 commits
-
-
Rafael Monnerat authored
-
Rafael Monnerat authored
-
Rafael Monnerat authored
-
- 08 Dec, 2021 1 commit
-
-
Romain Courteaud authored
-
- 31 Aug, 2021 1 commit
-
-
Rafael Monnerat authored
See merge request nexedi/erp5!1485
-
- 27 Aug, 2021 1 commit
-
-
Romain Courteaud authored
These are clone of Computer and Computer Partition, but used for virtual computing devices, unrelated to physical hardware.
-
- 11 Aug, 2021 26 commits
-
-
Cédric Le Ninivin authored
erp5_administration: Add Scripts for Alarm to update validation state according to consistency state
-
Rafael Monnerat authored
If two open orders are validated on the same transaction, archivePrevious script will get the an already archived as catalog will be outdated.
-
Rafael Monnerat authored
-
Rafael Monnerat authored
This allow the administrator define which Login portal types are searched.
-
Rafael Monnerat authored
Also extend tests to cover recently changes
-
Rafael Monnerat authored
This is an alternetive way to login using Certificates. Probably this format will evolve into use caucase; however this only introduce some most basic features. Use Certificate Login for store login definitions
-
Rafael Monnerat authored
Please squash me in future.
-
Rafael Monnerat authored
If the user wants actitivites, it should create multiples StandardBT5ConfiguratorItems, This should accellerate Tests based on ERP5Configurator. This should be recoded, but it should speed up bootstrap of a site, as get modified objects are not called.
-
Rafael Monnerat authored
It the user don't have fully permission on the object (already changed state), this set will fail to check if source should be defined.
-
Alain Takoudjou authored
The upgrade ordering seems buggy and requires to force reinstall it
-
Rafael Monnerat authored
This allow during a subscription process, create a user and them create all documents using that user w/o rely on proxy roles (keeping good ownership across the documents).
-
Rafael Monnerat authored
Without this (on slapos master ui) the redirection places value unquoted causing parser to fail later on when resolve {n.me}
-
Rafael Monnerat authored
-
Rafael Monnerat authored
-
Rafael Monnerat authored
The user can be present from diferent logins, password tool only works with ERP5LoginUserMager users.
-
Alain Takoudjou authored
-
Alain Takoudjou authored
Mixed commit: 43b1ae1bc46b453e4553a9bc1077fe86e5db13bb 2f05fe1b585d3ca736538b32269d36a410f5f7da
-
Łukasz Nowak authored
Returning true allows to add movements to existing one, and this group shall always separate them.
-
Rafael Monnerat authored
-
Romain Courteaud authored
-
Łukasz Nowak authored
Note: Generic code shall have no constraints at all. Conflicts: bt5/erp5_accounting/bt/revision
-
Alain Takoudjou authored
If 2 lines have the same effective date (catalog has a 1 second precision), always return the validate and open first. Commit: 02d06501ce38bc24d5d045968a53017d9b96b312 Changes applied from history: http://git.erp5.org/gitweb/erp5.git/history/refs/heads/interaction-drop:/product/ERP5/Document/SubscriptionItem.py?js=1
-
Rafael Monnerat authored
Original commit from : Lukasz Nowak <luke@nexedi.com> 3e45ec35e38c008b0f8c2ceec73d7bb9dc62e2c0
-
Romain Courteaud authored
Conflicts: bt5/erp5_crm/bt/revision
-
Rafael Monnerat authored
See merge request nexedi/erp5!1480
-
Rafael Monnerat authored
See merge request nexedi/erp5!1479
-
- 10 Aug, 2021 3 commits
-
-
Rafael Monnerat authored
See merge request nexedi/erp5!1477
-
Rafael Monnerat authored
This allow including more items to be ignored, preventing diffs from pure development.
-
Rafael Monnerat authored
Those 2 exceptions are from SlapOS Master codebase, and for now we cannot remove it. Rather them complexify the ignore lists, we are hardcoding the values for minimase the ignore list to the least entries as possible.
-