Skip to content

Commit 78fd20f

Browse files
committed
add hyperbridge
1 parent b550c7c commit 78fd20f

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
polkadot.wtf
2+
3+
backend @ https://github.com/lovelaced/corespaceweigher

src/App.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import {
1616
import useWeightConsumption from './hooks/useWeightConsumption';
1717
import { PROOF_SIZE_MB, MB_TO_GAS, GAS_TO_MGAS } from './constants';
1818

19-
const ALPHA = 0.3;
19+
const ALPHA = 0.7;
2020
const TARGET_WINDOW_SIZE = 30000; // 30s
2121
const MAX_BLOCKS_STORE = 1000;
2222

@@ -55,7 +55,7 @@ function calculateRollingMetrics(blocks: BlockRecord[]) {
5555
// console.log('debug: timeWindow <= 0, weird data -> returning 0');
5656
return { tps: 0, mbs: 0, gas: 0 };
5757
}
58-
58+
// subtract 2 for system extrinsics, but just in case ensure it's not negative
5959
const sumExtrinsics = relevant.reduce((acc, b) => acc + Math.max(0, b.extrinsics - 2), 0);
6060
const sumProofSize = relevant.reduce((acc, b) => acc + b.proofSize, 0);
6161

src/types/chains.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ export const polkadotChainsConfig: ChainsConfig = {
2727
Frequency: { paraId: 2091, displayName: 'Frequency' },
2828
Hashed: { paraId: 2093, displayName: 'Hashed Network' },
2929
Hydration: { paraId: 2034, displayName: 'Hydration' },
30+
Hyperbridge: { paraId: 3367, displayName: 'Hyperbridge' },
3031
Integritee: { paraId: 3359, displayName: 'Integritee Network' },
3132
Interlay: { paraId: 2032, displayName: 'Interlay' },
3233
InvArch: { paraId: 3340, displayName: 'InvArch' },

0 commit comments

Comments
 (0)