question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

🐛 BUG: SyntaxError, missing ) after argument list

See original GitHub issue

What version of Wrangler are you using?

0.0.0-bce731a

What operating system are you using?

MacOS

Describe the Bug

When running the command: node -r dotenv/config node_modules/.bin/wrangler pages dev ./.svelte-kit/cloudflare (adapted from https://github.com/cloudflare/wrangler2/issues/190#issuecomment-1012486967 for environment variables), Wrangler2 throws a SyntaxError: missing ) after argument list error (line 2).

The ./.svelte-kit/cloudflare directory contains a _worker.js and everything works fine if ommiting the node -r part.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
petebacondarwincommented, Feb 12, 2022

As a workaround you could try using the following:

node -r dotenv/config node_modules/wrangler/bin/wrangler.js pages dev ./.svelte-kit/cloudflare

But that files does some crazy stuff to turn on --experimental-vm-modules which I believe is only required for miniflare. So if that also doesn’t work you could go one step further and try:

node -r dotenv/config node_modules/wrangler/wrangler-dist/cli.js pages dev ./.svelte-kit/cloudflare
0reactions
petebacondarwincommented, Feb 12, 2022

I haven’t seen any discussion of this other than https://github.com/cloudflare/wrangler2/issues/190, which you already mentioned.

Read more comments on GitHub >

github_iconTop Results From Across the Web

SyntaxError: missing ) after argument list - JavaScript | MDN
The JavaScript exception "missing ) after argument list" occurs when there is an error with how a function is called. This might be...
Read more >
JavaScript: SyntaxError: missing ) after argument list
I was using 'await' outside of an 'async' function and for whatever reason that results in a 'missing ) after argument list' error....
Read more >
JavaScript SyntaxError - Missing ) after argument list
This JavaScript exception missing ) after argument list occurs if there is an error in function calls. This could be a typing mistake,...
Read more >
JavaScript SyntaxError: missing ) after argument list Solution
The “SyntaxError: missing ) after argument list” error is raised if a function call cannot be evaluated correctly. To fix this error, make...
Read more >
SyntaxError: missing ) after argument list - JavaScript
The JavaScript exception "missing ) after argument list" occurs when there is an error with how a function is called. This might be...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found