All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Add Rust specific build info to metadata - #680
- Removed requirement to install binaryen. The
wasm-opttool is now compiled intocargo-contract.
This release supports compatibility with the v4.0.0-alpha.3
release of ink!. It is not backwards compatible with older versions of ink!.
--output-jsonsupport forcall,instantiateanduploadcommands - #722- Denominated units for Balances - #750
- Use new ink entrance crate - #728
- Skip linting if running building in --offline mode - #737
- Sync version of transcode crate to fix metadata parsing - #723
- Fix numbering of steps during
build- #715
This release brings two exciting updates! First, contracts can now be built using the
stable Rust toolchain! Don't ask us how we managed to do this 👻.
Secondly, it allows you to build ink! v4.0.0-alpha.1, which introduced a small - but
breaking - change to the ink! ABI as part of paritytech/ink#1313.
- Add support for ink!'s
versionmetadata field - #641
- Build contracts and dylint driver with stable - #698
- Compile dylints when compiling the contract - #703
- Move transcode example to doc test, add helper method - #705
- Note that alongside this PR we released
contract-transcode@0.2.0
- Note that alongside this PR we released
- Replace custom RPCs by
state_call- #701
- Fix
tracing_subscriberfiltering - #702
- Dry run gas limit estimation - #484
- Bump
ink_*crates tov3.3.1- #686 - Refactor out transcode as a separate library - #597
- Sync
metadataversion withcargo-contract- #611 - Adapt to new subxt API - #678
- Replace log/env_logger with tracing/tracing_subscriber - #689
- Contract upload: emitting a warning instead of an error when the contract already existed is more user friendly - #644
- Updated
cargo contract newtemplate dependencies to ink!version = "3"- #569 - Improved documentation on how to invoke
cargo contract decode- #572
- Make constructor selector look for exact function name - #562 (thanks @forgetso!)
- Fix dirty directory issue when crate installation had been interrupted - #571
- Allow hex literals for unsigned integers - #547
- Display
H256instances in events as hex encoded string - #550 - Fix extrinsic params for contract chains - #523
- Fix
Vec<AccountId>args - #519 - Fix
--dry-runerror deserialization and report error details - #534
decodecommand for event, message and constructor data decoding - #481
- Fix usage of
check-onlyand remove need forFromStrimpl - #499
- Fix linting support for Apple Silicon (and some other architectures) - #489
- Allow multiple args values for call and instantiate commands - #480
- Fix event decoding -
c721b1
--skip-lintingflag that allows to skip the linting step during build process - #468
- Improved error reporting during installation - #469
- Updated
cargo contract newtemplate dependencies to ink!3.0- #466
We added commands to upload, instantiate and call contracts!
This allows interacting with contracts on live chains with a compatible
pallet-contracts.
For command-line examples on how to use these commands see #79.
We are introducing a linter for ink! smart contracts in this release!
From now on cargo-contract checks if the ink! smart contract that is
build or check-ed follows certain rules.
As a starting point we've only added one linting rule so far; it asserts correct
initialization of the ink_storage::Mapping
data structure.
In order for the linting to work with your smart contract, the contract has to be written in at least ink! 3.0.0-rc9. If it's older the linting will just always succeed.
- Interact with contracts: upload, instantiate and call commands - #79
- Add linting to assert correct initialization of
ink_storage::Mapping- #431
- Upgrade
subxt, SCALE crates, and substrate primitivesp-*crates #451. - Updated
cargo contract newtemplate dependencies to ink!3.0.0-rc9- #443
- Updated
cargo contract newtemplate dependencies to ink!3.0.0-rc8- #402 - Reverted the disabled overflow checks in the
cargo contract newtemplate - #376 - Migrated to 2021 edition, enforcing MSRV of
1.56.1- #360
- For contract size optimization added
workspacesection to override parentworkspace- #378
- Updated
cargo contract newtemplate dependencies to ink!3.0.0-rc7- #374 - Disabled overflow checks in the
cargo contract newtemplate - #372 - Use
-Clinker-plugin-ltoifltois enabled (reduces the size of a contract) - #358 - Deserialize metadata - #368
- Added a
--offlineflag to build contracts without network access - #356
- Update to
scale-info1.0 and support new metadata versioning - #342 - Update
cargo contract newtemplate dependencies to ink!rc6- #342
- Add option for JSON formatted output - #324
- Use new dependency resolver for template contract - #325
- Do not strip out panic messages in debug builds - #326
- Fixed a Windows issue with contract files in sub-folders - #313
- Convenient off-chain testing through
cargo contract test- #283 - Build contracts in debug mode by default, add
--releaseflag - #298 - Add
--keep-symbolsflag for better Wasm analysis capabilities - #302
- Change default optimizations pass to focus on code size - #305
- Suggest
binaryeninstallation from GitHub release on outdated version - #274
- Always use library targets name for contract artifacts - #277
- Fixed
ERROR: The workspace root package should be a workspace memberwhen building a contract under Windows - #261
- Remove support for
--binaryen-as-dependency- #251 - Remove support for the deprecated
cargo contract generate-metadatacommand - #265 - Remove pinned
funtydependency from "new project" template - #260
- Fix
wasm-opt --versionparsing - #248
- Improve error output for
wasm-optinteraction - #244 - Check optimized Wasm output file exists - #243
- Detect
wasm-optversion compatibility and improve error messages - #242 - Detect version mismatches of
parity-scale-codecin contract and ink! dependency - #237 - Support specifying
optimization-passesin the release profile - #231 - Support specifying
optimization-passeson the CLI - #216 - Use
ink::testattribute in "new project" template - #190
- Only allow new contract names beginning with an alphabetic character - #219
- Upgrade
cargo-metadataand fix usages - #210
- no periods in new contract names - #192
- Update
cargo contract newtemplate dependencies forink!rc3- #204
- Fix linker error when building complex contracts - #199
- Implement Wasm validation for known issues/markers - #171
- Use either
binaryen-rsdep orwasm-optbinary - #168 - Update to scale-info 0.5 and codec 2.0 - #164
- Put build artifacts under
target/ink/- #122
- Fix
wasm-optregression - #187 - Generate metadata explicitly for the contract which is build - #174
- Fix bug with empty Wasm file when using system binaryen for optimization - #179
- Suppress output on
--quiet- #165 - Do not generate build artifacts under
targetforcheck- #124 - update wasm-path usage name - #135
- Exit with 1 on Err #109
- Use package name instead of lib name for metadata dependency #107
- Do not prettify JSON for bundle #105
- Make
source.hashnon-optional, remove metadata-only #104 - Implement new commands
buildandcheck+ introduce bundles (.contract files) #97 - Replace xbuild with cargo build-std #99
- Use binaryen-rs as dep instead of requiring manual wasm-opt installation #95
- Specify optional --manifest-path for build and generate-metadata #93
- Update new command template to ink! 3.0-rc2 #85
- Fix deprecation warnings #82
- Use ink 3.0.0-rc1 #82
- [template] now uses ink_env and ink_storage #81
- Update new command template to ink! 3.0 syntax #80
- Extract contract metadata to its own crate #69
- Fix ManifestPath compiler errors #73
- Upgrade cargo-xbuild and other dependencies #71
- Update subxt and async-std dependencies #66
- Generate extended contract metadata #62
- Autogenerate abi/metadata package #58
- Extract workspace to module directory #59
- Add preferred default release profile settings #55
- Add option to build with unmodified original manifest #51
- Update cargo-xbuild #54
- Fix LTO regressions in nightly toolchain #52
- First release to crates.io
- Use
subxtrelease from crates.io
- Fix: fail the whole build process if the contract build fails.
- Minimize contract wasm binary size:
- Run
wasm-opton the contract Wasm binary. - Uses
cargo-xbuildto build custom sysroot crates without panic string bloat. - Automatically removes the
rlibcrate type fromCargo.toml, removing redundant metadata.
- Run
- Removes requirement for linker args specified in
.cargo/config. - Added
--verboseand--quietflags forbuildandgenerate-metadatacommands.