Skip to content

fix(nodejs): accept ZenDecisionContent returned from the loader - #547

Merged
stefan-gorules merged 1 commit into
masterfrom
fix/nodejs-loader-decision-content
Oct 13, 2026
Merged

stefan-gorules merged 1 commit into
masterfrom
fix/nodejs-loader-decision-content

Conversation

@stefan-gorules

Copy link
Copy Markdown
Contributor

napi 3.14 decodes a class reference only inside a native borrow scope, which a resolved loader promise does not have, so every loader returning ZenDecisionContent failed with "Value is none of these types". Decode the loader result into LoadedDecision, which copies the content Arc while the JS object is alive and keeps buffers for parsing off the JS thread.

napi 3.14 decodes a class reference only inside a native borrow scope, which a resolved loader promise does not have, so every loader returning ZenDecisionContent failed with "Value is none of these types". Decode the loader result into LoadedDecision, which copies the content Arc while the JS object is alive and keeps buffers for parsing off the JS thread.
@stefan-gorules
stefan-gorules merged commit 96af373 into master Oct 13, 2026
22 checks passed
@stefan-gorules
stefan-gorules deleted the fix/nodejs-loader-decision-content branch October 13, 2026 15:55
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