Author: brane
Date: Tue Jul  8 13:04:26 2025
New Revision: 1927075

URL: http://svn.apache.org/viewvc?rev=1927075&view=rev
Log:
PR #33: Fix a bug in mailer.py caused by improper user of dict.update().

* tools/hook-scripts/mailer/mailer.py
  (Config._prep_groups::repos_params): If there's a match for the
   repository configuration, copy the defaults dict and update it
   in place before returning the new dict.

Patch by: humbedooh

Modified:
    subversion/trunk/tools/hook-scripts/mailer/mailer.py

Modified: subversion/trunk/tools/hook-scripts/mailer/mailer.py
URL: 
http://svn.apache.org/viewvc/subversion/trunk/tools/hook-scripts/mailer/mailer.py?rev=1927075&r1=1927074&r2=1927075&view=diff
==============================================================================
--- subversion/trunk/tools/hook-scripts/mailer/mailer.py (original)
+++ subversion/trunk/tools/hook-scripts/mailer/mailer.py Tue Jul  8 13:04:26 
2025
@@ -1401,7 +1401,8 @@ class Config:
             # Extract key/value pairs from the regex match of this
             # repository, and merge them into the default params.
             # Make sure to copy() to avoid mutation of the argument.
-            return defaults.copy().update(match.groupdict())
+            defaults = defaults.copy()
+            defaults.update(match.groupdict())
 
         # There are no repository-specific key/value params, to add.
         return defaults


Reply via email to