Skip to content

Releases: CMTA/SnapshotEngine

v0.5.0

09 Jun 11:22
aa08935

Choose a tag to compare

- Changed

  • Bump VersionModule.VERSION and deployment test expectations to 0.5.0.

- Documentation

  • Add short contract-level NatSpec title/description blocks to the module and base contracts.
  • Add a short inheritance explanation for SnapshotEngine in the README schema section.
  • Add a matching README schema subsection for SnapshotEngineOwnable2Step, including inheritance and graph references.
  • Add a README Events section summarizing the snapshot events emitted by the external-engine and internal CMTAT deployment variants.
  • Fix the README table of contents and rename the duplicate Schema heading for the function-diagram section to Function Schemas.
  • Add the current deployed sizes of the main external-engine and local CMTAT internal snapshot deployment contracts to the README.

- Testing

  • Add a compatibility test covering simultaneous use of the external SnapshotEngine and the upstream CMTAT mock rule engine on the same token deployment.

Acknowledge
We would like to thank @Domson97 and @seturionbisig, as well as CMTA Tech Comite for their valuable feedback and contributions to this release and the previous one (v0.4.0). Their input played an important role in improving the project, and we sincerely appreciate their support.

v0.4.0

08 Jun 16:12
dec31b2

Choose a tag to compare

  • Dependencies

    • Align integration for CMTAT v3.3.0-rc1.
    • Update CMTATBaseRuleEngine import path (2_CMTATBaseRuleEngine.sol -> 3_CMTATBaseRuleEngine.sol).
    • Update version interface usage from IERC3643Base to IERC3643Version.
    • Update OpenZeppelin dependencies to @openzeppelin/contracts and @openzeppelin/contracts-upgradeable 5.6.1.
    • Replace full IERC20 dependency in SnapshotEngine modules with a minimal IERC20SnapshotCompatible interface (balanceOf, totalSupply).
  • Changed

    • Bump VersionModule.VERSION and deployment test expectations to 0.4.0.
    • Switch SnapshotEngine from OpenZeppelin AccessControl to AccessControlEnumerable.
    • Remove CMTATBaseSnapshot support from local CMTATUpgradeableInternalSnapshot and CMTATStandaloneInternalSnapshot so these deployment variants only support internal snapshots.
    • Keep external SnapshotEngine support separate from the local CMTAT deployment variants because combining both paths exceeds the EVM contract size limit.
    • Rename the local shared CMTAT snapshot base from CMTATSnapshotBase to CMTATInternalSnapshotBase to avoid confusion with upstream CMTAT snapshot contracts.
    • Rename the local deployment contracts from CMTATUpgradeableSnapshot / CMTATStandaloneSnapshot to CMTATUpgradeableInternalSnapshot / CMTATStandaloneInternalSnapshot to avoid colliding with upstream CMTAT contract names.
    • Convert snapshot scheduler authorization to a modifier-based gate that delegates to the internal _authorizeSnapshot() hook.
  • Documentation

    • Clarify and document the 0.3.0 known issue and 0.4.0 resolution for getNextSnapshots() arithmetic underflow when no future snapshots remain.
    • Document strict snapshot query semantics with exact-time APIs:
      • snapshotExists(time)
      • snapshotBalanceOfExact(time, tokenHolder) (reverts if time is not scheduled)
      • snapshotTotalSupplyExact(time) (reverts if time is not scheduled)
    • Document snapshot materialization observability:
      • SnapshotMaterialized(time, blockNumber) emitted when _setCurrentSnapshot() advances.
      • poke() can be used by authorized accounts to materialize due snapshots without requiring token transfers.
    • Add a second deployment variant using OpenZeppelin Ownable2Step (SnapshotEngineOwnable2Step) and refactor shared deployment logic into SnapshotEngineBase to minimize duplication.
    • Add CMTATStandaloneInternalSnapshot (standalone/non-proxy deployment) and refactor shared CMTAT+snapshot behavior into CMTATInternalSnapshotBase to minimize duplication with CMTATUpgradeableInternalSnapshot.
    • Update README integration guidance to document the minimal token interface required by SnapshotEngine (IERC20SnapshotCompatible).
    • Clarify in README.md that local CMTAT*InternalSnapshot deployment contracts are internal-snapshot-only and that external snapshot-engine-enabled CMTAT deployments should come from the CMTAT repository snapshot variants.
    • Add a SnapshotEngine compatibility table and setup guidance for supported CMTAT target versions.
  • Testing

    • Add tests for exact snapshot queries (scheduled vs non-scheduled timestamps and parity with legacy queries on scheduled timestamps).
    • Add tests for snapshot materialization event emission.
    • Add tests for poke() access control and idempotent behavior.
    • Add test coverage for SnapshotUnschedule(time) emission in unscheduleSnapshotNotOptimized.
    • Add a dedicated SnapshotEngineOwnable2Step test suite and share common snapshot behavior tests across AccessControl and Ownable variants.
    • Add a dedicated CMTATStandaloneInternalSnapshot test suite reusing the same shared snapshot behavior suites.
    • Refactor admin-authorization assertions into a shared helper to avoid duplicated expectations across test modules.
    • Refactor snapshot suite registration and CMTAT init params into shared test helpers to reduce duplication across test entrypoints.

v0.3.0

28 Aug 14:14
b5750a0

Choose a tag to compare

known issue with this release: _findScheduleMostRecentPastSnapshot - Uninitialized variable used in condition

  • Add deployment version with snapshot for CMTAT
  • Better code separation
  • Create new module SnapshotUpdateModule

v0.2.0

25 Aug 12:56
20e2aa5

Choose a tag to compare

Dependencies

  • Update CMTAT to v3.0.0-rc7
  • Update OpenZeppelin library to v5.4.0
  • Update Solidity to 0.8.30
  • Update EVM version to Prague

Technical

  • Better code separation trough the creation of modules
  • Use ERC-7201 for storage for compatibility with CMTAT

0.1.0

19 Aug 13:18
d47d6ff

Choose a tag to compare

First release !