What version of Bun is running?
1.2.18+0d4089ea7
What platform is your computer?
Darwin 24.3.0 arm64 arm
What steps can reproduce the bug?
Any of the following (and more):
await fetch(undefined)
await fetch(123)
await fetch({toString() {return `/some_path`}})
What is the expected behavior?
Something more precise, like:
fetch() URL must have a hostname
What do you see instead?
fetch() URL must not be a blank string
Additional information
Link to offending line in Bun sources:
|
return globalObject.ERR(.INVALID_ARG_TYPE, fetch_error_blank_url, .{}).throw(); |