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

Publishable NPM packages for mainnet #8360

Merged
merged 21 commits into from
Sep 22, 2023

Conversation

mhofman
Copy link
Member

@mhofman mhofman commented Sep 21, 2023

Fixes #8366

Description

The NPM packages generated by the release-mainnet1B branch, including the ones related to agoric-upgrade-11 are broken in various ways such that they are unusable to develop a dapp using agoric-sdk packages installed from NPM. Most of these issues have been fixed in trunk since then. This backports build changes to make published NPM packages work for the release-mainnet1B branch.

In particular:

This branch was constructed as follow:

# Branch Agoric-mfig-local-npm
label base-Agoric-mfig-local-npm
pick ca530f884 ci(local-npm): resume integration testing of NPM canary
pick b4a598469 build(deps): tweak `package.json`s
pick f33f4e20e chore(telemetry): use newer `@opentelemetry` with matching versions
pick 9364d7d8e build(deps): refresh `yarn.lock`
pick ff85a7af2 fix(deploy-scripts-support): correct bare module resolution
label Agoric-mfig-local-npm
reset base-Agoric-mfig-local-npm
merge -C 33535095a Agoric-mfig-local-npm # Merge pull request #7883 from Agoric/mfig-local-npm

# Pull request #8141
pick c3b3b5fbc ci: timeout agoric-cli integration-test

# Pull request #8092
pick 014a2ed8f ci: lerna publish sequentially

# Pull request #8250
pick 82ca74656 ci(getting-started): run (but ignore) checks with `npm` and `npx`
pick a59b9355e chore(deployment): properly set `packageJson.name`
pick 793426002 ci(getting-started): break out `registry.sh`
pick dd2873ddc chore(inter-protocol): do not publish bundles to NPM

# Pull request #8314
pick eb6c9e494 ci(integration): update for `restore-node`
pick 7b684a626 fix(agoric): relax override mistake using `@endo/init/legacy.js`
pick 06aa08a10 ci(registry): publish Endo in CI registry, update versions

# Pull request #8368
pick 098bb791c build(cosmos): prevent macOS `filesize exceeds vmsize`

# Pull request #8369
pick 57802f970 ci: jobs compatibility with release branch

# Pull request #8372
pick 2b7c650ea deps(agoric): cleanup deps (#8372)

# s/("@endo/([^"]+)": ")\^/$1"/
pick 875341d0b build(deps): pin endo package versions

# s/"@endo/bundle-source": "2.5.1"/"@endo/bundle-source": "2.5.2-upstream-rollup"/
pick f01767409 build(deps): bump @endo/bundle-source

# Some manual changes
pick 8f8782bc5 ci: tweak integration checks

Security Considerations

None

Scaling Considerations

None

Documentation Considerations

None

Testing Considerations

Locally tested using scripts/registry.sh ci. Will check CI integration tests as well

Upgrade Considerations

This should have no impact on a future chain software upgrade that includes these changes.

We should follow up this PR by going through the release process and publish new NPM packages with the appropriate dist tag. agoric-upgrade-11 may be appropriate.

@mhofman mhofman added the force:integration Force integration tests to run on PR label Sep 21, 2023
@mhofman
Copy link
Member Author

mhofman commented Sep 21, 2023

@michaelfig I'm not sure what is failing in the getting-started tests.

@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch from 781c700 to 1bd0c31 Compare September 21, 2023 01:43
@michaelfig
Copy link
Member

@michaelfig I'm not sure what is failing in the getting-started tests.

It's an old @endo/bundle-source which is incompatible with NPM installs, since it is dragging in a rollup from Github (automatically running the prepare script which invokes husky, which fails):

$ npm info @endo/[email protected]
[...]
dependencies:
[...]
rollup: github:endojs/endo#rollup-2.7.1-patch-1

Fixed by @turadg in https://github.com/endojs/endo/blob/5b8e97b445e0da0c92b2496cda574321f6758c34/packages/bundle-source/package.json#L42

@mhofman
Copy link
Member Author

mhofman commented Sep 21, 2023

It's an old @endo/bundle-source which is incompatible with NPM installs

That's what I just figured out. Are we ok with just yarn support then ? Still weird that yarn doesn't puke, I guess because of a different node_modules layout.

@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch from 1bd0c31 to 04b2461 Compare September 21, 2023 16:29
@mhofman mhofman linked an issue Sep 21, 2023 that may be closed by this pull request
@michaelfig
Copy link
Member

@michaelfig I'm not sure what is failing in the getting-started tests.

Now I see the getting-started test is timing out. I'm not sure why.

@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch 2 times, most recently from 8355af4 to 58a6d49 Compare September 21, 2023 23:35
@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch from 58a6d49 to 1f26562 Compare September 22, 2023 01:08
@mhofman
Copy link
Member Author

mhofman commented Sep 22, 2023

@warner @michaelfig I have confirmed in local tests, CI and manual npx agoric@other-dev install other-dev in the KREAd repo that this seems to be working as expected. I'd like @turadg to do a little more manual testing in a dapp that using the other-dev tag (published from this PR), that no other untested issues remain.

@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch from 735b9bf to 7c596b9 Compare September 22, 2023 21:07
@mhofman mhofman force-pushed the mhofman/mainnet1B-fixed-npm-publish branch from 7c596b9 to 8f8782b Compare September 22, 2023 21:09
Copy link
Member

@warner warner left a comment

Choose a reason for hiding this comment

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

@mhofman walked me through the need for this, and the solution they picked, and it sounds good to me

@mhofman mhofman merged commit c0e1089 into release-mainnet1B Sep 22, 2023
63 checks passed
@mhofman mhofman deleted the mhofman/mainnet1B-fixed-npm-publish branch September 22, 2023 23:59
turadg added a commit to agoric-labs/KREAd that referenced this pull request Sep 25, 2023
Agoric/agoric-sdk#8360 caused errors with Endo lockdown in Ava tests
turadg added a commit to agoric-labs/KREAd that referenced this pull request Sep 25, 2023
Agoric/agoric-sdk#8360 caused errors with Endo lockdown in Ava tests
@mhofman mhofman mentioned this pull request Sep 26, 2023
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.

missing a dist-tag for a mainnet-compatible agoric-sdk
4 participants