Releases: PaimaStudios/paima-engine
Releases · PaimaStudios/paima-engine
5.0.0
Breaking change
caip2
value can now be null (in the case of timers) instead of empty string''
since it's safer to force handling this case explicitlycde_caip2
tochain_data_extensions
. See #416 for moreconfig
field incde_dynamic_primitive_config
is now aJSONB
type instead ofTEXT
Bug fixes
dotenv
no longer tries to load the dependency on browser builds (so you no longer need a polyfill for it). This was a bug introduced in 4.0.0
Chore
- YAML config parsing now allows usage of anchor
- Paima Engine no longer bundles templates, docs or contracts. These are always out-of-date in practice because they're in separate repos causing a chicken-and-egg problem when keeping versions in sync, and removing them lowers the build time a lot of and lowers the exe size
4.0.0
Breaking changes
- Moved common types for REST API endpoints from
@paima/mw-core
to@paima/utils
. This makes it easier to share these types between your backend API and frontend client - STF calls now receive a new
BlockHeader
type (from@paima/sdk/utils
) instead of just the blockHeight
New features
- Add multiple new
@paima/rest
endpointstransaction_count/blockHeight
to get the total count of transactions (inputs & scheduled) in a blocktransaction_count/address
to get the total count of transactions (inputs & scheduled) in a block for a specific addresstransaction_content/blockNumberAndIndex
to get the content of a transaction by a block number + tx index
- Visually see the
AsyncAPI
for a node (the MQTT events used in Paima)- Full UI at
http://localhost:3333/docs/asyncapi/ui
- Specification at
http://localhost:3333/docs/asyncapi/spec.yml
- Full UI at
- Precompiles can now be fetched as a JSON object from
http://localhost:3333/docs/precompiles
@paima/rest
REST API endpoints can be now be queries in a statically typechecked way using usingimport { getPaimaNodeRestClient } from '@paima/mw-core'
Experimental features
- New (experimental) EVM JSON-RPC wrapper support for Paima applications at
http://localhost:3333/rpc/evm
. This means you can query a Paima node as if it was an EVM node. Not all endpoints work- Some EVM-specific concepts like
uncles
don't exist in Paima - Transaction / block related endpoints currently are not well supported (improvements coming in the future. See #411)
- Some EVM-specific concepts like
- Work-in-progress support for MQTT topics that are complex objects (not just strings & number) by turning creating the topic based on the object's hash
Bug fixes
- Fix avail batcher not sending a message when a batch is finalized
- Fix issue where an empty presync during parallel EVM sync caused a crash
- Add missing error code documentation on
@paima/rest
endpoints - Fix missing return on
dry_run
error case - Log database connection string so it's more obvious the cause of a crash if it crashes during connection
Chores
- Bump
nx
version - Fix issue with tests hanging on latest foundry version
- Load
ENV
in nodejs environments if used before they are explicitly loaded - Fixed
@paima/source
sometimes causing builds to hang - Document error severity when checking for implicit dependencies in the Paima build process
3.0.1
Bug fixes
- fix: generic primitives are not scheduled on presync by @ecioppettini in #403
3.0.0
Breaking change
- New
precompiles
system to give names to timers (and to event logs). You can learn how to register precompiles here. This requires you to create a precompiles project in your workspace createScheduledData
now requires to be registered as a precompile
New features
- MQTT support to listen to L2 blocks being made and batcher transaction progress. Learn more about the new in-progress event system here
- Finish implementing the PoC Orderbook DEX to enable trading of prc-5 ERC1155 tokens. Learn more about the contract here
- New Cardano smart contract package
inverse-whirlpool
. This is still a WIP - New docgen tool to generate Docusaurus docs from Cardano contracts (npm)
- New recaptcha option for batchers. Learn more about how to set this up here
- Introduce new transaction hash for all transactions in Paima. You can see how they're calculated here
- Add
PaimaParser.JSON
to easily parse JSON data from chains
Avail related updates
- Avail batcher support (post txs to Avail instead of EVM) set by
BATCHER_NETWORK
. Learn more here - Use Avail as the source of DA instead of EVM by replacing the EVM chain in the settings with Avail. Learn more about the Avail funnel here
- Use Avail as a secondary source of DA while keeping EVM as the main source. You can learn more about the Parallel Avail funnel here
- Expose
config.$NETWORK.yml
configuration as aBUILT_TIME_INJECTED_CONFIGURATION
env variable
Bug fixes
- Added
NODE_OPTIONS='--max-old-space-size=8192' to fix
npm run lint` running out of memory - Fixed localhost batcher setup (no longer using incorrect
BATCHER_DB_HOST
value) - Fix dynamic primitive sometimes triggering twice
- Add missing log when CDEs persisted don't match the CDEs loaded
cdeName
is now optional forcreateScheduledData
- Fix Hardhat
retrieveFee
having the wrong type specified for the return - Fix emulated blocks sometimes fetching the wrong block range causing it to get into a bad state. Learn more here
- Make funnel processing order consistent. Learn more here
Chores
- Print funnel configuration on paima-engine launch
- Lowered default
GAME_INPUT_VALIDATOR_PERIOD
andBATCHED_TRANSACTION_POSTER_PERIOD
for batcher (this makes running on localhost chains faster) - Added initial Verdaccio support so we can more easily test local packages. This is still a WIP, but you can try it with
npm run release:local
- Bumped many dependency versions
2.4.0
New features
- New ability to dynamically register primitives (ERC721 or generic) for the rollup (see docs)
- Add ERC1155 primitive docs
- Improve delegation cancellation API and delegation docs (docs)
- Mina primitive support (docs)
- Mina wallet (Aura) support (docs)
- Add new achievement standard to the game node (docs)
- Unify parallel funnel
confirmationDepth
anddelay
to be common amongst all parallel funnel types (docs) - Add the transaction hash that triggered a state transition function update in
inputData.scheduledTxHash
(docs) - Add the primitive name that triggered a state transition function update in
inputData.extensionName
(docs)
Bug fixes
- Fix block where full block would be dropped if a single STF update in the block failed
- Fix cleanup not being done if STF call to update delegation information changes
Tooling
- add command to print the json schema of the config by @ecioppettini in #361
- feature/windows by @GGAlanSmithee in #369
New Contributors
- @GGAlanSmithee made their first contribution in #369
Full Changelog: 2.3.0...2.4.0
2.3.0
Breaking change
- Unify all primitive so they schedule STF events during the presync to the first slot after presync is done
New features
- Introduce new parallel EVM funnel (docs)
- Introduce new
config.$NETWORK.yml
file to store network configurations (docs) - New transfer primitive for Cardano
- New mint & burn primitive for Cardano
- Expose wallet delegation state transitions (see here) to the user app state machine
- Add new optional
burnScheduledPrefix
for the ERC721 primitive (docs) - Add new utility functions for querying pending migrations:
getPendingMigration
hasPendingMigrationForBlock
Build system
- Enable batcher to run on localhost setups
- Set batcher system to default ENV variables to hardhat node
- Avoid occasional module duplication caused by
src
imports - Update batcher to use postgres 16
ssh-agent
no longer required to build Paima- Bump version of CML used
- Remove truffle (and most of web3) and replace it with
ethers
Bug fixes
- Fix
npx paima-reset-db
script - Fix typo in some Paima error strings (8e7d3dd)
- Fix wallet delegation not resolving for inputs that happen too soon after the delegation occurred
- Batcher no longer silently crashes if initialization fails
@paima/evm-contracts 3.0.0
2.2.0
Breaking changes
- Migrated all contracts to the new @paima/evm-contracts package now managed by Hardhat (see docs for more info on how to use this package)
- Updated to latest
pgtyped
version2.3.0
(games need to use the same version as Paima Engine) - Introduce new
NETWORK
env variable (replacingNODE_ENV
) for choosing which network to use for deployments (withlocalhost
as the new default)
Features
- Support for a Carp funnel to get Cardano data. This comes with the following new primitives
- New
BATCHER_CARDANO_ENABLED_POOLS
option for batchers to only provide free txs to delegators of a specific pool - Add new
npx paima-reset-db
script to reset the docker database and update theSTART_BLOCKHEIGHT
for the app - New Paima Hardhat plugin to interact with L2 contracts (see Paima docs for more info)
- New Paima wallet delegation system #272
START_BLOCKHEIGHT
is no longer required on localhost networks (since they always start at block 0)
Bug fixes
- Support ABI files that are just the raw ABI (instead of wrapped in an object)
Chore
- Update from node18 to node20 (
lts/iron
) - Drop support for pkg-dev builds of Paima Engine
- New codegen tool for Solidity documentation (see Paima docs for how the result looks)
- Disable broken
webui
command - Improve address validity check for Cardano/Algorand/Polkadot
- Remove duplicate MetaMask entry in EVM wallet option list (
getWalletOptions
) that was caused by MetaMaks adding EIP-6963 support - Fix
wipe.sh
command not cleaning all generated files
Draft for SNEK
This is a draft build on top of master that changes
const bodyParser = express.json();
to
const bodyParser = express.json({ limit: '50mb' });
which SNEK needs
v2.1.2
Breaking change
- Split all nodejs-dependent functionality out of
@paima/sdk
and into a new NPM package@paima/node-sdk
. This should improve the portability of Paima
New features
- Release v1 of
@paima/rest
that allows easily visualizing the API for your game node. To use this, add anopenapi.json
to your game's build output (seepack.sh
in templates on how to do this) and then visithttp://localhost:3333/docs/
after starting your node - Add
checkChainId: false
option on theEvmInjected
option ofuserWalletLogin
for games that never need to a sign a transaction. This allows the game to function on wallets that cannot switch networks like Phantom and Flint.
Bug fixed
- Fix injected EVM
signMessage
calls - Fix
EvmEthers
mode foruserWalletLogin
- Fix Metamask appearing twice in the list of EVM wallets available to a user
- Fix invalid user input potentially causing sync of the game node to get stuck
Refactor
- Increase default for
EMULATED_BLOCKS_MAX_WAIT
to 20s - Removed unnecessary fields in
cde_tracking
leftover from previous refactoring #257
Full Changelog: v2.0.0...2.1.2