Attached the logs under gunicorn and flask.
## The logging under gunicorn ##
(venv) stanley@stanley-ThinkPad-T490:~/Desktop/Git_Repos/oem-qa-autosummary$ gunicorn -w 2 -b 0.0.0.0:8080 -t 120 webapp:app
[2021-06-22 10:16:59 +0800] [16505] [INFO] Starting gunicorn 20.1.0
[2021-06-22 10:16:59 +0800] [16505] [INFO] Listening at: http://0.0.0.0:8080 (16505)
[2021-06-22 10:16:59 +0800] [16505] [INFO] Using worker: sync
[2021-06-22 10:16:59 +0800] [16507] [INFO] Booting worker with pid: 16507
[2021-06-22 10:16:59 +0800] [16508] [INFO] Booting worker with pid: 16508
[2021-06-22T10:16:59] [summary.py/MailContentNotFoundError] [ERROR] the mail.content file is not found on the WebDAV server
[2021-06-22T10:16:59] [summary.py/Sha256FileNotFoundError] [ERROR] sha256sum file for a given image is not found on the WebDAV server
[2021-06-22T10:16:59] [summary.py/MailContentNotFoundError] [ERROR] the mail.content file is not found on the WebDAV server
[2021-06-22T10:16:59] [summary.py/Sha256FileNotFoundError] [ERROR] sha256sum file for a given image is not found on the WebDAV server
[2021-06-22T10:17:17] [__init__.py/index] [INFO] Route to index page, method: GET
[2021-06-22T10:17:17] [__init__.py/index] [DEBUG] selected_project:
[2021-06-22T10:17:26] [__init__.py/index] [INFO] Route to index page, method: POST
[2021-06-22T10:17:33] [__init__.py/index] [DEBUG] selected_project: sutton
[2021-06-22T10:17:50] [__init__.py/generate_summary] [INFO] Route to summary page
[2021-06-22T10:17:50] [summary.py/__init__] [INFO] Summary object initailizing
[2021-06-22T10:17:50] [summary.py/__init__] [DEBUG] Prepare launchpad API for sutton - p350-tr-sff-alpha
[2021-06-22T10:17:51] [summary.py/__init__] [DEBUG] Prepare WEBDAV API with sutton
[2021-06-22T10:17:51] [summary.py/get_image_info_from_mail_content] [INFO] Try to get mail.content file from WebDAV server. URI: /share/sutton/bachman/p350-tr-sff-alpha/mail.content
[2021-06-22T10:17:55] [summary.py/get_image_info_from_mail_content] [DEBUG] Image: pc-sutton-bachman-focal-amd64-X00-20210601-872.iso, SHA256: e10a62404d8350a4927c2d693d2cf4ae99520e40460da58e3c471ba0c2088718
[2021-06-22T10:17:55] [summary.py/get_new_bugs] [INFO] Collecting new bugs
[2021-06-22T10:17:56] [summary.py/get_new_bugs] [DEBUG] Search bugs from 2021-06-01 00:00:00 to 2021-06-22 10:16:59.275233 for sutton project
[2021-06-22T10:17:57] [summary.py/get_new_bugs] [DEBUG] 47 bugs found, analysing
[2021-06-22T10:17:57] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930543 bug
[2021-06-22T10:18:01] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930786 bug
[2021-06-22T10:18:04] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930789 bug
[2021-06-22T10:18:06] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930791 bug
[2021-06-22T10:18:09] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930793 bug
## The logging under flask ##
(venv) stanley@stanley-ThinkPad-T490:~/Desktop/Git_Repos/oem-qa-autosummary$ flask run
* Serving Flask app 'webapp' (lazy loading)
* Environment: development
* Debug mode: on
[2021-06-22T10:19:18] [summary.py/MailContentNotFoundError] [ERROR] the mail.content file is not found on the WebDAV server
[2021-06-22T10:19:18] [summary.py/Sha256FileNotFoundError] [ERROR] sha256sum file for a given image is not found on the WebDAV server
[2021-06-22T10:19:22] [_internal.py/_log] [INFO] * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
[2021-06-22T10:19:22] [_internal.py/_log] [INFO] * Restarting with stat
* Debugger is active!
* Debugger PIN: 143-224-034
[2021-06-22T10:19:22] [summary.py/MailContentNotFoundError] [ERROR] the mail.content file is not found on the WebDAV server
[2021-06-22T10:19:22] [summary.py/Sha256FileNotFoundError] [ERROR] sha256sum file for a given image is not found on the WebDAV server
[2021-06-22T10:19:40] [__init__.py/index] [INFO] Route to index page, method: GET
[2021-06-22T10:19:40] [__init__.py/index] [DEBUG] selected_project:
[2021-06-22T10:19:47] [__init__.py/index] [INFO] Route to index page, method: POST
[2021-06-22T10:19:54] [__init__.py/index] [DEBUG] selected_project: sutton
[2021-06-22T10:20:12] [__init__.py/generate_summary] [INFO] Route to summary page
[2021-06-22T10:20:12] [summary.py/__init__] [INFO] Summary object initailizing
[2021-06-22T10:20:12] [summary.py/__init__] [DEBUG] Prepare launchpad API for sutton - p350-tr-sff-alpha
[2021-06-22T10:20:14] [summary.py/__init__] [DEBUG] Prepare WEBDAV API with sutton
[2021-06-22T10:20:14] [summary.py/get_image_info_from_mail_content] [INFO] Try to get mail.content file from WebDAV server. URI: /share/sutton/bachman/p350-tr-sff-alpha/mail.content
[2021-06-22T10:20:18] [summary.py/get_image_info_from_mail_content] [DEBUG] Image: pc-sutton-bachman-focal-amd64-X00-20210601-872.iso, SHA256: e10a62404d8350a4927c2d693d2cf4ae99520e40460da58e3c471ba0c2088718
[2021-06-22T10:20:18] [summary.py/get_new_bugs] [INFO] Collecting new bugs
[2021-06-22T10:20:18] [summary.py/get_new_bugs] [DEBUG] Search bugs from 2021-06-01 00:00:00 to 2021-06-22 10:19:22.523878 for sutton project
[2021-06-22T10:20:20] [summary.py/get_new_bugs] [DEBUG] 47 bugs found, analysing
[2021-06-22T10:20:20] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930543 bug
[2021-06-22T10:20:25] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930786 bug
[2021-06-22T10:20:27] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930789 bug
[2021-06-22T10:20:30] [summary.py/get_new_bugs] [DEBUG] handle https://api.launchpad.net/devel/sutton/+bug/1930791 bug
Thanks a lot, that will provide much more information that the current situation!
I added a bunch of comments below.
Since we use Python 3.6+, we can use f-strings instead of `.format()` or `%s`, such as:
f"Preparing Launchpad API for {self.project_name} - {self.milestone _name}. .."
Make sure you use this everywhere, cause I think it's easier to read :)
Then, you can amend your last commit (no need to create a new one) and push the update here.