Skip to content

Merge pull request #755 from kynesyslabs/merge/stabilisation-into-petri

9e8e557
Select commit
Loading
Failed to load commit list.
Open

Added Petri Consensus #692

Merge pull request #755 from kynesyslabs/merge/stabilisation-into-petri
9e8e557
Select commit
Loading
Failed to load commit list.
SonarQubeCloud / SonarCloud Code Analysis succeeded Apr 2, 2026 in 1m 24s

Annotations

Check warning on line 237 in testing/petri/blockCompiler.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

`rejectedHashes` should be a `Set`, and use `rejectedHashes.has()` to check existence or non-existence.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-fS-WNYeg2jWN2&open=AZ0ar7-fS-WNYeg2jWN2&pullRequest=692

Check warning on line 428 in testing/petri/secretaryCoordination.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Do not call `Array#push()` multiple times.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-US-WNYeg2jWNv&open=AZ0ar7-US-WNYeg2jWNv&pullRequest=692

Check warning on line 145 in src/libs/consensus/petri/block/petriBlockCompiler.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

'error' will use Object's default stringification format ('[object Object]') when stringified.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar711S-WNYeg2jWMg&open=AZ0ar711S-WNYeg2jWMg&pullRequest=692

Check warning on line 490 in src/libs/network/manageConsensusRoutines.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

'error' will use Object's default stringification format ('[object Object]') when stringified.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar71YS-WNYeg2jWMd&open=AZ0ar71YS-WNYeg2jWMd&pullRequest=692

Check warning on line 64 in testing/petri/routing.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this useless assignment to variable "selected2".

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-1S-WNYeg2jWN6&open=AZ0ar7-1S-WNYeg2jWN6&pullRequest=692

Check warning on line 38 in src/libs/consensus/petri/forge/continuousForge.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Member 'tracker' is never reassigned; mark it as `readonly`.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar72AS-WNYeg2jWMi&open=AZ0ar72AS-WNYeg2jWMi&pullRequest=692

Check warning on line 124 in testing/loadgen/src/features/consensus/petri_relay_flow.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79kS-WNYeg2jWNQ&open=AZ0ar79kS-WNYeg2jWNQ&pullRequest=692

Check failure on line 97 in testing/loadgen/src/features/consensus/petri_relay_flow.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 22 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79kS-WNYeg2jWNL&open=AZ0ar79kS-WNYeg2jWNL&pullRequest=692

Check warning on line 405 in testing/petri/secretaryCoordination.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Do not call `Array#push()` multiple times.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-US-WNYeg2jWNr&open=AZ0ar7-US-WNYeg2jWNr&pullRequest=692

Check failure on line 94 in testing/loadgen/src/features/consensus/petri_tx_inclusion.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 25 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79sS-WNYeg2jWNS&open=AZ0ar79sS-WNYeg2jWNS&pullRequest=692

Check warning on line 121 in testing/loadgen/src/features/consensus/petri_relay_flow.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79kS-WNYeg2jWNP&open=AZ0ar79kS-WNYeg2jWNP&pullRequest=692

Check warning on line 110 in testing/loadgen/src/features/consensus/petri_soak.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79aS-WNYeg2jWNB&open=AZ0ar79aS-WNYeg2jWNB&pullRequest=692

Check warning on line 74 in src/libs/consensus/v2/routines/broadcastBlockHash.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

'e' will use Object's default stringification format ('[object Object]') when stringified.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar74rS-WNYeg2jWM5&open=AZ0ar74rS-WNYeg2jWM5&pullRequest=692

Check warning on line 379 in testing/petri/secretaryCoordination.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Do not call `Array#push()` multiple times.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-US-WNYeg2jWNn&open=AZ0ar7-US-WNYeg2jWNn&pullRequest=692

Check warning on line 216 in testing/loadgen/src/features/consensus/petri_soak.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79aS-WNYeg2jWNH&open=AZ0ar79aS-WNYeg2jWNH&pullRequest=692

Check warning on line 175 in src/libs/consensus/petri/index.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

'error' will use Object's default stringification format ('[object Object]') when stringified.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar73eS-WNYeg2jWM0&open=AZ0ar73eS-WNYeg2jWM0&pullRequest=692

Check failure on line 170 in src/libs/consensus/petri/forge/continuousForge.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 31 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar72AS-WNYeg2jWMk&open=AZ0ar72AS-WNYeg2jWMk&pullRequest=692

Check warning on line 368 in testing/petri/secretaryCoordination.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Do not call `Array#push()` multiple times.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-US-WNYeg2jWNk&open=AZ0ar7-US-WNYeg2jWNk&pullRequest=692

Check warning on line 264 in testing/loadgen/src/features/consensus/petri_soak.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Prefer `.at(…)` over `[….length - index]`.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79aS-WNYeg2jWNJ&open=AZ0ar79aS-WNYeg2jWNJ&pullRequest=692

Check warning on line 137 in src/libs/consensus/petri/arbitration/bftArbitrator.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

'error' will use Object's default stringification format ('[object Object]') when stringified.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar73FS-WNYeg2jWMw&open=AZ0ar73FS-WNYeg2jWMw&pullRequest=692

Check warning on line 111 in testing/loadgen/src/features/consensus/petri_tx_inclusion.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

`new Error()` is too unspecific for a type check. Use `new TypeError()` instead.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79sS-WNYeg2jWNV&open=AZ0ar79sS-WNYeg2jWNV&pullRequest=692

Check failure on line 79 in src/libs/blockchain/mempool_v2.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 18 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar76pS-WNYeg2jWM8&open=AZ0ar76pS-WNYeg2jWM8&pullRequest=692

Check warning on line 221 in testing/loadgen/src/features/consensus/petri_soak.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar79aS-WNYeg2jWNI&open=AZ0ar79aS-WNYeg2jWNI&pullRequest=692

Check failure on line 147 in src/libs/blockchain/chainBlocks.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 26 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar758S-WNYeg2jWM6&open=AZ0ar758S-WNYeg2jWM6&pullRequest=692

Check warning on line 97 in testing/petri/conflictPath.test.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this useless assignment to variable "flagged".

See more on https://sonarcloud.io/project/issues?id=kynesyslabs_node&issues=AZ0ar7-_S-WNYeg2jWN7&open=AZ0ar7-_S-WNYeg2jWN7&pullRequest=692