-
-
Notifications
You must be signed in to change notification settings - Fork 536
[15.0][MIG] base_export_async: Migration to 15.0 #498
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
[15.0][MIG] base_export_async: Migration to 15.0 #498
Conversation
The UI still send it to the current user, but it will allow reusing the module for other purposes: plan a regular export to users. Setting the recipient_ids instead of the email_to in mail.mail means that we can still send the email, it will stay in the failed emails, allowing to correct the user.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: queue-12.0/queue-12.0-base_export_async Translate-URL: https://translation.odoo-community.org/projects/queue-12-0/queue-12-0-base_export_async/
Currently translated at 100.0% (18 of 18 strings) Translation: queue-12.0/queue-12.0-base_export_async Translate-URL: https://translation.odoo-community.org/projects/queue-12-0/queue-12-0-base_export_async/fr/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: queue-12.0/queue-12.0-base_export_async Translate-URL: https://translation.odoo-community.org/projects/queue-12-0/queue-12-0-base_export_async/
Currently translated at 100.0% (18 of 18 strings) Translation: queue-12.0/queue-12.0-base_export_async Translate-URL: https://translation.odoo-community.org/projects/queue-12-0/queue-12-0-base_export_async/da/
Currently translated at 94.4% (17 of 18 strings) Translation: queue-12.0/queue-12.0-base_export_async Translate-URL: https://translation.odoo-community.org/projects/queue-12-0/queue-12-0-base_export_async/pt/
|
I investigated "object unbound" errors a couple weeks ago in the server-auth repository: OCA/server-auth#456 (review). We had to push a mock request onto the stack for testing, i.e. from odoo.http import _request_stack
// in setUp()
_request_stack.push(mock.Mock(
env=self.env,
))
self.addCleanup(_request_stack.pop) |
ed7c183 to
024a3cb
Compare
|
@amh-mw Thank you so much for your help 🙏 To be honest, my knowledge on the |
|
No, it doesn't seem quite right to me. When a queue_job worker delegates jobs, it requests a web worker to actually do the work, so I am surprised that there is no request on the stack. I can't spare a lot of time, but let me read through the code real quick and see if I get any ideas. |
|
I've put the finger on the issue: I'm using |
|
Ah, that makes a lot of sense. I think the best course of action forward would be to move the _request_stack.push bandage into queue_job_cron_jobrunner, which would move it into another pull request entirely. That module is marked alpha / non-production anyway and the second issue would be a good design talking point. |
6cbfdd4 to
a82da95
Compare
amh-mw
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand the urge to refactor, but I'm not sure that I agree with behavior changes in a migration commit.
a82da95 to
2eff778
Compare
|
@amh-mw I've moved the email template refactoring into a separate commit, but let me know if it actually should be into a separate PR. The method |
145d12a to
0aff65c
Compare
amh-mw
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. @OCA/tools-maintainers Ready for review and merge.
|
LGTM. @OCA/connector-maintainers Ready for review and merge. Apologies to mistakenly notified tools-maintainers. |
|
Thanks @vincent-cowboy for this PR! I have copied the changes of the automatic test to bypass the object unbound issue to my PR #492 . |
|
@vincent-cowboy After install base_export_async, there is a defect when click on the export all button I fixed it on my PR for 14.0 migration c6b4499. |
0aff65c to
de2283f
Compare
|
@cuongnmtm nice catch and thank you for the heads-up! the change is now included |
de2283f to
4a4ec05
Compare
|
|
|
There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. |
|
LGTM 👍 . @OCA/connector-maintainers Could you merge this PR? |
|
/ocabot migration base_export_async |
|
Sorry @thomaspaulb you are not allowed to merge. To do so you must either have push permissions on the repository, or be a declared maintainer of all modified addons. If you wish to adopt an addon and become it's maintainer, open a pull request to add your GitHub login to the |
|
Sorry @thomaspaulb you are not allowed to mark the addon tobe migrated. To do so you must either have push permissions on the repository, or be a declared maintainer of all modified addons. If you wish to adopt an addon and become it's maintainer, open a pull request to add your GitHub login to the |
|
/ocabot merge nobump |
|
This PR looks fantastic, let's merge it! |
|
Congratulations, your PR was merged at b8e8a11. Thanks a lot for contributing to OCA. ❤️ |

Inspired by #492
Help needed regardingRuntimeError("object unbound")when usingxlsformat: