Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
github: Use logging.exception so we know which exception happened.
Alex Vandiverfc9e5f5187ce
diff --git a/zerver/lib/github.py b/zerver/lib/github.pyindex 226a6949e88..567b890c0a4 100644--- a/zerver/lib/github.py+++ b/zerver/lib/github.py@@ -13,7 +13,9 @@ def get_latest_github_release_version_for_repo(repo: str) -> str:try:return requests.get(api_url).json()["tag_name"]except (requests.RequestException, json.JSONDecodeError, KeyError):- logger.error("Unable to fetch the latest release version from GitHub %s", api_url)+ logger.exception(+ "Unable to fetch the latest release version from GitHub %s", api_url, stack_info=True+ )return ""diff --git a/zerver/tests/test_github.py b/zerver/tests/test_github.pyindex 5d4c3a7366f..2519a25def6 100644--- a/zerver/tests/test_github.py+++ b/zerver/tests/test_github.py@@ -56,11 +56,9 @@ class GitHubTestCase(ZulipTestCase):get_latest_github_release_download_link_for_platform("windows"),"https://github.com/zulip/zulip-desktop/releases/latest",)- self.assertEqual(- error_log.output,- [- f"ERROR:{logger_string}:Unable to fetch the latest release version from GitHub {api_url}"- ],+ self.assertIn(+ f"ERROR:{logger_string}:Unable to fetch the latest release version from GitHub {api_url}",+ error_log.output[0],)responses.replace(