Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:clean": "npx nx reset && npm run build",
"build-docker": "docker build -t protokit-base -f ./packages/deployment/docker/base/Dockerfile .",
"lint": "npx lerna run lint",
"lint:fix": "npx lerna run lint -- --fix",
"lint:staged": "eslint",
"test": "npx lerna run test -- --passWithNoTests",
"test:ci": "npx lerna run test --concurrency=1 -- --passWithNoTests --forceExit",
Expand Down
5 changes: 4 additions & 1 deletion packages/persistance/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
{
"extends": "../../.eslintrc",
"parserOptions": {
"project": ["./tsconfig.json", "./test/tsconfig.json", "./test-integration/tsconfig.json"]
},
"rules": {
"no-underscore-dangle": "off",
"@typescript-eslint/consistent-type-assertions": "off"
}
}
}
6 changes: 6 additions & 0 deletions packages/sequencer/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": ["../../.eslintrc"],
"parserOptions": {
"project": ["./tsconfig.json", "./test/tsconfig.json", "./test-integration/tsconfig.json"]
},
}
2 changes: 1 addition & 1 deletion packages/sequencer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"scripts": {
"build": "tsc -p tsconfig.json",
"dev": "tsc -p tsconfig.json --watch",
"lint": "eslint ./src ./test",
"lint": "eslint ./src ./test ./test-integration",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:watch": "npm run test:file -- ./test/** --watch",
Expand Down
1 change: 0 additions & 1 deletion packages/sequencer/test-integration/ArchiveNode.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { describe } from "@jest/globals";

import { ArchiveNode } from "../src/settlement/utils/ArchiveNode";
import { TokenId } from "o1js";

describe("ArchiveNode", () => {
it("should resolve", async () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { PrivateKey } from "o1js";
import { log } from "@proto-kit/common";
import { FungibleToken } from "mina-fungible-token";

import { settlementTestFn } from "../test/settlement/Settlement";
import { FungibleToken } from "mina-fungible-token";

console.log(PrivateKey.random().toPublicKey().toBase58());

Expand Down
1 change: 0 additions & 1 deletion packages/sequencer/test-integration/benchmarks/tps.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import {
DatabasePruneModule,
ManualBlockTrigger,
Sequencer,
AppChain,
} from "../../src";
// we import PrivateMempool from dist to satisfy constraints of InMemoryTransactionSender
import { PrivateMempool } from "../../dist";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,17 @@ export class ChildProcessWorker {
}
);
s.on("error", (err) => {
// eslint-disable-next-line no-console
console.error(err);
});
if (forwardLogs) {
s.stdout.on("data", (data) => {
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
process.stdout.write(data);
});
}
s.stderr.on("data", (data) => {
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
process.stderr.write(data);
});

Expand All @@ -37,6 +40,7 @@ export class ChildProcessWorker {

kill() {
this.process!.kill("SIGKILL");
// eslint-disable-next-line no-console
console.log("Killed", this.process!.killed);
}
}
2 changes: 2 additions & 0 deletions packages/sequencer/test-integration/workers/modules.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import { Runtime } from "@proto-kit/module";
import { Protocol } from "@proto-kit/protocol";
// eslint-disable-next-line import/no-extraneous-dependencies
import { VanillaProtocolModules } from "@proto-kit/library";
import { ModulesConfig } from "@proto-kit/common";
// eslint-disable-next-line import/no-extraneous-dependencies
import { BullQueueConfig } from "@proto-kit/deployment";

import { ProvenBalance } from "../../test/integration/mocks/ProvenBalance";
Expand Down
2 changes: 2 additions & 0 deletions packages/sequencer/test-integration/workers/worker.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ describe("worker", () => {
.containerEvents.on("ready", res);
});

expect(ready).toBe(true);

console.log("Ready received!");

await sleep(10000000);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,20 @@ import "reflect-metadata";
import { container } from "tsyringe";
import { PrivateKey, UInt64 } from "o1js";
import { expectDefined, log } from "@proto-kit/common";
import { AppChain } from "@proto-kit/sdk";
import { BullQueue } from "@proto-kit/deployment";

import {
BatchProducerModule,
BlockProducerModule,
InMemoryDatabase,
ManualBlockTrigger,
NoopBaseLayer,
PrivateMempool,
Sequencer,
SequencerStartupModule,
AppChain,
ConstantFeeStrategy,
} from "../../src";
import { BlockTestService } from "../../test/integration/services/BlockTestService";
import { ConstantFeeStrategy } from "../../src/protocol/baselayer/fees/ConstantFeeStrategy";

import {
BullConfig,
Expand All @@ -36,7 +35,7 @@ describe("worker-proven", () => {

let worker: ChildProcessWorker;

let appChain: AppChain<any, any, any, any>;
let appChain: AppChain<any>;

beforeAll(async () => {
worker = new ChildProcessWorker();
Expand Down