Skip to content

Commit

Permalink
Merge pull request #1222 from input-output-hk/chore/node-8.10-pre-upg…
Browse files Browse the repository at this point in the history
…rade

Chore/node 8.10.1 pre upgrade
  • Loading branch information
mirceahasegan committed May 15, 2024
2 parents cace9ad + e7a8d58 commit d0e1d13
Show file tree
Hide file tree
Showing 38 changed files with 12,803 additions and 10,039 deletions.
8 changes: 4 additions & 4 deletions compose/aarch64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

services:
cardano-db-sync:
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-sancho-4-0-0}
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-sancho-4-2-1}
cardano-node:
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-node:${CARDANO_NODE_VERSION:-8.9.1}
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-node:${CARDANO_NODE_VERSION:-8.10.1-pre}
ogmios:
image: ghcr.io/input-output-hk/ogmios-tracker/ogmios:v${OGMIOS_VERSION:-6.2.0}
image: ghcr.io/input-output-hk/ogmios-tracker/ogmios:v${OGMIOS_VERSION:-6.3.0}
cardano-submit-api:
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-submit-api:${CARDANO_NODE_VERSION:-8.9.1}
image: ghcr.io/input-output-hk/ogmios-tracker/cardano-submit-api:${CARDANO_NODE_VERSION:-8.10.1-pre}
10 changes: 5 additions & 5 deletions compose/common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ services:
timeout: 1s
retries: 120
start_period: 100ms
image: ghcr.io/intersectmbo/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-sancho-4.1.0}
image: ghcr.io/intersectmbo/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-sancho-4-2-1}
restart: on-failure
stop_signal: SIGINT
volumes:
Expand All @@ -128,7 +128,7 @@ services:
<<:
- *logging
- *with-postgres
image: ghcr.io/intersectmbo/cardano-smash-server:${CARDANO_DB_SYNC_VERSION:-13.1.0.2}
image: ghcr.io/intersectmbo/cardano-smash-server:${CARDANO_DB_SYNC_VERSION:-sancho-4-2-1}
command: ['--config', '/config/cardano-db-sync/config.json']
environment:
POSTGRES_HOST: postgres
Expand All @@ -149,7 +149,7 @@ services:

cardano-node:
<<: *logging
image: ghcr.io/intersectmbo/cardano-node:${CARDANO_NODE_VERSION:-8.9.1}
image: ghcr.io/intersectmbo/cardano-node:${CARDANO_NODE_VERSION:-8.10.1-pre}
command:
[
'run',
Expand All @@ -169,7 +169,7 @@ services:

ogmios:
<<: *logging
image: cardanosolutions/ogmios:v${OGMIOS_VERSION:-6.2.0}
image: cardanosolutions/ogmios:v${OGMIOS_VERSION:-6.3.0}
command:
['--host', '0.0.0.0', '--node-socket', '/ipc/node.socket', '--node-config', '/config/cardano-node/config.json']
depends_on:
Expand All @@ -185,7 +185,7 @@ services:

cardano-submit-api:
command: --config /config/cardano-submit-api/config.json --listen-address 0.0.0.0 --socket-path /ipc/node.socket $SUBMIT_API_ARGS
image: ghcr.io/intersectmbo/cardano-submit-api:${CARDANO_NODE_VERSION:-8.9.1}
image: ghcr.io/intersectmbo/cardano-submit-api:${CARDANO_NODE_VERSION:-8.10.1-pre}
ports:
- 8090:8090
restart: on-failure
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/* eslint-disable wrap-regex */
import { TxSubmissionError, TxSubmissionErrorCode } from '@cardano-sdk/core';

// TODO: LW-9890 Map cardano-submit-api to core errors
// For now this is a very superficial mapping, we should improve it in the future
const parseStringishError = (errorData: string) => {
if (/outsideofvalidity/i.test(errorData)) {
return new TxSubmissionError(TxSubmissionErrorCode.OutsideOfValidityInterval, null, errorData);
Expand Down
4 changes: 2 additions & 2 deletions packages/cardano-services/config/.gitrepo
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[subrepo]
remote = https://github.com/input-output-hk/cardano-configurations.git
branch = master
commit = a09256f7bcd2a7e7d8427175a53a7bac10ef2ca3
parent = b7e5e3fec49aca549b7cd6a8f54826b0c5402bd3
commit = fa19a63c9a2050940583b10e9f39ed02e3cf306f
parent = eaa27b7861fb098c100724e74a5cf00fda1467be
method = merge
cmdver = 0.4.6
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,16 @@
"LastKnownBlockVersion-Major": 3,
"LastKnownBlockVersion-Minor": 0,
"MaxKnownMajorProtocolVersion": 2,
"MinNodeVersion": "8.9.2",
"PeerSharing": true,
"Protocol": "Cardano",
"RequiresNetworkMagic": "RequiresNoMagic",
"ShelleyGenesisFile": "../genesis/shelley.json",
"ShelleyGenesisHash": "1a3be38bcbb7911969283716ad7aa550250226b76a61fc51cc9a9a35d9276d81",
"TargetNumberOfActivePeers": 20,
"TargetNumberOfEstablishedPeers": 50,
"TargetNumberOfKnownPeers": 100,
"TargetNumberOfRootPeers": 100,
"TargetNumberOfRootPeers": 60,
"TraceAcceptPolicy": true,
"TraceBlockFetchClient": false,
"TraceBlockFetchDecisions": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
{
"address": "backbone.mainnet.emurgornd.com",
"port": 3001
},
{
"address": "backbone.mainnet.cardanofoundation.org",
"port": 3001
}
],
"localRoots": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,16 @@
"LastKnownBlockVersion-Alt": 0,
"LastKnownBlockVersion-Major": 2,
"LastKnownBlockVersion-Minor": 0,
"MinNodeVersion": "8.9.2",
"PeerSharing": true,
"Protocol": "Cardano",
"RequiresNetworkMagic": "RequiresMagic",
"ShelleyGenesisFile": "../genesis/shelley.json",
"ShelleyGenesisHash": "162d29c4e1cf6b8a84f2d692e67a3ac6bc7851bc3e6e4afe64d15778bed8bd86",
"TargetNumberOfActivePeers": 20,
"TargetNumberOfEstablishedPeers": 50,
"TargetNumberOfKnownPeers": 100,
"TargetNumberOfRootPeers": 100,
"TargetNumberOfRootPeers": 60,
"TraceAcceptPolicy": true,
"TraceBlockFetchClient": false,
"TraceBlockFetchDecisions": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@
"LastKnownBlockVersion-Alt": 0,
"LastKnownBlockVersion-Major": 3,
"LastKnownBlockVersion-Minor": 1,
"MinNodeVersion": "8.9.2",
"PeerSharing": true,
"Protocol": "Cardano",
"RequiresNetworkMagic": "RequiresMagic",
"ShelleyGenesisFile": "../genesis/shelley.json",
"ShelleyGenesisHash": "363498d1024f84bb39d3fa9593ce391483cb40d479b87233f868d6e57c3a400d",
"TargetNumberOfActivePeers": 20,
"TargetNumberOfEstablishedPeers": 50,
"TargetNumberOfKnownPeers": 100,
"TargetNumberOfRootPeers": 100,
"TargetNumberOfRootPeers": 60,
"TestAllegraHardForkAtEpoch": 0,
"TestAlonzoHardForkAtEpoch": 0,
"TestMaryHardForkAtEpoch": 0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,23 @@
"ByronGenesisFile": "../genesis/byron.json",
"ByronGenesisHash": "785eb88427e136378a15b0a152a8bfbeec7a611529ccda29c43a1e60ffb48eaa",
"ConwayGenesisFile": "../genesis/conway.json",
"ConwayGenesisHash": "de609b281cb3d8ae91a9d63a00c87092975612d603aa54c0f1c6a781e33d6e1e",
"ConwayGenesisHash": "49ef010ff0d13b090893a919bbc22022038a8b782faa0b1561a256b781672174",
"EnableP2P": true,
"ExperimentalHardForksEnabled": true,
"ExperimentalProtocolsEnabled": true,
"LastKnownBlockVersion-Alt": 0,
"LastKnownBlockVersion-Major": 3,
"LastKnownBlockVersion-Minor": 1,
"MinNodeVersion": "8.10.0",
"PeerSharing": true,
"Protocol": "Cardano",
"RequiresNetworkMagic": "RequiresMagic",
"ShelleyGenesisFile": "../genesis/shelley.json",
"ShelleyGenesisHash": "f94457ec45a0c6773057a529533cf7ccf746cb44dabd56ae970e1dbfb55bfdb2",
"TargetNumberOfActivePeers": 20,
"TargetNumberOfEstablishedPeers": 50,
"TargetNumberOfKnownPeers": 100,
"TargetNumberOfRootPeers": 100,
"TargetNumberOfRootPeers": 60,
"TestAllegraHardForkAtEpoch": 0,
"TestAlonzoHardForkAtEpoch": 0,
"TestMaryHardForkAtEpoch": 0,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,30 @@
{
"poolVotingThresholds": {
"committeeNormal": 0.51,
"committeeNormal": 0.60,
"committeeNoConfidence": 0.51,
"hardForkInitiation": 0.51,
"motionNoConfidence": 0.51,
"ppSecurityGroup": 0.51
"motionNoConfidence": 0.60,
"ppSecurityGroup": 0.60
},
"dRepVotingThresholds": {
"motionNoConfidence": 0.51,
"committeeNormal": 0.51,
"committeeNoConfidence": 0.51,
"updateToConstitution": 0.51,
"hardForkInitiation": 0.51,
"ppNetworkGroup": 0.51,
"ppEconomicGroup": 0.51,
"ppTechnicalGroup": 0.51,
"ppGovGroup": 0.51,
"treasuryWithdrawal": 0.51
"motionNoConfidence": 0.67,
"committeeNormal": 0.67,
"committeeNoConfidence": 0.60,
"updateToConstitution": 0.75,
"hardForkInitiation": 0.60,
"ppNetworkGroup": 0.67,
"ppEconomicGroup": 0.67,
"ppTechnicalGroup": 0.67,
"ppGovGroup": 0.75,
"treasuryWithdrawal": 0.67
},
"committeeMinSize": 0,
"committeeMaxTermLength": 200,
"govActionLifetime": 10,
"govActionDeposit": 1000000000,
"dRepDeposit": 2000000,
"committeeMinSize": 7,
"committeeMaxTermLength": 73,
"govActionLifetime": 6,
"govActionDeposit": 50000000000,
"dRepDeposit": 500000000,
"dRepActivity": 20,
"minFeeRefScriptCostPerByte": 44,
"constitution": {
"anchor": {
"url": "",
Expand All @@ -33,6 +34,6 @@
"committee": {
"members": {
},
"quorum": 0
"threshold": 0.67
}
}
2 changes: 1 addition & 1 deletion packages/cardano-services/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
"tscNoEmit": "echo typescript --noEmit command not implemented yet"
},
"devDependencies": {
"@cardano-ogmios/client": "6.2.0",
"@cardano-ogmios/client": "6.3.0",
"@cardano-sdk/util-dev": "workspace:~",
"@types/bunyan": "^1.8.8",
"@types/cors": "^2.8.13",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,24 @@ export const findAccountBalance = `
JOIN epoch_param ep ON
ep.epoch_no = e."no"
ORDER BY e.no DESC LIMIT 1
),
combined_rewards AS (
SELECT
reward.amount,
reward.addr_id,
reward.spendable_epoch
FROM reward
UNION ALL
SELECT
reward_rest.amount,
reward_rest.addr_id,
reward_rest.spendable_epoch
FROM reward_rest
)
SELECT
(
SELECT COALESCE(SUM(r.amount),0)
FROM reward r
FROM combined_rewards r
JOIN stake_address ON
stake_address.id = r.addr_id
WHERE stake_address.view = $1
Expand All @@ -36,19 +49,34 @@ export const findRewardsHistory = (lowerBound?: number, upperBound?: number) =>
no AS epoch_no
FROM epoch
${whereSentence}
),
combined_rewards AS (
SELECT
reward.amount,
reward.addr_id,
reward.earned_epoch,
reward.pool_id
FROM reward
UNION ALL
SELECT
reward_rest.amount,
reward_rest.addr_id,
reward_rest.earned_epoch,
NULL as pool_id
FROM reward_rest
)
SELECT
SUM(r.amount) AS quantity,
sa."view" AS address,
r.earned_epoch AS epoch,
ph."view" as pool_id
FROM reward r
FROM combined_rewards r
JOIN stake_address sa ON
sa.id = r.addr_id AND
sa."view" = ANY($1)
JOIN epochs ON
r.earned_epoch = epochs.epoch_no
JOIN pool_hash ph ON
LEFT JOIN pool_hash ph ON
r.pool_id = ph.id
GROUP BY sa."view", r.earned_epoch, ph."view"
ORDER BY quantity ASC
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export const getMaxSupply = `
SELECT (treasury + reserves + rewards + utxo + deposits + fees) as max_supply
SELECT (treasury + reserves + rewards + utxo + deposits_stake + deposits_drep + deposits_proposal + fees) as max_supply
FROM ada_pots
ORDER BY epoch_no desc
LIMIT 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -962,7 +962,7 @@ describe('StakePoolHttpService', () => {
expect(response.pageResults).toEqual(responseCached.pageResults);
expect(response.pageResults[0].status).toEqual(Cardano.StakePoolStatus.Activating);
});
it.skip('pledgeMet false, status activating, and condition', async () => {
it('pledgeMet false, status activating, and condition', async () => {
const activating = await fixtureBuilder.getPools(1, {
with: [PoolWith.ActivatingState, PoolWith.PledgeNotMet]
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -625,15 +625,15 @@ describe('TypeormStakePoolProvider', () => {
describe('by default, result is sorted by relevance', () => {
it('with stringent search', async () => {
const response = await provider.queryStakePools({ filters: { text: 'sp11' }, pagination });
expect(response.pageResults.map(({ metadata }) => metadata?.ticker)).toEqual(['SP11', 'SP1', 'SP10']);
expect(response.pageResults.map(({ metadata }) => metadata?.ticker)).toEqual(['SP11', 'SP10', 'SP1']);
});

it('with mild search', async () => {
const response = await provider.queryStakePools({ filters: { text: 'pool 10 ' }, pagination });
expect(response.pageResults.map(({ metadata }) => metadata?.ticker).slice(0, 3)).toEqual([
'SP10',
'SP1',
'SP11'
'SP6a7',
'SP1'
]);
});
});
Expand Down

0 comments on commit d0e1d13

Please sign in to comment.