Skip to content

Commit 4821374

Browse files
Release/5.5.0 (#138)
2 parents 904c4ab + fea5fcf commit 4821374

File tree

246 files changed

+71643
-76792
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

246 files changed

+71643
-76792
lines changed

.dockerignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.drone.yml.back

Lines changed: 0 additions & 63 deletions
This file was deleted.

.github/workflows/main.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
on:
2+
push:
3+
branches:
4+
- feature/*
5+
- bugfix/*
6+
- develop
7+
- release/*
8+
- hotfix/*
9+
- main
10+
- v5
11+
12+
jobs:
13+
coverage:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
- name: Init
19+
run: npm ci
20+
- name: Run coverage
21+
run: npm run coverage
22+
- name: Upload coverage reports to Codecov
23+
uses: codecov/[email protected]
24+
with:
25+
token: ${{ secrets.CODECOV_TOKEN }}
26+
slug: iExecBlockchainComputing/PoCo
27+
- name: Run static analysis with slither
28+
uses: crytic/[email protected]
29+
id: slither
30+
with:
31+
target: "contracts/tools/testing/slither/"
32+
solc-version: '0.8.21'
33+
slither-args: --checklist --markdown-root ${{ github.server_url }}/${{ github.repository }}/blob/${{ github.sha }}/
34+
node-version: "20"
35+
fail-on: none # TODO set this to high or other
36+
sarif: results.sarif
37+
- name: Upload SARIF file
38+
uses: github/codeql-action/upload-sarif@v3
39+
with:
40+
sarif_file: ${{ steps.slither.outputs.sarif }}

.gitignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,18 @@ node_modules
44
coverage
55
coverage.json
66
logs
7+
8+
.env
9+
typechain
10+
typechain-types
11+
12+
# Hardhat files
13+
cache
14+
artifacts
15+
16+
# Deployed addresses saved with deploy/ scripts
17+
build/*.json
18+
19+
contracts/hardhat-dependency-compiler/
20+
deployments/*hardhat*
21+
deployments/dev-*

.husky/pre-commit

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/usr/bin/env sh
2+
3+
npx lint-staged
4+
npm run doc

.mocharc.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"require": "hardhat/register",
3+
"timeout": 40000,
4+
"_": ["test/**/*.test.ts"]
5+
}

.prettierrc

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"printWidth": 100,
3+
"singleQuote": true,
4+
"tabWidth": 4,
5+
"trailingComma": "all",
6+
"endOfLine": "auto",
7+
"plugins": [
8+
"prettier-plugin-organize-imports",
9+
"prettier-plugin-solidity"
10+
],
11+
"pluginsComments": {
12+
"prettier-plugin-organize-import": "Supports .ts files (not .sol)",
13+
"prettier-plugin-solidity": "Does not support imports sorting yet. See prettier-solidity/prettier-plugin-solidity#918"
14+
},
15+
"overrides": [
16+
{
17+
"files": "*.sol",
18+
"options": {
19+
"singleQuote": false
20+
}
21+
}
22+
]
23+
}

.solcover.js

Lines changed: 23 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,26 @@
1-
const fs = require("fs");
1+
const BASE_FOLDER = './coverage';
22

33
module.exports = {
4-
client: require('ganache'),
5-
/*
6-
* providerOptions: {
7-
* hardfork: "istanbul",
8-
* mnemonic: "actual surround disorder swim upgrade devote digital misery truly verb slide final",
9-
* network_id: 65535
10-
* },
11-
*/
12-
mocha: {
13-
timeout: 600000, // double timeout
14-
},
15-
port: 8555,
16-
skipFiles: [
17-
'tools/Migrations.sol',
18-
'tools/testing/TestClient.sol',
19-
'tools/testing/TestReceiver.sol',
20-
],
21-
onCompileComplete: () => {
22-
files = [
23-
{ repo: 'rlc-faucet-contract', name: 'RLC' },
24-
{ repo: '@ensdomains/ens', name: 'ENSRegistry' },
25-
{ repo: '@ensdomains/ens', name: 'FIFSRegistrar' },
26-
{ repo: '@ensdomains/ens', name: 'ReverseRegistrar' },
27-
{ repo: '@ensdomains/resolver', name: 'PublicResolver' },
28-
{ repo: '@iexec/erlc', name: 'ERLCTokenSwap' },
29-
{ repo: '@iexec/solidity', name: 'ERC1538Proxy' },
30-
{ repo: '@iexec/solidity', name: 'ERC1538UpdateDelegate' },
31-
{ repo: '@iexec/solidity', name: 'ERC1538QueryDelegate' },
32-
{ repo: '@iexec/solidity', name: 'GenericFactory' },
33-
];
34-
for (file of files)
35-
{
36-
fs.copyFileSync(`node_modules/${file.repo}/build/contracts/${file.name}.json`, `.coverage_artifacts/contracts/${file.name}.json`);
37-
}
38-
}
4+
/**
5+
* See https://github.com/sc-forks/solidity-coverage/issues/715 issue if
6+
* coverage is 0% when IR enabled.
7+
*/
8+
configureYulOptimizer: true,
9+
solcOptimizerDetails: {
10+
yul: true,
11+
yulDetails: {
12+
optimizerSteps: '',
13+
},
14+
},
15+
mocha: {
16+
timeout: 600000, // double timeout
17+
},
18+
skipFiles: [
19+
'tools/Migrations.sol',
20+
'tools/testing/ERC1271Mock.sol',
21+
'tools/testing/TestClient.sol',
22+
'tools/testing/TestReceiver.sol',
23+
'modules/delegates/SignatureVerifier.sol',
24+
],
25+
istanbulFolder: BASE_FOLDER,
3926
};

CHANGELOG.md

Lines changed: 169 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,174 @@
11
# Changelog
22

3+
## v5.5.0
4+
5+
### What's new?
6+
- Added the ability to sponsor a deal for a requester via the new `sponsorMatchOrders(..)` function.
7+
- contracts implementation ✍️
8+
- deployment on iExec Bellecour network 🚀
9+
- Initialized « boost » mode to improve deal throughput
10+
- contracts implementation ✍️
11+
12+
### More details
13+
- Include `IexecOrderManagement` module in Poco sponsoring upgrade. (#132)
14+
- Update function visibilities to `external` in `IexecPoco` and `IexecOrderManagement` modules. (#131)
15+
- Fix configs native and token. (#129)
16+
- Bump dependencies: (#127)
17+
- `@openzeppelin/hardhat-upgrades`, `hardhat-dependency-compiler`, `web3`,
18+
`prettier`, `zx`, and others [minor/patch version bump]
19+
- `prettier-plugin-organize-imports@4`
20+
- Clean some TODOs and harmonize unit tests. (#123)
21+
- Add `set-callback-gas.ts` script. (#121)
22+
- Accept any signature format in `SignatureVerifier.v8` when the account is a smart contract. (#120)
23+
- Update UML class diagrams. (#112)
24+
- Generate Solidity documentation. (#111)
25+
- Migrate unit test files to Typescript & Hardhat:
26+
- Resources (#125, #126)
27+
- Registries (#122, #124)
28+
- IexecPoco2
29+
- reopen (#133)
30+
- finalize (#79, #117, #119)
31+
- reveal (#114, #118)
32+
- contribute (#108, #109, #110)
33+
- IexecPoco1 (#107, #113, #115, #116)
34+
- Add `.test` suffix to unit test files (#106)
35+
- ENSIntegration (#105)
36+
- IexecOrderManagement (#101, #102, #103, #104)
37+
- IexecMaintenance (#100)
38+
- IexecEscrowNative (#99)
39+
- IexecERC20 (#98)
40+
- IexecCategoryManager (#97)
41+
- IexecAccessors (#96)
42+
- Wait for transactions occurring during deployment. (#95)
43+
- Deploy and configure ENS with hardhat. (#93)
44+
- Fix contribute & finalize with callbacks. (#92)
45+
- [Deploy Poco sponsoring on local fork of Bellecour](./scripts/sponsoring/README.md). (#91)
46+
- Create slither smart contract entry point and run slither analysis on new contracts. (#87)
47+
- Upgrade to `@openzeppelin/[email protected]` and upgrade other dependencies. (#86)
48+
- Deploy IexecPocoAccessorsDelegate module. (#85)
49+
- Create `_computeDealVolume` and expose `ComputeDealVolume` functions (#82)
50+
- Upgrade Order Management to solidity `^0.8.0`. (#84)
51+
- Resolve naming conflict in accessors. (#81)
52+
- Refund sponsor on `claimBoost`. (#80)
53+
- Seize sponsor on success task. (#79)
54+
- Refund sponsor on `claim`. (#77)
55+
- Sponsor match orders boost. (#67, #78)
56+
- Migrate to hardhat tests related to:
57+
- `initialize` (#74, #75)
58+
- `claim` (#65, #66, #72, #76)
59+
- Upgrade Poco2 to solidity v0.8 . (#63)
60+
- Use common helpers in Poco Boost integration tests. (#62)
61+
- Upload coverage reports to Codecov. (#61)
62+
- Deploy contracts in tests explicitly with hardhat or truffle fixture. (#59)
63+
- Add the ability to deploy without truffle fixture. (#58)
64+
- Sponsor match orders. (#57, #60)
65+
- Upgrade Poco1 to solidity `^0.8.0` (#55):
66+
- Migrate to `openzeppelin@v5`
67+
- Migrate to `SignatureVerifier.v8`
68+
- Change MNEMONIC var name for production & clean Hardhat file. (#53)
69+
- Format files & update copyright notices:
70+
- DelegateBase, IexecERC20Core (#64)
71+
- PoCo2 contracts (#54)
72+
- PoCo1 contracts (#52)
73+
- Order Management contract (#83)
74+
- Remove enterprise mode. (#51, #56)
75+
- Add PoCo Boost modules to a timelock controlled proxy.
76+
- Add IexecEscrow.v8 tests and developer notices.
77+
- Add tests around callback feature verifying interests of actors are guaranteed.
78+
- Reformat JS files.
79+
- Create a hardhat network close to the iExec Bellecour blockchain.
80+
- Merge settings and v8Settings using object spread.
81+
- Remove useless files.
82+
- Add Slither config. Run single contract Slither analysis on CI.
83+
- Make Poco Boost ITs runnable with "native" mode.
84+
- Migrate puml2links.sh to zx.
85+
- Update copyright and license notices.
86+
- Introduce zx for task scripting.
87+
- Compile latest contracts with 0.8.21.
88+
- Use a single 0.8.19 solidity version to compile latest contracts.
89+
- Fix prettier solidity plugin resolution.
90+
- Remove patched test helpers.
91+
- Clean poco-chain files.
92+
- Bump dependencies.
93+
- Check balance in transfer operation.
94+
- Reformat tests.
95+
- Reformat contracts.
96+
- Add mocha to use test explorer.
97+
- Refactor tests.
98+
- Add dedicated Poco Boost accessors.
99+
- Implement `claimBoost`:
100+
- Refund requester.
101+
- Seize workerpool and reward kitty.
102+
- Implement `pushResultBoost`:
103+
- Verify task exists.
104+
- Push result before deadline.
105+
- Require enclave challenge when TEE bit of tag set.
106+
- Verify signatures
107+
- scheduler
108+
- enclave
109+
- tee broker
110+
- Reward worker.
111+
- Reward app provider.
112+
- Reward dataset provider.
113+
- Unlock scheduler stake.
114+
- Reward scheduler.
115+
- Handle callback.
116+
- Implement `matchOrdersBoost`:
117+
- Verify compatibility of orders
118+
- trust
119+
- category
120+
- price
121+
- tag
122+
- restrictions
123+
- Assets or requester belong to groups in ERC734 identity contract.
124+
- Verify entries are registered & category exists.
125+
- Verify signatures or presignatures of orders.
126+
- ERC1271 contracts can be signers of orders.
127+
- Compute volume & consume orders.
128+
- Lock requester deal value.
129+
- Store deal.
130+
- Emit events.
131+
- Lock scheduler stake.
132+
- Return `dealId`.
133+
- Reduce gas footprint:
134+
- Remove beneficiary from deal storage.
135+
- Reduce Boost deal storage from 6 to 5 slots.
136+
- Reduce gas consumption on `lock()` calls.
137+
- Cache addresses of assets and requester from arguments.
138+
- Init local vars and cache order category.
139+
- Optimize deal storing by slot.
140+
- Change local structure for local variables.
141+
- Store in variable if read multiple times.
142+
- Group `hasDataset` block.
143+
- Remove useless variable.
144+
- Update prettier rules and reformat.
145+
- Migrate `IexecPocoBoost` linking to hardhat deploy script.
146+
- Clean files related to docker build of a test blockchain.
147+
- Run automatically before commit a prettier on `.ts` and `.sol` staged files.
148+
- Upgrade `eth_signTypedData` function to use `ethers`. Remove now useless `eth-sig-util`.
149+
- Init Boost deal structure.
150+
- Publish coverage report on CI/CD. Refactor Jenkinsfile.
151+
- Deploy Nominal and Boost modules with Hardhat.
152+
- Upgrade `hashStruct` function to use `ethers`.
153+
- Add Boost module.
154+
- Add interfaces.
155+
- Add `Store` contract compatible with solidity `^0.8.0`.
156+
- Update documentation:
157+
- Generate class diagrams from solidity contracts.
158+
- Add task and contribution state diagrams.
159+
- Add boost workflow sequence diagram. Update nominal workflow sequence diagram.
160+
- Update TEE workflow sequence diagram.
161+
- Update actors diagram.
162+
- Rename UMLs.md file to standard README.md.
163+
- Add inline solidity documentation.
164+
- Update class diagrams.
165+
- Create folder docs that contains all documentation material.
166+
- Migrate to Hardhat:
167+
- Init Hardhat project.
168+
- Migrate unit tests with `@nomiclabs/hardhat-truffle5`.
169+
- Fetch `@iexec/[email protected]` from default public registry.
170+
- Migrate tests coverage with [solidity-coverage](https://github.com/sc-forks/solidity-coverage) of `@nomicfoundation/hardhat-toolbox`.
171+
3172
## v5.4.2
4173
- Use latest Nethermind base image `nethermindeth/nethermind:iexec`
5174
(saved internally at `nexus.intra.iex.ec/nethermind:1.18.x-0`)

0 commit comments

Comments
 (0)