Skip to content

chore(deps): bump @midnight-ntwrk/compact-runtime from 0.14.0 to 0.16.0#105

Open
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/midnight-ntwrk/compact-runtime-0.16.0
Open

chore(deps): bump @midnight-ntwrk/compact-runtime from 0.14.0 to 0.16.0#105
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/midnight-ntwrk/compact-runtime-0.16.0

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot Bot commented on behalf of github Jun 3, 2026

Bumps @midnight-ntwrk/compact-runtime from 0.14.0 to 0.16.0.

Release notes

Sourced from @​midnight-ntwrk/compact-runtime's releases.

Compact toolchain 0.31.0 (Compact language 0.23.0)

Compact toolchain 0.31.0

  • Date: 2026-04-28
  • Language version: 0.23.0
  • Compact runtime version: 0.16.0
  • Environment: All public Midnight environments at the time of release. For the full compatibility matrix, see the release notes overview

High-level summary

Version 0.31.0 of the Compact toolchain has workarounds for erroneous proof failures which were awkward for developers to avoid. You can update to this version with compact update (as long as it is the most recent version) or compact update 0.31.

Audience

These release notes are intended for Compact smart contract developers and for DApp developers who use the Compact runtime.

What changed

This release has workarounds for an issue where proofs would erroneously fail because of conditional branches that were not taken. It also has a number of usability improvements and some other bug fixes.

  • Operations in untaken branches are changed so that they cannot fail during proof construction
  • The language reference is now up to date with the current language version
  • for loop iteration bounds can now be generic parameters
  • The contract-info.json file now contains a description of the public ledger state

Improvements

There are several correctness and usability improvements.

Operations in untaken branches cannot fail during proof construction

Off chain and before transaction submission, a Compact circuit is "run" twice. The first time, the compiled JavaScript code is executed to collect public and private state updates. The second time, the ZKIR representation of the circuit is used along with the public and private state updates already computed in order to construct a zero-knowledge proof.

During JavaScript execution, conditional branches in the Compact code are either taken or not taken, depending on the value of the condition. During proof construction, both branches of the conditional are considered as part of the relation being proven. This could lead to erroneous proof construction failures due to the not-taken branches.

The ZKIR representation of operations in conditional branches has been changed to work around this problem, so that they cannot fail when the branch is not taken. The following operations have had workaround implemented to prevent erroneous proof failures:

  • downcasts from Uint types to smaller Uint types,
  • downcasts of Field to Uint types,
  • conversions of byte vectors to and from Field and Uint types,
  • conversions of vectors to byte vectors, and
  • uses of relational comparisons (<, <=, >, >=) with inputs that might be unknown.

The downside of these workarounds is that they can increase the size of the generated circuit. If this increase in circuit size is problematic, developers should consider moving these operations outside of conditionally executed Compact code.

These workarounds are temporary ones, a genuine fix requires a change to the ZKIR format which will be coming in a later release.

Up to date language reference

The Compact language reference found in the Midnight Network documentation has been fully revised and is now up to date with the current version of the Compact language. Use this reference for definitive answers to questions about the language.

... (truncated)

Changelog

Sourced from @​midnight-ntwrk/compact-runtime's changelog.

[Toolchain 0.31.102, language 0.23.102, runtime 0.16.0]

Added

  • eval and arguments which are reserved words in strict mode of JavaScript are now added as future reserved words in Compact. Previously Compact accepted a contract using these as an identifier, resulting in producing an invalid JavaScript output.

Fixed

[Toolchain 0.31.101, language 0.23.101, runtime 0.16.0]

Added

Adds event and log as future keywords that are reserved.

[Toolchain 0.31.0, language 0.23.0, runtime 0.16.0]

This release includes all changes for compiler versions in the range between 0.30.100 and 0.31.0; language versions in the range between 0.22.100 and 0.23.0; and Compact runtime versions in the range between 0.15.100 and 0.16.0.

[Toolchain 0.30.107, language 0.22.101, runtime 0.15.101]

Fixed

Various zkir operators that can result in assertion failures and thus should be executed conditionally do not have guards are thus actually executed unconditionally. This can result in proof failures for correct transactions. For example, casting an unsigned integer value to a smaller unsigned type will always cause the proof to fail when the value is too big for that type, even if the cast occurs in a branch that is not taken in the Compact code.

The intent is to add guards to these operators in the next version of zkir. In the meantime, the compiler implements workarounds that arrange to invoke these operators with inputs that cannot cause assertion failures when the guard would be false.

The downside of these workarounds is that they can increase the size of the generated circuit. The size increase arises from conditional use (i.e., use in the then or

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [@midnight-ntwrk/compact-runtime](https://github.com/LFDT-Minokawa/compact) from 0.14.0 to 0.16.0.
- [Release notes](https://github.com/LFDT-Minokawa/compact/releases)
- [Changelog](https://github.com/LFDT-Minokawa/compact/blob/main/CHANGELOG.md)
- [Commits](https://github.com/LFDT-Minokawa/compact/commits)

---
updated-dependencies:
- dependency-name: "@midnight-ntwrk/compact-runtime"
  dependency-version: 0.16.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Jun 3, 2026
@dependabot dependabot Bot requested review from a team as code owners June 3, 2026 03:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants