ted
(Ted Johansson)
6 سبتمبر 2024، 8:56ص
9
من المرجح جدًا أن يحدث هذا بسبب وجود متعقب لفحص المشكلات ولكنه لم يعد منطق فحص المشكلة موجودًا. الطريقة الأكثر احتمالاً لحدوث ذلك هي تثبيت إضافة تحتوي على فحص مشكلة ثم إلغاء تثبيتها. سيظل المتعقب موجودًا، ولكن منطق الفحص مفقود.
لدي إصلاح لهذا هنا:
main ← dev/clear-trackers-for-uninstalled-checks
opened 07:52AM - 06 Sep 24 UTC
### What is this change?
When running checks, we look to the existing problem… check trackers and try to grab their `ProblemCheck` classes.
In some cases this is no longer in the problem check repository, e.g. when the check was part of a plugin that has been uninstalled.
In the case where the check was scheduled, this would lead to an error in one of the jobs.
### How does this fix it?
This fix has two parts:
1. If a problem check tracker can't find it's `ProblemCheck` class, it destroys itself and any admin notices associated with it. It then returns `nil`.
2. The job that selects which checks to run now accounts for the fact that the `ProblemCheck` class could be `nil`, and filters it out of the run.
Bonus:
- Scheduled checks now honour the `enabled = false` configuration, same as realtime checks.
إعجابَين (2)