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

Remove unused undici import #1387

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

hectorhdzg
Copy link
Member

Apparently this was added by mistake as Headers is already defined in node types, removing to fix #1386

@JacksonWeber
Copy link
Contributor

I believe the reason the Node 16 tests are failing is that instanceof doesn't just use the type (which we could get from the @node/types 18.0.0 package) but requires a value, which explains why pulling the definition of the Header class from undici fixed this in Node 16 environments. We can either have an explicit dependency on undici (it's already pulled in as a dependency of the @azure/functions package) to solve the issue with yarn, or I can define a type-guard to check for the properties of the Headers type without the import.

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.

Undeclared dependency “undici”
2 participants