You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Adobe CF (2023 + 2025): cfheader(attributeCollection) throws 'Failed to add HTML header' — blocks all tests #2741
On Adobe ColdFusion 2023, every request to the test endpoint (and likely every Wheels request in general) fails with:
Failed to add HTML header.
ColdFusion was unable to add the header you specified to the output stream. This is probably because you have already used a cfflush tag in your template or buffered output is turned off.
The error occurred in /wheels-test-suite/vendor/wheels/Global.cfc: line 123
Called from /wheels-test-suite/vendor/wheels/events/EventMethods.cfc: line 113
Called from /wheels-test-suite/vendor/wheels/Global.cfc: line 248
Called from /wheels-test-suite/vendor/wheels/Global.cfc: line 41
Called from /wheels-test-suite/public/Application.cfc: line 308
121 : cfheader(attributeCollection = "#local.args#");
122 : } else {
123 : cfheader(attributeCollection = "#arguments#");
124 : }
The compat-matrix Adobe 2023 job records 0 pass / 0 fail / 0 err because no test request gets past application boot — every spec file's HTTP request returns the Wheels error HTML page rather than the test results JSON.
Reproduction
Run tools/test-matrix.sh adobe2023 mysql (any DB)
Watch every result fail JSON parsing — the body is the Wheels error page
Or: curl http://localhost:62023/wheels/core/tests?db=mysql — same error
Evidence
Compat-matrix run 25978222394 (develop, 2026-05-17). Adobe 2023 artifact (test-results-adobe2023) contains HTML for every DB.
Suspected cause
The cfheader(attributeCollection = "#arguments#") call at vendor/wheels/Global.cfc:123 — passing arguments directly. Adobe 2023 likely rejects this shape (maybe expects a struct rather than the arguments scope, or stricter validation than Lucee/BoxLang/Adobe 2021).
The call site is on the dispatch path (EventMethods.cfc:113 → Global.cfc:248 → Global.cfc:41), so every controller action hits it. Lucee 6/7 and BoxLang pass through without issue.
Expected behavior
cfheader(attributeCollection=…) should work cross-engine. Either the call shape needs adjustment for Adobe 2023, or the helper needs to bridge arguments to a plain struct before calling cfheader.
Pending: confirm Adobe 2025 status
The same run's adobe2025 job was still in progress at filing time. If 2025 hits the same regression, this issue covers both versions.
controller — see .ai/wheels/controllers/ for canonical patterns, and .ai/wheels/cross-engine-compatibility.md for the Adobe-CF-specific gotchas that apply here. The defect is in the global $header helper that controllers and the dispatch path call to emit HTTP response headers.
Fix sketch
vendor/wheels/Global.cfc:112-125 — the $header() function calls cfheader(attributeCollection = "#arguments#"), passing the arguments scope directly. Adobe CF 2023 rejects this shape (Lucee 6/7 and BoxLang accept it). The same function already has the pattern needed for the fix: the statusText branch above copies arguments into a plain local.args struct before calling cfheader. Apply that same copy unconditionally so every call path hands cfheader a plain struct, not the arguments scope. One file, no API change, no caller updates. Verify on Adobe 2023 via tools/test-matrix.sh adobe2023 sqlite (and re-check Adobe 2025 once that job finishes — the issue body flags it as pending).
Confidence: medium
Report and fix location are unambiguous and the shape is mechanical, but cross-engine concern (Adobe-vs-Lucee-vs-BoxLang cfheader parsing) fires the auto-downgrade rule — at most medium.
Spec: vendor/wheels/tests/specs/global/headerSpec.cfc — covers name/value, statuscode, charset, and statuscode+statusText call shapes. Passes locally on Lucee 7 both before and after the fix (Lucee already accepts the arguments scope), so it documents the cross-engine contract; the failure manifests on Adobe 2023 only and will be verified by the compat-matrix job once the PR runs CI.
Implementation: vendor/wheels/Global.cfc — $header() now copies the arguments scope into a plain struct (and strips statusText for Adobe CF 2025 compatibility) before invoking cfheader(attributeCollection=...), collapsing the previous two-branch shape into one uniform code path.
A human review is required before merge. Reviewer A and Reviewer B will weigh in shortly. Doc updates (MDX guides, .ai/wheels/, CLAUDE.md) are handled separately by bot-update-docs.yml.
The Adobe 2025 job from run 25978222394 finished after this issue was filed. Confirmed: Adobe 2025 hits the exact samecfheader(attributeCollection) failure at vendor/wheels/Global.cfc:123 on every DB (cockroachdb, mysql, oracle, postgres, sqlite, sqlserver — all return the Wheels error HTML page).
So both Adobe 2023 and Adobe 2025 are wholesale blocked by this regression. Scope of this issue should be read as "Adobe ColdFusion (2023 + 2025)" rather than 2023-only.
changed the title [-]Adobe 2023: cfheader(attributeCollection) throws 'Failed to add HTML header' — blocks all tests[/-][+]Adobe CF (2023 + 2025): cfheader(attributeCollection) throws 'Failed to add HTML header' — blocks all tests[/+]on May 18, 2026
Activity
wheels-bot commentedon May 17, 2026
Wheels Bot — Triage
Classified as bug.
Suspected layer
controller— see.ai/wheels/controllers/for canonical patterns, and.ai/wheels/cross-engine-compatibility.mdfor the Adobe-CF-specific gotchas that apply here. The defect is in the global$headerhelper that controllers and the dispatch path call to emit HTTP response headers.Fix sketch
vendor/wheels/Global.cfc:112-125— the$header()function callscfheader(attributeCollection = "#arguments#"), passing theargumentsscope directly. Adobe CF 2023 rejects this shape (Lucee 6/7 and BoxLang accept it). The same function already has the pattern needed for the fix: thestatusTextbranch above copiesargumentsinto a plainlocal.argsstruct before callingcfheader. Apply that same copy unconditionally so every call path handscfheadera plain struct, not theargumentsscope. One file, no API change, no caller updates. Verify on Adobe 2023 viatools/test-matrix.sh adobe2023 sqlite(and re-check Adobe 2025 once that job finishes — the issue body flags it as pending).Confidence:
mediumReport and fix location are unambiguous and the shape is mechanical, but cross-engine concern (Adobe-vs-Lucee-vs-BoxLang
cfheaderparsing) fires the auto-downgrade rule — at mostmedium.<!-- wheels-bot:triage:2741 -->
<!-- wheels-bot:triage-class:bug -->
<!-- wheels-bot:triage-confidence:medium -->
wheels-bot commentedon May 17, 2026
Wheels Bot — Fix proposed
Draft PR: #2751
Spec:
vendor/wheels/tests/specs/global/headerSpec.cfc— covers name/value, statuscode, charset, and statuscode+statusText call shapes. Passes locally on Lucee 7 both before and after the fix (Lucee already accepts theargumentsscope), so it documents the cross-engine contract; the failure manifests on Adobe 2023 only and will be verified by the compat-matrix job once the PR runs CI.Implementation:
vendor/wheels/Global.cfc—$header()now copies theargumentsscope into a plain struct (and stripsstatusTextfor Adobe CF 2025 compatibility) before invokingcfheader(attributeCollection=...), collapsing the previous two-branch shape into one uniform code path.A human review is required before merge. Reviewer A and Reviewer B will weigh in shortly. Doc updates (MDX guides,
.ai/wheels/,CLAUDE.md) are handled separately bybot-update-docs.yml.docs: document attributeCollection + arguments scope gotcha on Adobe …
docs: document attributeCollection + arguments scope gotcha on Adobe …
docs: document attributeCollection + arguments scope gotcha on Adobe …
bpamiri commentedon May 18, 2026
Adobe 2025 update — same regression
The Adobe 2025 job from run 25978222394 finished after this issue was filed. Confirmed: Adobe 2025 hits the exact same
cfheader(attributeCollection)failure atvendor/wheels/Global.cfc:123on every DB (cockroachdb, mysql, oracle, postgres, sqlite, sqlserver — all return the Wheels error HTML page).So both Adobe 2023 and Adobe 2025 are wholesale blocked by this regression. Scope of this issue should be read as "Adobe ColdFusion (2023 + 2025)" rather than 2023-only.
[-]Adobe 2023: cfheader(attributeCollection) throws 'Failed to add HTML header' — blocks all tests[/-][+]Adobe CF (2023 + 2025): cfheader(attributeCollection) throws 'Failed to add HTML header' — blocks all tests[/+]fix(dispatch): copy arguments to a plain struct in $header() for Adob…