Repository navigation
Conversation
Gated behind experimental-delete-account-metadata. Both engines call a new Store.DeleteAccountMetadata method during execution and drop any earlier set_account_meta of the same key from the result. Compiled to the new DELETE_ACCOUNT_META opcode (0x26), which the verifier rejects inside a mark.
Older 0.x freezes keep running with their header re-stamped to the current version, so a freeze only adds the programs no earlier freeze holds. The 0.2 freeze holds the four delete_account_metadata programs.
ascandone
force-pushed
the
feat/delete-account-metadata
branch
from
November 4, 2026 15:40
df1c77b to
d096c68
Compare
Contributor
|
Warning ⛔ REVIEW BLOCKED — binary files were not reviewedThese changed binary/non-UTF8 files were excluded from the model input. Their contents have not been verified.
|
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.
Adds a
delete_account_metadata(account, key)statement.Changes
(account, string), gated behind theexperimental-delete-account-metadataflag, requiringinterpreter 0.1.4when a version pragma is present. The LSP hover and diagnostics work through the analysis builtin table.StatementFnCallResolutionnow acceptsVersionConstraints.interpreter.Storeandvm.Store(numscript.Store/numscript.VMStore) both getDeleteAccountMetadata(ctx, account, scope, key string) error. The engine calls it during execution, in script order.DELETE_ACCOUNT_META(0x26, one word: account, key, scope). The verifier rejects it inside a mark, assaveis rejected, because a store delete cannot be undone. Exec checks the same.CurrentBytecodeVersionis now 0.2. 0.1 blobs are no longer readable, as for any 0.x bump.testdata/bytecode/0.2holds only the 4 new programs instead of a ~950-file copy of 0.1.testdata/bytecode/0.1is unchanged and still runs in full.DeleteMetadataError(exported). The VM wraps store failures in the existingVmStoreError.ResolveDependenciesreports the deleted key inMetaWrites.expect.deletedMetadata(an ordered list of{account, key, scope?}) in the code and inv1.specs.schema.json. Fixtures are inexperimental/delete-account-metadata/and run on both engines.StmtDeleteAccountMetadata.Semantics to review
The store is called mid-run, even if the run fails later. The host must apply the deletions in the same transaction as the result, and discard them on error.
Interaction with
set_account_metaon the same key:AccountsMetadata.The host must therefore apply the deletions before the result's metadata.
Reading a key after deleting it is not defined yet. Today no engine reads metadata after a statement: the interpreter rejects a mid-script
meta(), and the compiler compiles one in account position asscoped()(a separate bug on main). If mid-scriptmeta()is supported, the VM would ask the store, so the result would depend on whether the store has applied the delete yet.The engine does not check whether the key exists. Deleting a missing key is up to the store, which can return nil or an error.
StaticStore.DeleteAccountMetadatais a no-op, because aStaticStoreis an immutable snapshot. As a result,numscript run/testandbytecode rundo not show deletions in their output.Not done
SideResultdoes not capture store calls.DeleteAccountMetadataand bump its numscript pin.