deprecate having only localparts in an Account's Destinations, it should always be a full email address

current behaviour isn't intuitive. it's not great to have to attempt parsing
the strings as both localpart and email address. so we deprecate the
localpart-only behaviour. when we load the config file, and it has
localpart-only Destinations keys, we'll change them to full addresses in
memory. when an admin causes a write of domains.conf, it'll automatically be
fixed. we log an error with a deprecated notice for each localpart-only
destinations key.

sometime in the future, we can remove the old localpart-only destination
support. will be in the release notes then.

also start keeping track of update notes that need to make it in the release
notes of the next release.

for issue #18
This commit is contained in:
Mechiel Lukkien
2023-03-09 22:07:37 +01:00
parent 5742ed1537
commit 2c07645ab4
20 changed files with 57 additions and 41 deletions

View File

@ -436,15 +436,16 @@ describe-static" and "mox config describe-domains":
Accounts:
x:
# Default domain for addresses specified in Destinations. An address can specify a
# domain override.
# Default domain for account. Deprecated behaviour: If a destination is not a full
# address but only a localpart, this domain is added to form a full address.
Domain:
# Free form description, e.g. full name or alternative contact info. (optional)
Description:
# Destinations, specified as (encoded) localpart for Domain, or a full address
# including domain override.
# Destinations, keys are email addresses (with IDNA domains). Deprecated
# behaviour: If the address is not a full address but a localpart, it is combined
# with Domain to form a full address.
Destinations:
x: