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

Website auto-publish fails on 9.0 branch #2135

Open
ibgreen opened this issue Jul 21, 2024 · 3 comments
Open

Website auto-publish fails on 9.0 branch #2135

ibgreen opened this issue Jul 21, 2024 · 3 comments
Labels

Comments

@ibgreen
Copy link
Collaborator

ibgreen commented Jul 21, 2024

Actual Result

  • deploy
    Unexpected input(s) 'cache', valid inputs are ['volta-version', 'node-version', 'npm-version', 'yarn-version', 'package-json-path', 'variant', 'registry-url', 'scope', 'token', 'always-auth']

Expected Result

New website is published

Reproduce Steps

Published a new version

Background

@ibgreen ibgreen added the bug label Jul 21, 2024
@felixpalmer
Copy link
Collaborator

The error reported is due to yarn bootstrap, invoked in the website workflow:

Usage Error: Couldn't find the node_modules state file - running an install might help (findPackageLocation)

I could repro this locally by rm -rf node_modules and then yarn bootstrap.

If I run yarn && yarn bootstrap it works. So this could be a fix, although it is a mystery why it is necessary given that yarn bootstrap is defined as "yarn && ocular-bootstrap".

Note that in the test workflow we invoke yarn install before yarn bootstrap

@ibgreen
Copy link
Collaborator Author

ibgreen commented Jul 29, 2024

Thanks for looking into this.

yarn && yarn bootstrap works. And yarn bootstrap is defined as "yarn && ocular-bootstrap".

Yes, unfortunately, this is a pattern, I spent a bunch of time upgrading to yarn 4 to reduce install times but now we have to run yarn so many times instead, defeating the gains. (in fact I suspect that ocular-bootstrap in turn also calls yarn? )

Note that in the test workflow we invoke yarn install before yarn bootstrap

Yes I recall facing a similar problem there, so probably I added this to fix it.


If yarn 4 doesn't want to accept commands before a clean install, one solution might be to always require a separate call to yarn, and stop trying to have out various bootstrap commands call yarn?

@Pessimistress food for thought...

@donmccurdy
Copy link
Collaborator

We might not need yarn bootstrap today, with Yarn v4 and Lerna v8. It looks like the bootstrap script is mostly now a workaround for an old issue from Yarn v1. Lerna bootstrap and link commands were removed in Lerna v7, to let Yarn workspaces handle it. In that case only yarn and yarn build would be necessary.

Regardless — I do somewhat prefer letting yarn be a distinct step.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants