Knowledge base

PMTA knowledge baseβ€ΊBlock <signals>β€ΊDirectiveΒ§ 11.1.6.2.10

html-edit-error-mode

<signals>

What to do if a message could not be parsed for substitution
in the configuration this is a linehtml-edit-error-mode perm-failinside the block <signals>
The cost of a failed substitution

To insert links and pixels, the engine parses the message’s HTML. Parsing can fail β€” and the line decides what happens then. The default is perm-fail.

πŸ”΄ The default means refusing delivery. A message whose HTML the engine could not handle will be bounced as a failed transfer β€” that is, it will not reach the recipient at all. Because of tracking.

The second value is deliver-unmodified: the error is ignored and the message goes out as is, without inserted links. There will be no tracking for it, but there will be delivery.

It is written to the log in both cases.

The choice here is simple in meaning: what is more valuable β€” delivering the message or complete statistics. For campaigns the answer is almost always β€œdelivery.”

The main trap is leaving the default without knowing it. Messages with non-standard markup β€” from someone else’s editor, with unexpected tags β€” will start bouncing, and in the bounces this will look like a transfer error rather than a parsing error.
What the Hub does. It does not write it β€” and does not intend to: substituting someone else’s links into our messages would mean recipients’ clicks going through the vendor’s domain.
Recommended values

The choice here is short:

Value When
perm-fail (default) statistics matter more than delivery β€” almost never
deliver-unmodified delivery matters more than complete tracking
Both values, the perm-fail default and logging the error in both cases come from the manual (Β§ 11.1.6.2.10).
Example configuration
# delivery matters more than complete statistics
<signals>
    engagement-tracking sparkpost
    html-edit-error-mode deliver-unmodified</signals>
With the default, a message with unfamiliar markup will not reach the recipient at all.
yellow β€” β€” directive names, blue β€” blocks. They are highlighted the same way in the text of the card.
β–²

Common mistakes and problems

what people get wrong and how it ends2 mistakesβ–Ά

Leaving the default for campaigns from different editors

our experience

What it costsMessages with non-standard markup bounce as failed transfers. In statistics this looks like a delivery error, while the cause is link substitution.
How to spot itSome campaigns produce bounces with no clear reason at the receiving server.
How to do it rightSet deliver-unmodified and watch parsing errors in the log.

Expecting the line to work with substitution turned off

Β§ 11.1.6.2.10

What it costsThe substitution lines work only with engagement-tracking set to sparkpost. With other values they do nothing.
How to spot itThe line is set, and nothing in the messages has changed.
How to do it rightCheck the value of engagement-tracking.
Compatibility
PowerMTA 6.0
described in the manual of this version Β· platform: any
The vendor does not state the first version for every directive β€” there is no note here. The name also appears in the 5.0 edition of the manual.
Reference data
Syntax
html-edit-error-mode { perm-fail | deliver-unmodified }
Values
perm-fail | deliver-unmodified
Default
perm-fail Β§ 11.1.6.2.10
Applying
reload, no restart needed
Queue
will not touch what is already queued
Where to write it
<signals>
How many times
once in the block
Everything here comes from the manual, with the section.
Inheritance
There is no inheritance: the line lives inside <signals>, and there is one such block per node. The scope of export by stream is set by the enable-signals line with three levels.
How to check on the node
The result is visible in the message itself β€” check it in a delivered one:
grep -i "signals\|html" /var/log/pmta/log | tail -20
It is more reliable to look at a message that reached the seed mailbox: the links and pixels are either in it or not.
In the Hub
Cost of a mistake
dangerous: effects outlast a rollback
Scenarios
Bounce classification Β· Tracking infrastructure