mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-08-26 12:46:08 +00:00
app: Update diagnose() docstring
Signed-off-by: James Valleroy <jvalleroy@mailbox.org> [sunil: Add reference documentation for the DiagnosticCheck and Result classes] [sunil: Add link to DiagnosticCheck class from docstring] Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
520ce34e7c
commit
2a8b9b94ba
@ -33,3 +33,12 @@ Base Classes
|
|||||||
|
|
||||||
.. autoclass:: plinth.app.FollowerComponent
|
.. autoclass:: plinth.app.FollowerComponent
|
||||||
:members:
|
:members:
|
||||||
|
|
||||||
|
Other Classes
|
||||||
|
^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
.. autoclass:: plinth.modules.diagnostics.check.DiagnosticCheck
|
||||||
|
:members:
|
||||||
|
|
||||||
|
.. autoclass:: plinth.modules.diagnostics.check.Result
|
||||||
|
:members:
|
||||||
|
|||||||
@ -211,10 +211,11 @@ class App:
|
|||||||
def diagnose(self):
|
def diagnose(self):
|
||||||
"""Run diagnostics and return results.
|
"""Run diagnostics and return results.
|
||||||
|
|
||||||
Return value must be a list of results. Each result is a two-tuple with
|
Return value must be a list of results. Each result is a
|
||||||
first value as user visible description of the test followed by the
|
:class:`~plinth.modules.diagnostics.check.DiagnosticCheck` with a
|
||||||
|
unique check_id, a user visible description of the test, and the
|
||||||
result. The test result is a string enumeration from 'failed',
|
result. The test result is a string enumeration from 'failed',
|
||||||
'passed', 'error' and 'warning'.
|
'passed', 'error', 'warning' and 'not_done'.
|
||||||
|
|
||||||
Results are typically collected by diagnosing each component of the app
|
Results are typically collected by diagnosing each component of the app
|
||||||
and then supplementing the results with any app level diagnostic tests.
|
and then supplementing the results with any app level diagnostic tests.
|
||||||
@ -303,10 +304,11 @@ class Component:
|
|||||||
def diagnose():
|
def diagnose():
|
||||||
"""Run diagnostics and return results.
|
"""Run diagnostics and return results.
|
||||||
|
|
||||||
Return value must be a list of results. Each result is a two-tuple with
|
Return value must be a list of results. Each result is a
|
||||||
first value as user visible description of the test followed by the
|
:class:`~plinth.modules.diagnostics.check.DiagnosticCheck` with a
|
||||||
result. The test result is a string enumeration from 'failed', 'passed'
|
unique check_id, a user visible description of the test, and the
|
||||||
and 'error'.
|
result. The test result is a string enumeration from 'failed',
|
||||||
|
'passed', 'error', 'warning' and 'not_done'.
|
||||||
|
|
||||||
Also see :meth:`.has_diagnostics`.
|
Also see :meth:`.has_diagnostics`.
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user