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

fix: implement fetch per spec #928

Merged
merged 56 commits into from
Aug 12, 2021
Merged

fix: implement fetch per spec #928

merged 56 commits into from
Aug 12, 2021

Conversation

ronag
Copy link
Member

@ronag ronag commented Aug 5, 2021

No description provided.

@ronag ronag requested a review from mcollina August 5, 2021 06:28
@ronag

This comment has been minimized.

@ronag

This comment has been minimized.

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The node-fetch copyright should be retained somewhere.

@ronag
Copy link
Member Author

ronag commented Aug 5, 2021

The node-fetch copyright should be retained somewhere.

#928 (comment)

Any suggestion of how to best do that?

@ronag
Copy link
Member Author

ronag commented Aug 5, 2021

How about 8c198e1?

@mcollina
Copy link
Member

mcollina commented Aug 5, 2021

ok for me.

@ronag ronag force-pushed the node-fetch branch 2 times, most recently from 469f55a to 7ec6fbc Compare August 5, 2021 08:44
index.js Outdated Show resolved Hide resolved
test/node-fetch/headers.js Outdated Show resolved Hide resolved
test/node-fetch/main.js Outdated Show resolved Hide resolved
test/node-fetch/main.js Outdated Show resolved Hide resolved
@ronag ronag changed the title test: port node-fetch test: port node-fetch tests Aug 5, 2021
@ronag ronag force-pushed the node-fetch branch 4 times, most recently from de12940 to 6cdaa6e Compare August 5, 2021 11:06
lib/api/api-fetch/headers.js Outdated Show resolved Hide resolved
@ronag
Copy link
Member Author

ronag commented Aug 5, 2021

Applied the file restructure/refactor to main and rebased to make it more clear what changes this PR does.

@ronag ronag force-pushed the node-fetch branch 2 times, most recently from 9179fd8 to ab64f2e Compare August 5, 2021 11:10
@GrosSacASac
Copy link

Does it mean fetch will be built in to nodejs ?

@jasnell
Copy link
Member

jasnell commented Aug 12, 2021

Not yet. nodejs/undici is still a separate module independent of node.js core. There is an active discussion happening about whether it will be vendored in but that decision has not been made yet.

@szmarczak
Copy link
Member

Just finished reviewing this. This is really good piece of art :)

@max-hk
Copy link

max-hk commented Aug 12, 2021

Not yet. nodejs/undici is still a separate module independent of node.js core. There is an active discussion happening about whether it will be vendored in but that decision has not been made yet.

Where do the discussion take place?

@trivikr
Copy link
Member

trivikr commented Aug 12, 2021

Not yet. nodejs/undici is still a separate module independent of node.js core. There is an active discussion happening about whether it will be vendored in but that decision has not been made yet.

Where do the discussion take place?

It's at nodejs/node#38533

ronag added a commit that referenced this pull request Aug 13, 2021
ronag added a commit that referenced this pull request Aug 13, 2021
* fix: request body.body regression

Refs: #928 (comment)

* fixup

* fixup

* fixup

* fixup

* fixup
KhafraDev pushed a commit to KhafraDev/undici that referenced this pull request Jun 23, 2022
* fix: implement fetch per spec

Also ports node-fetch tests.

* fixup: strict null check

* fixup: extractBody

* fixup: body used

* fixup: use instanceof Blob

* fixup

* fixup

* fixup: isBodyReadable

* fixup: localURLSOnly

* fixup: timingAllow

* fixup: timingInfo

* fixup: disregard any enqueuing

* fixup: strict cmp

* fixup: clone

* fixup: don't need to copy URL

* fix: Response init

* fixup: opaqueredirect

* fixup: avoid new Response

* fixup: abort default err

* fixup: url

* fixup: don't use body.source when writing request body

* fixup

* fixup

* fixup: fixes from review

* fixup: check valid reason phrase

* fixup: error messages

* fixup: isBuffer

* fixup: more error msg

* fixup: forbidden methods

* fixup: node stream body does not violate spec

* fixup: error msgs

* fixup

* fixup

* fixup

* fixup

* fixup: chrome compat

* fixup

* fixup: error msgs

* fixup

* fixup: timingInfo

* fixup: comments

* fixup: prettier + standard --fix

* fixup: bad port + missing cond

* fixup: docs

* fixup: move fetch to new folder

* fixup: Dispatcher.fetch doesn't exist

* fixup: link MDN docs

* fixup

* fixup: node fetch in CI

* fixup: terminate on onError

* fixup

* fixup: transmit request body algorithm

* fixup

* fixup

* fixup

* fixup
KhafraDev pushed a commit to KhafraDev/undici that referenced this pull request Jun 23, 2022
* fix: request body.body regression

Refs: nodejs#928 (comment)

* fixup

* fixup

* fixup

* fixup

* fixup
crysmags pushed a commit to crysmags/undici that referenced this pull request Feb 27, 2024
* fix: implement fetch per spec

Also ports node-fetch tests.

* fixup: strict null check

* fixup: extractBody

* fixup: body used

* fixup: use instanceof Blob

* fixup

* fixup

* fixup: isBodyReadable

* fixup: localURLSOnly

* fixup: timingAllow

* fixup: timingInfo

* fixup: disregard any enqueuing

* fixup: strict cmp

* fixup: clone

* fixup: don't need to copy URL

* fix: Response init

* fixup: opaqueredirect

* fixup: avoid new Response

* fixup: abort default err

* fixup: url

* fixup: don't use body.source when writing request body

* fixup

* fixup

* fixup: fixes from review

* fixup: check valid reason phrase

* fixup: error messages

* fixup: isBuffer

* fixup: more error msg

* fixup: forbidden methods

* fixup: node stream body does not violate spec

* fixup: error msgs

* fixup

* fixup

* fixup

* fixup

* fixup: chrome compat

* fixup

* fixup: error msgs

* fixup

* fixup: timingInfo

* fixup: comments

* fixup: prettier + standard --fix

* fixup: bad port + missing cond

* fixup: docs

* fixup: move fetch to new folder

* fixup: Dispatcher.fetch doesn't exist

* fixup: link MDN docs

* fixup

* fixup: node fetch in CI

* fixup: terminate on onError

* fixup

* fixup: transmit request body algorithm

* fixup

* fixup

* fixup

* fixup
crysmags pushed a commit to crysmags/undici that referenced this pull request Feb 27, 2024
* fix: request body.body regression

Refs: nodejs#928 (comment)

* fixup

* fixup

* fixup

* fixup

* fixup
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.