-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Migrate Sentry to 15.0 #2428
Migrate Sentry to 15.0 #2428
Conversation
2 tests are failing, but they are not in |
c5891a8
to
ea5894f
Compare
Failing tests appear to be in
Possibly the policy has changed since the tests were written. There are no errors in the 14.0 branch, I'll see if there are fixes in there. |
There are no changes to @janverb and @NL66278 , you seem to be the ones who introduced one of the tests that is now failing: https://github.com/OCA/server-tools/blob/14.0/letsencrypt/tests/test_letsencrypt.py#L79 Do either of you have an idea of what might be going wrong here? Judging by the error, it almost seems like we're getting a response from actual LetsEncrypt, despite it seeming like we're mocking things pretty thoroughly. This is the traceback I'm seeing in the test logs:
I couldn't see any obvious recent changes to the |
Ah, you had already come to the same conclusion I see. |
/ocabot rebase |
Sorry @NL66278 you are not allowed to rebase. 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 |
@aisopuro Please rebase your branch on latest 15.0. This now contains a fix by @StefanRijnhart that should solve the letsencrypt problems. |
* [ADD] sentry module * [FIX] updated sentry module according to PR comments
- [FIX] sentry: fixes missing `raven` library preventing loading of modules - [FIX] 2to3 script on py file - [FIX] add requirements.txt
sentry: It is not always possible to read commit information from a production environment. In those cases it is useful to be able to set a release version manually. [UPD] Update sentry.pot
[UPD] Update sentry.pot
because OCA/maintainer-tools#459 [UPD] Update sentry.pot
fix OCA/maintainer-tools#459 OCA#1776 (comment) Credits sbidoul [UPD] README.rst
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: server-tools-14.0/server-tools-14.0-sentry Translate-URL: https://translation.odoo-community.org/projects/server-tools-14-0/server-tools-14-0-sentry/
The following warning is fixed: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.9 it will stop working
Allow using `sentry_release` or `sentry_odoo_dir` in the Odoo configuration file. Previously, the `sentry_odoo_dir` was never actually respected. It would always be overridden by `sentry_release`. Even if `sentry_release` is not set, it will use an empty value instead of using `sentry_odoo_dir` to find the Git commit hash. After this commit, the `sentry_release` parameter still takes precedence. However, if `sentry_release` is not set and `sentry_odoo_dir` is set, then `sentry_odoo_dir` will be used to find the appropriate Git commit hash, which will be used as the `release` value. Both cases are covered by the added unit tests.
Because post_load is called after odoo.service.server start It has already registered the unpatched odoo.service.wsgi_server.application So patch it here too. This enables wsgi performance reporting with sentry_traces_sample_rate
The test code uses a "mock" Transport object to ensure that events are stored locally in memory, instead of triggering network requests. The Sentry client is cleaned up once done, and this triggers a call to capture_envelope, a different way of sending events to Sentry. Since our mock class did not fully complete initialization, and also did not provide an overriding method, the original was called, which depends on proper initialization to work. We introduce an override for capture_envelope: as it is meant to be a "sibling" to capture_event, it makes sense for us to also make sure events registrered in this way are intercepted, even if we don't currently expect any of our tests to explicitly cause it to be used.
ea5894f
to
ced4efc
Compare
Rebased and pushed, thanks for the help @NL66278 |
This PR has the |
/ocabot merge nobump |
This PR looks fantastic, let's merge it! |
Congratulations, your PR was merged at ca8af23. Thanks a lot for contributing to OCA. ❤️ |
This PR replaces #2386:
14.0
in order to include the recently merged switch to usingsentry_sdk
instead ofraven
.14.0
, and so those commits are not necessary in this PR.