-
-
Notifications
You must be signed in to change notification settings - Fork 169
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
[IMP] update_module_names: Add merge option #63
[IMP] update_module_names: Add merge option #63
Conversation
cc @Tecnativa |
Travis error unrelated |
@moylop260, do you have any tip why this fails? |
Maybe is a flake8-3.2.1 error flake8 OCA/openupgradelib
Traceback (most recent call last):
File "flake8", line 11, in <module>
sys.exit(main())
File "flake8/main/cli.py", line 16, in main
app.run(argv)
File "flake8/main/application.py", line 322, in run
self._run(argv)
File "flake8/main/application.py", line 306, in _run
self.run_checks()
File "flake8/main/application.py", line 243, in run_checks
self.file_checker_manager.start(files)
File "/flake8/checker.py", line 371, in start
self.make_checkers(paths)
File "/flake8/checker.py", line 285, in make_checkers
if argument == filename or should_create_file_checker(filename)
File "/flake8/checker.py", line 412, in __init__
self.display_name = self.processor.filename
AttributeError: 'NoneType' object has no attribute 'filename' |
It could be related with https://gitlab.com/pycqa/flake8/issues/272 |
It seems so. Thanks for the info. Is in our hands to repair it? |
Options
|
OK, I think we should choose option 2, isn't it? We did the same on MQT if I don't remember bad. |
This project is not using MQT |
Yeah, I know, that's why I tell to do the same. |
We have freeze pylint version from pylint-odoo but flake8 is not freeze |
FYI using
openupgradelib/openupgrade_tools.py:31:1: E302 expected 2 blank lines, found 1
openupgradelib/openupgrade.py:101:5: F811 redefinition of unused 'RegistryManager' from line 58 |
d75099a
to
29b22a5
Compare
what do you think about having a new function to merge module A into B instead? This way, we can account for situations where multiple modules are replaced by another one, and the execution path will be a lot less complicated |
I preferred to use the same method for not duplicating code. You can still perform the merge of multiple modules into one:
|
29b22a5
to
291963e
Compare
With these minimal changes, we allow to reallocate all the resources related to a module that has been merged into others in later versions. For example, email_template in version 8 that has been integrated in mail module in version 9.
291963e
to
181c1cb
Compare
As we have already tested this feature and need it for a lot of current PRs, I concede myself the luxury of merging it. |
With these minimal changes, we allow to reallocate all the resources related to a module that has been merged into others in later versions. For example, email_template in version 8 that has been integrated in mail module in version 9.