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

feat(workerd): use vite/module-runner from peer dep #143

Merged
merged 4 commits into from
Oct 27, 2024

Conversation

hi-ogawa
Copy link
Owner

No description provided.

Copy link
Owner Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @hi-ogawa and the rest of your teammates on Graphite Graphite

@hi-ogawa hi-ogawa marked this pull request as ready for review October 27, 2024 04:29
@hi-ogawa hi-ogawa changed the title chore: unbundle vite/module-runner feat(workerd): use vite/module-runner from peer dep Oct 27, 2024
@hi-ogawa hi-ogawa merged commit 4b928fd into main Oct 27, 2024
1 check passed
@hi-ogawa hi-ogawa deleted the refactor-no-bundle-runner branch October 27, 2024 05:13
Comment on lines +96 to +97
// avoid new AsyncFunction during import side effect
).replace(`new AsyncFunction("a", "b", body).toString()`, `""`);
Copy link
Owner Author

Choose a reason for hiding this comment

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

Otherwise we get:

service core:user:: Uncaught Error: EvalError: Code generation from strings disallowed for this context
  at vite/module-runner:21:37
  at vite/module-runner:24:3
error when starting dev server:
MiniflareCoreError [ERR_RUNTIME_FAILURE]: The Workers runtime failed to start. There is likely additional logging output above.
    at #assembleAndUpdateConfig (/home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/miniflare@3.20240925.0/node_modules/miniflare/dist/src/index.js:9828:13)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Mutex.runWith (/home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/miniflare@3.20240925.0/node_modules/miniflare/dist/src/index.js:3627:16)
    at async #waitForReady (/home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/miniflare@3.20240925.0/node_modules/miniflare/dist/src/index.js:9885:5)
    at async Miniflare2._getProxyClient (/home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/miniflare@3.20240925.0/node_modules/miniflare/dist/src/index.js:10009:5)
    at async #getProxy (/home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/miniflare@3.20240925.0/node_modules/miniflare/dist/src/index.js:10069:25)
    at async createWorkerdDevEnvironment (file:///home/hiroshi/code/personal/vite-environment-examples/packages/workerd/dist/index.js:190:14)
    at async _createServer (file:///home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/vite@https+++pkg.pr.new+vite@70bb8de_@types+node@20.14.11_terser@5.31.3/node_modules/vite/dist/node/chunks/dep-DsfahqHZ.js:51979:26)
    at async CAC.<anonymous> (file:///home/hiroshi/code/personal/vite-environment-examples/node_modules/.pnpm/vite@https+++pkg.pr.new+vite@70bb8de_@types+node@20.14.11_terser@5.31.3/node_modules/vite/dist/node/cli.js:745:20)

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

Successfully merging this pull request may close these issues.

1 participant