@acala-network/chopsticks 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +2 -4
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -57,11 +57,9 @@ const setup = async (argv) => {
|
|
|
57
57
|
const port = argv.port || Number(process.env.PORT) || 8000;
|
|
58
58
|
const tasks = new task_1.TaskManager(port, argv['mock-signature-host'], argv['executor-cmd']);
|
|
59
59
|
const blockNumber = +header.number;
|
|
60
|
+
const timestamp = argv.timestamp ?? Date.now();
|
|
60
61
|
const setTimestamp = new inherents_1.SetTimestamp((newBlockNumber) => {
|
|
61
|
-
|
|
62
|
-
return argv.timestamp + (newBlockNumber - blockNumber) * 12000; // TODO: make this more flexible
|
|
63
|
-
}
|
|
64
|
-
return Date.now();
|
|
62
|
+
return timestamp + (newBlockNumber - blockNumber) * 12000; // TODO: make this more flexible
|
|
65
63
|
});
|
|
66
64
|
const inherents = new inherents_1.InherentProviders(setTimestamp, [new inherents_1.SetValidationData(tasks, 1)]);
|
|
67
65
|
const chain = new blockchain_1.Blockchain({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@acala-network/chopsticks",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"types": "./dist/index.d.ts",
|
|
6
6
|
"author": "Bryan Chen <xlchen1291@gmail.com>",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"dev:acala": "ts-node-dev --transpile-only --inspect --notify=false src/index.ts -- dev --config=configs/acala.yml"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@acala-network/chopsticks-executor": "0.2.
|
|
31
|
+
"@acala-network/chopsticks-executor": "0.2.2",
|
|
32
32
|
"@polkadot/api": "^9.10.1",
|
|
33
33
|
"@polkadot/rpc-provider": "^9.10.1",
|
|
34
34
|
"@polkadot/types": "^9.10.1",
|