Draft
Conversation
* add weiroll script generation * feat: add script hash computation (#405) * add script hash computation * feat: add ABI generation (#406) * add ABI generation * remove comments in ABI * feat: add types for workflow definitions (#407) * add types for workflow definitions * feat: add variable resolution (#408) * add variable resolution * add onchain policy management (#410)
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.
Added
buildScript(workflow, context)— resolves magic, configurable, and runtimevariables and returns
{ commands, state, stateBitmap }ready for on-chainsubmission.
computeScriptHash(commands, state, stateBitmap, callbacks)— offlinereimplementation of
OnchainPM.computeScriptHash(): hashes only pinned stateslots so runtime values don't invalidate the Merkle proof.
buildPolicyUpdate(onchainPMAddress, strategist, scriptHashes)— rebuilds thestrategist's Merkle root from all whitelisted script hashes and returns an
unsigned
Hub.updateContract()transaction.resolveVariableLabel(variable, poolMetadata)— maps magic variable keys(e.g.
$scId) to human-readable labels for API responses.WorkflowDefinition,WeirollAction,WorkflowStateSlot,Callback, andrelated types in
src/types/workflow.ts.OnchainPM,OnchainPMFactory,ScriptHelpers.encodeCommandand weiroll constants (CALL,STATICCALL,VALUECALL,FLAG_RAW,UNUSED_SLOT) exported as public utilities.