Salesforce has admitted that they have screwed up their implementation.
Hi Johannes,
My name is XXX, and I'm the Tier 2 Developer Support agent who's taken ownership of this case. Our team is aware of this issue and is currently working to resolve it. As a short-term workaround, can you please try copying your AMPScript from your content blocks and placing it directly in the from name and from email of your sender profile? ...
Thank you,
XXX XXX
Success Agent - Tier 2
Salesforce Technical Support
So for all that use the configuration like I have described in my question, it will create this error.
Solution is not like stated in the comment from support:
- Post your complete ampscript into the fromname and fromemail of the sender profile
- (testing right now)
%%[ContentBlockByKey("sender-profile")]%%%%=v(@fromEmail)=%%
- Deleting the
%%=v(@fromEmail)=%%
from the ampscript itself
Posting your complete ampscript into the fromname and fromemail of the sender profile will cause errors when you try to save it into the sender profile. Atleast for me.