Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix KV data for postfix/local #189

Merged
merged 2 commits into from
Feb 2, 2024
Merged

Conversation

ulab
Copy link
Contributor

@ulab ulab commented Jan 29, 2024

The postfix_keyvalue_data that was generated by POSTFIX_LOCAL contained a string that could not be parsed as KV because it contained parts split by spaces that did not contain the = character:

...status=sent (delivered to command: procmail...

This PR changes it to use %{POSTFIX_SMTP_DELIVERY} instead which results in the correct format plus postfix_status and postfix_smtp_response fields.

While I am not sure if postfix_smtp_response is the correct name for a local transport, it is also used for POSTFIX_VIRTUAL and has the same meaning as in POSTFIX_SMTP.

@whyscream
Copy link
Owner

whyscream commented Jan 29, 2024

Hi @ulab,

I added a commit that copies the POSTFIX_SMTP_DELIVERY pattern and altered the pattern name. Maybe the same should be done for virtual, but we don't need to fix that here. What do you think?

@ulab
Copy link
Contributor Author

ulab commented Jan 30, 2024

I am "indifferent" 😉. On one hand it makes sense to use a different name for a different service message, on the other hand they have the same reason behind them.

But using a different name by default allows people to rename the field into a shared one with additional filters if they want to.

@whyscream whyscream merged commit e0e8cf5 into whyscream:main Feb 2, 2024
@ulab ulab deleted the fix_local_kv branch February 2, 2024 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants