-
Notifications
You must be signed in to change notification settings - Fork 548
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
undici/lib/fetch/headers.js: Unexpected token (300:44) #1479
Comments
Can you provide steps to reproduce? We often need a reproducible example, e.g. some code that allows someone else to recreate your problem by just copying and pasting it. If it involves more than a couple of different file, create a new repository on GitHub and add a link to that. |
I think this is another issue with using Line 300 in 966a54f
|
Can we add a test? |
Isn't that a problem with the |
Updated description with a reproducible example repository. Please check. |
Digging in a little bit, it is the parser https://github.com/acornjs/acorn that seems not to support I'm going to investigate a little more and eventually open an issue about this.
|
It seems we need to wait for these 2 issues to resolve |
If you want you can open a PR to remove ?? in undici. |
think that acorn/detective should be updated to support ?? |
??= assignment converted |
Bug Description
Getting this error on serverless project.
Reproducible By
Here is an example repository for the issue: https://github.com/BRoy98/undici-serverless
Note: It happens only when
serverless-plugin-optimize
is being used to optimize the handlers.Steps to reproduce:
yarn install
yarn invoke
To disable the optimize plugin, uncomment #L10 on serverless.yml:
https://github.com/BRoy98/undici-serverless/blob/b15fb3ad50c1a2f81d1391636bc06a1794684622/serverless.yml#L10
Expected Behavior
Should run without error.
Environment
Tested on:
MacOS monterey 12.4 (21F79) and Ubuntu Latest (github actions)
Node v16.14.0 and Node v14.19.3
The text was updated successfully, but these errors were encountered: