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

chore(web-components): fix devDependencies #6159

Merged
merged 3 commits into from
Sep 9, 2022
Merged

chore(web-components): fix devDependencies #6159

merged 3 commits into from
Sep 9, 2022

Conversation

samsiegart
Copy link
Contributor

refs: #6064

If this package is used from npm (not a yarn link via agoric install), when I try to build the dapp I see errors from inside the package complaining that lit and @lit-labs/react can't be found. When I do yarn link @agoric/web-components the errors go away.

I haven't verified this fix (not sure how), but I think moving these to dependencies will make the dapp transitively download them.

@samsiegart samsiegart marked this pull request as ready for review September 8, 2022 13:53
@samsiegart
Copy link
Contributor Author

samsiegart commented Sep 8, 2022

And looks like it also causes an error in netlify deploy:

[vite]: Rollup failed to resolve import "@lit-labs/react" from "node_modules/@agoric/web-components/react.js".
7:07:31 AM: This is most likely unintended because it can break your application at runtime.
7:07:31 AM: If you do want to externalize this module explicitly add it to
7:07:31 AM: `build.rollupOptions.external`
7:07:31 AM: error during build:
7:07:31 AM: Error: [vite]: Rollup failed to resolve import "@lit-labs/react" from "node_modules/@agoric/web-components/react.js".
7:07:31 AM: This is most likely unintended because it can break your application at runtime.
7:07:31 AM: If you do want to externalize this module explicitly add it to
7:07:31 AM: `build.rollupOptions.external`
7:07:31 AM:     at onRollupWarning (file:///opt/build/repo/node_modules/vite/dist/node/chunks/dep-0fc8e132.js:43721:19)
7:07:31 AM:     at onwarn (file:///opt/build/repo/node_modules/vite/dist/node/chunks/dep-0fc8e132.js:43520:13)
7:07:31 AM:     at Object.onwarn (file:///opt/build/repo/node_modules/vite/node_modules/rollup/dist/es/shared/rollup.js:23178:13)
7:07:31 AM:     at ModuleLoader.handleResolveId (file:///opt/build/repo/node_modules/vite/node_modules/rollup/dist/es/shared/rollup.js:22335:26)
7:07:31 AM:     at file:///opt/build/repo/node_modules/vite/node_modules/rollup/dist/es/shared/rollup.js:22296:26
7:07:31 AM: error Command failed with exit code 1. (https://ntl.fyi/exit-code-1)
7:07:31 AM: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
7:07:31 AM: ​
7:07:31 AM: ────────────────────────────────────────────────────────────────
7:07:31 AM:   "build.command" failed                                        
7:07:31 AM: ────────────────────────────────────────────────────────────────
7:07:31 AM: ​
7:07:31 AM:   Error message
7:07:31 AM:   Command failed with exit code 1: yarn build (https://ntl.fyi/exit-code-1)
7:07:31 AM: ​
7:07:31 AM:   Error location
7:07:31 AM:   In Build command from Netlify app:
7:07:31 AM:   yarn build
7:07:31 AM: ​
7:07:31 AM:   Resolved config
7:07:31 AM:   build:
7:07:31 AM:     command: yarn build
7:07:31 AM:     commandOrigin: ui
7:07:31 AM:     publish: /opt/build/repo/dist
7:07:31 AM:     publishOrigin: ui

@samsiegart samsiegart added the automerge:squash Automatically squash merge label Sep 8, 2022
@mergify mergify bot merged commit e223687 into master Sep 9, 2022
@mergify mergify bot deleted the fix-deps branch September 9, 2022 00:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge:squash Automatically squash merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants