Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wallet factory upgrade 2 branch #8593

Merged
merged 2 commits into from
Dec 15, 2023

Conversation

mhofman
Copy link
Member

@mhofman mhofman commented Dec 1, 2023

refs: #8578

Description

This prepares the dev-upgrade-wallet-factory-2 branch for the wallet factory core eval. The branch is based on release-mainnet1B after agoric-upgrade-13.

Security Considerations

None

Scaling Considerations

None

Documentation Considerations

None

Testing Considerations

Docker upgrade tests are empty in this branch for lack of core eval testing framework

Upgrade Considerations

The dev branch should be merged back to the release-mainnet1B branch before generating the release artifacts.

@mhofman mhofman added the force:integration Force integration tests to run on PR label Dec 1, 2023
@mhofman mhofman requested review from turadg and dckc December 1, 2023 17:23
@mhofman mhofman changed the title Mhofman/8578 wallet factory 2 Wallet factory upgrade 2 branch Dec 1, 2023
@@ -1,27 +1,20 @@
# Defaults
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals@sha256:ac10c09b5927d759d37b1525b5a0bc4aeb3034df8d0f0fbb15b51203555ffb1b
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agoric/agoric-3-proposals#33 merged. I guess this isn't main because that flow is failing?

Please leave a comment here about why it isn't main as it should be. We should unbreak that.

Suggested change
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33
// Once https://github.com/Agoric/agoric-3-proposals/pull/37 merges, s/pr33/main
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even if it was pushed to the main tag, I do not feel confident using main until Agoric/agoric-3-proposals#25 is resolved.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think your concern is about this CI starting to fail once main includes the upgrade being tested here.

So even after 25, you wouldn't want :main, right? You'd want :upgrade12 or something like that.

Given that I propose a different comment.

Suggested change
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33
# Don't use `:main` because once this upgrade is incorporated into it, this test would break
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33


# DEST (TEST)
#this is agoric-upgrade-12 / multi-collateral, etc.
#this is wallet-factory-upgrade
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't need to distinguish now that there's one DEST

Suggested change
#this is wallet-factory-upgrade

ARG DEST_IMAGE
FROM ${DEST_IMAGE} as agoric-upgrade-12
FROM ${DEST_IMAGE} as wallet-factory-upgrade
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

similarly, this stage doesn't need a name now

Suggested change
FROM ${DEST_IMAGE} as wallet-factory-upgrade
FROM ${DEST_IMAGE}

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the name is still used as a target for the Makefile, which I haven't changed that drastically.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. We can clean this up when migrating on top of #8635

Comment on lines 8 to 13
# BASE
FROM ${BASE_IMAGE} as base-wallet-factory-upgrade
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this isn't doing any work now. better to inline…

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Inlining didn't work. Apparently COPY --from doesn't like variables...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah. then how about,

Suggested change
# BASE
FROM ${BASE_IMAGE} as base-wallet-factory-upgrade
# BASE stage for the `COPY --from` below
FROM ${BASE_IMAGE} as base

packages/deployment/upgrade-test/Dockerfile Show resolved Hide resolved
agoric-upgrade-12: propose-agoric-upgrade-12
$(BUILD) --target agoric-upgrade-12 -t $(REPOSITORY):agoric-upgrade-12$(TAG_SUFFIX)
wallet-factory-upgrade:
$(BUILD) --target wallet-factory-upgrade -t $(REPOSITORY):wallet-factory-upgrade
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

being last, it's the default target

Suggested change
$(BUILD) --target wallet-factory-upgrade -t $(REPOSITORY):wallet-factory-upgrade
$(BUILD) -t $(REPOSITORY):wallet-factory-upgrade

Comment on lines 7 to 21
test.before(async t => {
await mintIST(GOV1ADDR, 12340000000, 10000, 2000);
});

test.skip('Open Vaults', async t => {
const currentVaults = await agops.vaults('list', '--from', GOV1ADDR);
t.is(currentVaults.length, 5);

// TODO get as return value from openVault
const vaultId = 'vault6';
await openVault(GOV1ADDR, 7, 11);
await adjustVault(GOV1ADDR, vaultId, { giveMinted: 1.5 });
await adjustVault(GOV1ADDR, vaultId, { giveCollateral: 2.0 });
await closeVault(GOV1ADDR, vaultId, 5.75);
});
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there are no actions to perform.

this test and its prep should move to post.test.js

Copy link
Member

@dckc dckc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I haven't learned how Dockerfiles work - especially this one - well enough to review this.

If it's important that I review this more thoroughly, let's please discuss it.

ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals@sha256:ac10c09b5927d759d37b1525b5a0bc4aeb3034df8d0f0fbb15b51203555ffb1b
ARG BASE_IMAGE=ghcr.io/agoric/agoric-3-proposals:pr33
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:main isn't on target for this?

pr33, while more readable than a hash, seems somewhat fragile. "pr33" in a comment and a hash in the code would make more sense to me.

not critical

packages/deployment/upgrade-test/Dockerfile Show resolved Hide resolved
@@ -1,25 +1,23 @@
# Defaults
# Use a stable base image to prevent this test from breaking when
# new upgrade proposals are added to a3p.
# TODO: pr-33 is upgrade-12, use the upgrade-13 PR once it exists
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still working on the upgrade-13 PR

@mhofman mhofman requested a review from turadg December 14, 2023 22:48
Copy link
Member

@turadg turadg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No concerns here. I expect this will reach a3p before being proposed on agoric-3, and that will use the design in #8635

ARG DEST_IMAGE
FROM ${DEST_IMAGE} as agoric-upgrade-12
FROM ${DEST_IMAGE} as wallet-factory-upgrade
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. We can clean this up when migrating on top of #8635

@mhofman
Copy link
Member Author

mhofman commented Dec 14, 2023

I expect this will reach a3p before being proposed on agoric-3, and that will use the design in #8635

We would need to cherry-pick #8635 into the release branch, which I'm totally ok with, but right now I don't want to block on that. So I expect this to land on the release branch first.

Copy link
Member

@turadg turadg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I clicked the wrong radio button somehow.

No concerns here

That means I approve :)

@mhofman mhofman force-pushed the mhofman/8578-wallet-factory-2 branch from 552879a to f1732a4 Compare December 15, 2023 15:06
@mhofman mhofman merged commit c044454 into dev-upgrade-wallet-factory-2 Dec 15, 2023
60 checks passed
@mhofman mhofman deleted the mhofman/8578-wallet-factory-2 branch December 15, 2023 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
force:integration Force integration tests to run on PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants