Drop HTML sample email templates from unpackaged/post - #223
Merged
Merged
Conversation
The two HTML sample templates cannot deploy as unmanaged metadata via
unpackaged/post. They reference the packaged Visualforce component across
a namespace boundary, and the component attribute recipientId is not
access="global". The platform rejects the cross-namespace call:
Cannot use attribute recipientid without global access in a
component/page that is not in the same namespace as the component
Remove:
- Unsubscribe_Contact_Template_HTML.email (+ meta)
- Unsubscribe_Lead_Template_HTML.email (+ meta)
Keep the plain-text sample. Add the CumulusCI namespace token so the
merge field resolves in both managed and unmanaged contexts:
{!Recipient.%%%NAMESPACE%%%Unsubscribe_Url_Plain_Text__c}
With this change the install path deploys clean. HTML sample delivery is
left as a product decision (see follow-up on #217).
DKeatonDC
reviewed
Aug 14, 2026
DKeatonDC
left a comment
Contributor
There was a problem hiding this comment.
These changes make sense and should proceed.
DKeatonDC
approved these changes
Aug 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this does
Removes the two HTML sample email templates from
unpackaged/post/email/Unsubscribe_Link/. Keeps the plain-text sample and fixes its merge field.Why
The new package
Unsubscribe-Link-4delivers sample templates as unmanaged metadata throughunpackaged/post, not inside the package. The two HTML samples cannot deploy this way.The HTML samples call the packaged Visualforce component:
When the sample lands in the subscriber default namespace (
c) and the component stays inUnsubscribeLnk, the call crosses a namespace boundary. The platform then enforces a stricter rule: every attribute passed to a managed component from another namespace must beaccess="global". TherecipientIdattribute is not global, so the deploy fails:This is a consequence of the "deliver samples via unpackaged/post" model, not a template typo. It has been true since the component was first created (checked
release/0.3.0.2); the package model just exposed it.Changes
Remove
Unsubscribe_Contact_Template_HTML.email(+ meta).Remove
Unsubscribe_Lead_Template_HTML.email(+ meta).Keep
Unsubscribe_Lead_Template_Plain_Text.email. Add the CumulusCI namespace token so the merge field resolves in both managed and unmanaged contexts:Verification
Built
1.0.0.1of the new package and ran the same test the beta-test CI job runs after merge (ci_beta: install the managed package, deployunpackaged/post, run Apex tests), pinned to04tKf000000kjbHIAQ, in a fresh scratch org.unfiled$publiccollision.HTML sample follow-up
HTML sample delivery is a product decision, tracked in a follow-up comment on #217. Two options: make the component attribute global and rebuild (a public-API commitment, new version), or ship the HTML sample as copy-paste documentation. This PR does not decide that. It only unblocks the install path.