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

Support cloudflare wrangler #7290

Closed
bkniffler opened this issue Nov 23, 2023 · 4 comments
Closed

Support cloudflare wrangler #7290

bkniffler opened this issue Nov 23, 2023 · 4 comments
Labels
enhancement New feature or request

Comments

@bkniffler
Copy link

What is the problem this feature would solve?

Error when trying to use wrangler, e.g. to run a test for a cloudflare worker.

Message

[bun] Warning: worker_threads.Worker option "execArgv" is not implemented.

Code example

import {expect, test} from 'bun:test'
import {unstable_dev} from 'wrangler'
import {join} from 'path'

const root = join(__dirname, '../../..')
test('durable-objects', async () => {
  const handler  = await unstable_dev(join(root, 'src/index.ts'), {
    config: join(root, 'wrangler.toml'),
    experimental: {
      disableExperimentalWarning: true,
      disableDevRegistry: true
    },
    bundle: false,
    compatibilityDate: '2023-10-10',
    local: true,
    logLevel: 'debug',
  });
  const res =await handler.fetch('http://worker.dev', {});
  const json = await res.json();
  expect(json).toEqual({hello: 'world'});
});

What is the feature you are proposing to solve the problem?

Add support for execArgv and thus for wrangler.

What alternatives have you considered?

Use vitest/jest.

@bkniffler bkniffler added the enhancement New feature or request label Nov 23, 2023
@bkniffler
Copy link
Author

Here is the execArgv support issue: #4130

@Electroid
Copy link
Contributor

Duplicate of #4130

@Electroid Electroid marked this as a duplicate of #4130 Nov 24, 2023
@Electroid Electroid closed this as not planned Won't fix, can't repro, duplicate, stale Nov 24, 2023
@bkniffler
Copy link
Author

Still not working yet unfortunately, waiting for #8867 to work for unstable_dev, for anyone stumbling upon this

@bkniffler
Copy link
Author

As well as #4165

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

No branches or pull requests

2 participants