mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
No need to display this message in webadmin (we're already on the diagnosis script when this happens ...) + in CLI we want to have it as a warning so that it's displayed in cron email
This commit is contained in:
parent
301ced9d6e
commit
e880e775c1
2 changed files with 3 additions and 7 deletions
|
@ -143,8 +143,7 @@
|
||||||
"diagnosis_basesystem_ynh_single_version": "{package} version: {version} ({repo})",
|
"diagnosis_basesystem_ynh_single_version": "{package} version: {version} ({repo})",
|
||||||
"diagnosis_basesystem_ynh_main_version": "Server is running YunoHost {main_version} ({repo})",
|
"diagnosis_basesystem_ynh_main_version": "Server is running YunoHost {main_version} ({repo})",
|
||||||
"diagnosis_basesystem_ynh_inconsistent_versions": "You are running inconsistent versions of the YunoHost packages... most probably because of a failed or partial upgrade.",
|
"diagnosis_basesystem_ynh_inconsistent_versions": "You are running inconsistent versions of the YunoHost packages... most probably because of a failed or partial upgrade.",
|
||||||
"diagnosis_display_tip_web": "You can go to the Diagnosis section (in the home screen) to see the issues found.",
|
"diagnosis_display_tip": "To see the issues found, you can go to the Diagnosis section of the webadmin, or run 'yunohost diagnosis show --issues' from the command-line.",
|
||||||
"diagnosis_display_tip_cli": "You can run 'yunohost diagnosis show --issues' to display the issues found.",
|
|
||||||
"diagnosis_failed_for_category": "Diagnosis failed for category '{category}': {error}",
|
"diagnosis_failed_for_category": "Diagnosis failed for category '{category}': {error}",
|
||||||
"diagnosis_cache_still_valid": "(Cache still valid for {category} diagnosis. Not re-diagnosing yet!)",
|
"diagnosis_cache_still_valid": "(Cache still valid for {category} diagnosis. Not re-diagnosing yet!)",
|
||||||
"diagnosis_cant_run_because_of_dep": "Can't run diagnosis for {category} while there are important issues related to {dep}.",
|
"diagnosis_cant_run_because_of_dep": "Can't run diagnosis for {category} while there are important issues related to {dep}.",
|
||||||
|
|
|
@ -180,11 +180,8 @@ def diagnosis_run(categories=[], force=False, except_if_never_ran_yet=False):
|
||||||
if report != {}:
|
if report != {}:
|
||||||
issues.extend([item for item in report["items"] if item["status"] in ["WARNING", "ERROR"]])
|
issues.extend([item for item in report["items"] if item["status"] in ["WARNING", "ERROR"]])
|
||||||
|
|
||||||
if issues:
|
if issues and msettings.get("interface") == "cli":
|
||||||
if msettings.get("interface") == "api":
|
logger.warning(m18n.n("diagnosis_display_tip"))
|
||||||
logger.info(m18n.n("diagnosis_display_tip_web"))
|
|
||||||
else:
|
|
||||||
logger.info(m18n.n("diagnosis_display_tip_cli"))
|
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue