#3907 Add more logging to the pagure_logcom service
Merged 5 years ago by pingou. Opened 5 years ago by pingou.

file modified
+8 -1
@@ -205,9 +205,16 @@ 

      log_all = pagure_config.get("LOG_ALL_COMMITS", False)

      if log_all or branch == default_branch:

          pagure.lib.git.log_commits_to_db(session, project, commits, abspath)

+     else:

+         _log.info(

+             "Not logging commits not made on the default branch: %s",

+             default_branch

+         )

  

      # Notify subscribed users that there are new commits

-     if pagure_config.get("EMAIL_ON_WATCHCOMMITS", True):

+     email_watchcommits = pagure_config.get("EMAIL_ON_WATCHCOMMITS", True)

+     _log.info("Sending notification about the commit: %s", email_watchcommits)

+     if email_watchcommits:

          pagure.lib.notify.notify_new_commits(abspath, project, branch, commits)

  

      try:

Signed-off-by: Pierre-Yves Chibon pingou@pingoured.fr

rebased onto f38c1a57cf8b1efd2f572e9baae4df0f694a2f35

5 years ago

rebased onto f38c1a57cf8b1efd2f572e9baae4df0f694a2f35

5 years ago

rebased onto 70c1a2ebd7db169395659fb0e652d5945e349424

5 years ago

rebased onto 70c1a2ebd7db169395659fb0e652d5945e349424

5 years ago

rebased onto 0ac4b33

5 years ago

Thanks for the review :)

Pull-Request has been merged by pingou

5 years ago