Skip to content

Commit

Permalink
Target pallet-revive instead of pallet-contracts (#2356)
Browse files Browse the repository at this point in the history
* Remove feature gated code

* Migrate code to `pallet-revive`

Remove `LimitParamsV1` + `pallet-contracts`
Use RISC-V target in CI
Use latest `polkadot-sdk` `master`
Use `H256` instead of `E::Hash`
Remove generic from `ToAddr` and `FromAddr`
Remove support for `no_implicit_prelude`
Remove `Determinism`

* Adding dry run for upload

* Revert "Adding dry run for upload"

This reverts commit 86411fa69b220972eb2194013bd6d7c614fabefb.

* Increase limit

* Remove generic `Salt`

* Implement new `delegate_call` API

* Fix CI, upgrade `dylint-link`

* Apply linter

* Fix copy from slice, deactivate `cargo fmt`

* Update `Cargo.lock`, apply `clippy` fixes

* Optimize CI

* Clean up more disc space

* Try to save more disk space

* Debug CI space issues

* Fix types for endowent and balance

* Fix tests and clippy errors

* Debug CI + fix types

* Fix linting tests

* Fix CI

* Fix `erc20` + `trait-erc20`

* Fix `erc721` + `contract-ref`

* Fix `erc1155`

* Update to `polkadot-sdk` `b7afe48ed0bfef30836e7ca6359c2d8bb594d16e`

* Fix `dns`

* Debug CI

* Debug CI

* Fix `lazyvec`

* Debug CI

* Debug CI

* Fix `cross-contract-calls` partly

* Debug `cross-contract-calls`

* Fix `contract-transfer`

* Debug strange bug

* Add stack bug reproducer

* Make clippy happy

* Fix types

* Fix types

* Fix `custom-environment`, `multisig`, `contract-terminate`, `contract-transfer`

* Fix more examples

* Fix more tests

* Run tests with `--all`

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Debug CI

* Fix tests for `lazy` + `delegator`

* Debug strange bug

* Revert "Debug strange bug"

This reverts commit fbd23ee.

* Fix tests

* Make `clippy` happy

* Fix tests + add debugging output

* Debug `mapping` test

* Fix GHA

* Add `unstable` feature

* Fix GHA

* Debug `mapping` tests

* Update CI confgi

* Fix `mapping` + `events` tests

* Fix CI config for `mapping`

* Add `unstable` feature everywhere

* Add missing `unstable` feature for integration tests

* Add `unstable` for `linting`

* Add `unstable` for `linting`

* Add `unstable` for `conditional-compilation`

* Debug `events`

* Add `unstable` for `lang-err` tests

* Fix `static-buffer` tests

* Implement todo's

* Apply `cargo fmt`

* Fix spellcheck + zepter

* Apply `cargo fmt`

* Fix CI + reenable test

* Apply `clippy` fixes

* Fix CI

* Apply `cargo fmt`

* Add failsafe for scripts

* Debug `examples-test-mapping`

* Debug `examples-test-mapping`

* Debug `examples-test-mapping`

* Temporarily `nightly-2024-11-28` for `mapping`

* Use latest `nightly` for `mapping`

* Fix URL

* Disable `doctest` for `mapping`

* Use self-hosted runner

* Fix path for `delegator`

* Update labels for runner

* Revert "Update labels for runner"

This reverts commit d4a2366.

* Revert "Use self-hosted runner"

This reverts commit d995e27.

* Add words to dictionary

* Use self-hosted runner

* Update labels for runner

* Adapt for instantiation testability

* Remove `unstable` feature

* Update test fixtures

* Revert running on self-hosted

* Replace `test_instantiate` feature with `test`

* Add `e2e_tests` module to `contract-invocation`

* Revert "Replace `test_instantiate` feature with `test`"

This reverts commit 79c311a.

* Cleaning up `contract-invocation`

* Add `test_instantiate` to integration tests

* Fix CI

* Deduplicate E2E-built contracts

* Fix CI

* Fix CI

* Fix CI

* Update test fixtures, propagate `test_instantiate`

* Debug CI

* Update test fixtures

* Allow `unexpected_cfgs`

* Add `allow(unexpected_cfgs)` to ui tests

* Use `std` instead of `test_instantiate`

* Remove `test_instantiate` feature throughout

* Update fixtures

* Fix inner attribute

* Remove println's

* Fix linting tests

* Make `panic` an `unreachable`

* Get rid of `unreachable_code` errs

* Update test fixtures

* Fix `contract-invocation`

* Get rid of `unreachable_code` errs

* Update values for `contract-invocation` asserts

* Fix `contract-invocation` tests

* Update test fixtures

* Fix `own_code_hash`

* Use `nightly` for measuring contract sizes (ICE)

* Migrate to `U256`

* Revert "Migrate to `U256`"

This reverts commit ae62747.

* Code cleanup

* Apply `cargo fmt`
  • Loading branch information
cmichi authored Jan 16, 2025
1 parent 06bd78e commit ba77c04
Show file tree
Hide file tree
Showing 399 changed files with 9,682 additions and 6,738 deletions.
3 changes: 3 additions & 0 deletions .config/cargo_spellcheck.dic
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ KECCAK
L1
L2
Polkadot
PolkaVM
PSP22
RPC
SHA
Expand Down Expand Up @@ -42,6 +43,7 @@ defragmentation
delegatee
delegator
deploy
deployer
dereferencing
deserialize/S
deserialization
Expand Down Expand Up @@ -77,6 +79,7 @@ tuple
type_info
unordered
untyped
upgradeable
v1
v2
v3
Expand Down
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ updates:
- package-ecosystem: "cargo"
directory: "/"
schedule:
interval: "daily"
interval: "weekly"
# ignore Substrate pallets major updates.
# automated Substrate releases cause dependabot PR spam, so these must be updated manually when required.
ignore:
Expand Down
3 changes: 1 addition & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
## Summary
Closes #_
- [ ] y/n | Does it introduce breaking changes?
- [ ] y/n | Is it dependent on the specific version of `cargo-contract` or `pallet-contracts`?
- [ ] y/n | Is it dependent on a specific version of `cargo-contract` or `pallet-revive`?
<!--- Provide a general summary of your changes -->

## Description
<!--- Describe your changes in detail -->

## Checklist before requesting a review
- [ ] My code follows the style guidelines of this project
- [ ] I have added an entry to `CHANGELOG.md`
- [ ] I have commented on my code, particularly in hard-to-understand areas
- [ ] I have added tests that prove my fix is effective or that my feature works
Expand Down
26 changes: 26 additions & 0 deletions .github/riscv64emac-unknown-none-polkavm.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"arch": "riscv64",
"cpu": "generic-rv64",
"crt-objects-fallback": "false",
"data-layout": "e-m:e-p:64:64-i64:64-i128:128-n32:64-S64",
"eh-frame-header": false,
"emit-debug-gdb-scripts": false,
"features": "+e,+m,+a,+c,+auipc-addi-fusion,+ld-add-fusion,+lui-addi-fusion,+xtheadcondmov",
"linker": "rust-lld",
"linker-flavor": "ld.lld",
"llvm-abiname": "lp64e",
"llvm-target": "riscv64",
"max-atomic-width": 64,
"panic-strategy": "abort",
"relocation-model": "pie",
"target-pointer-width": "64",
"singlethread": true,
"pre-link-args": {
"ld": [
"--emit-relocs",
"--unique",
"--relocatable"
]
},
"env": "polkavm"
}
Loading

0 comments on commit ba77c04

Please sign in to comment.