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

[BUG] Miniflare testing not working due to chalk #563

Open
psteinroe opened this issue May 8, 2024 · 4 comments · May be fixed by #781
Open

[BUG] Miniflare testing not working due to chalk #563

psteinroe opened this issue May 8, 2024 · 4 comments · May be fixed by #781
Assignees
Labels
Bug Something isn't working 📦 inngest Affects the `inngest` package

Comments

@psteinroe
Copy link

Describe the bug
When running a test with mini flare (Cloudflare Worker local dev env) and Inngestjs, it always crashes with

TypeError: Cannot read properties of undefined (reading 'bold')
 ❯ Users/psteinroe/Developer/hellomateo/node_modules/inngest/helpers/consts.js?mf_vitest_no_cjs_esm_shim:146:45
 ❯ Users/psteinroe/Developer/hellomateo/node_modules/inngest/helpers/env.js?mf_vitest_no_cjs_esm_shim:9:18
 ❯ Users/psteinroe/Developer/hellomateo/node_modules/inngest/api/api.js?mf_vitest_no_cjs_esm_shim:4:15
 ❯ Users/psteinroe/Developer/hellomateo/node_modules/inngest/components/Inngest.js?mf_vitest_no_cjs_esm_shim:4:15
 ❯ Users/psteinroe/Developer/hellomateo/node_modules/inngest/index.js?mf_vitest_no_cjs_esm_shim:6:17

The reason is that for some reason, chalk.magenta is undefined. Is there any way we could change it to return a default prefix (without chalk) if its not there?

Copy link

linear bot commented May 8, 2024

@felixSchl
Copy link

Hey I am running into this as well. Did you find a workaround?

@psteinroe
Copy link
Author

Unfortunately not. We are using lambda by now so the problem isn't ours anymore.

@jpwilliams jpwilliams linked a pull request Dec 12, 2024 that will close this issue
3 tasks
@jpwilliams jpwilliams self-assigned this Dec 12, 2024
@jpwilliams jpwilliams added Bug Something isn't working 📦 inngest Affects the `inngest` package labels Dec 12, 2024
@jpwilliams
Copy link
Member

Hi folks!

Got a probable fix over at #781 (comment).
You can try it out now with:

npm install inngest@pr-781

I can't reproduce with Miniflare, so will wait for verification here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working 📦 inngest Affects the `inngest` package
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants