Skip to content

Commit

Permalink
WIP: with a3p use-lo-bundle-cost, we don't need to lower it
Browse files Browse the repository at this point in the history
  • Loading branch information
dckc committed Mar 7, 2024
1 parent 395204c commit 15fe856
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 42 deletions.
35 changes: 0 additions & 35 deletions contract/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,41 +27,6 @@ mint100:
yarn --silent agops vaults open --wantMinted 100 --giveCollateral 100 >/tmp/want-ist.json && \
yarn --silent agops perf satisfaction --executeOffer /tmp/want-ist.json --from user1 --keyring-backend=test

# https://agoric.explorers.guru/proposal/61
lower-bundle-cost: bundles/lower-bundle-cost.json ./scripts/voteLatestProposalAndWait.sh
agd tx gov submit-proposal param-change bundles/lower-bundle-cost.json \
$(SIGN_BROADCAST_OPTS) \
--from user1
./scripts/voteLatestProposalAndWait.sh
# agd query swingset params


bundles/swingset-params.json:
mkdir -p bundles/
agd query swingset params -o json >$@

.ONESHELL:
bundles/lower-bundle-cost.json: bundles/swingset-params.json
@read PARAMS < bundles/swingset-params.json; export PARAMS
node - <<- EOF >$@
const storageByte = '20000000';
const paramChange = {
title: 'Lower Bundle Cost to 0.02 IST/Kb (a la mainnet 61)',
description: '0.02 IST/Kb',
deposit: '10000000ubld',
changes: [{
subspace: 'swingset',
key: 'beans_per_unit',
value: '...',
}],
};
const params = JSON.parse(process.env.PARAMS);
const ix = params.beans_per_unit.findIndex(({key}) => key === 'storageByte');
params.beans_per_unit[ix].beans = storageByte;
paramChange.changes[0].value = params.beans_per_unit;
console.log(JSON.stringify(paramChange, null, 2));
EOF

# Keep mint4k around a while for compatibility
mint4k:
make FUNDS=1000$(ATOM) fund-acct
Expand Down
1 change: 0 additions & 1 deletion contract/scripts/run-chain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ waitForBlock 2
approveProposals &

make -C /workspace/contract mint100
make -C /workspace/contract lower-bundle-cost

# bring back chain process to foreground
wait
5 changes: 0 additions & 5 deletions contract/scripts/voteLatestProposalAndWait.sh

This file was deleted.

2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: '3.5'
services:
agd:
# cf. https://github.com/Agoric/agoric-3-proposals
image: ghcr.io/agoric/agoric-3-proposals:latest
image: ghcr.io/agoric/agoric-3-proposals:use-lo-bundle-cost
platform: linux/amd64
ports:
- 26656:26656
Expand Down

0 comments on commit 15fe856

Please sign in to comment.