Skip to content

fix: header callbacks merge instead of overwriting#78

Merged
ionut-mihalache-uipath merged 1 commit into
mainfrom
fix/merge-headers
May 13, 2026
Merged

fix: header callbacks merge instead of overwriting#78
ionut-mihalache-uipath merged 1 commit into
mainfrom
fix/merge-headers

Conversation

@andreiancuta-uipath
Copy link
Copy Markdown
Contributor

@andreiancuta-uipath andreiancuta-uipath commented May 13, 2026

Previously, when adding two header callbacks to the client, the second one's returned headers would overwrite the ContextVar and clear the first callback's headers.
Now, each callback's results are merged into the existing headers. Only on_llm_end/error clear the contextvar.

@ionut-mihalache-uipath ionut-mihalache-uipath merged commit 670f122 into main May 13, 2026
7 checks passed
@ionut-mihalache-uipath ionut-mihalache-uipath deleted the fix/merge-headers branch May 13, 2026 10:17
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.

2 participants