aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-09-21double assertiondave/assert-double-is-validGravatar dave caruso 5-11/+14
2023-09-21Fix test failures (#5862)Gravatar Jarred Sumner 2-12/+4
* Fix test failures * Fixes #5851 --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-21On Linux, respect memory limit from cgroups (#5849)Gravatar Jarred Sumner 3-56/+69
* Implement `process.constrainedMemory()` * Add a comment * Handle max * Missing header * We can use WTF::ramSize now * Update WebKit * Update ZigGlobalObject.cpp * WebKit * :scissors: --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-21Revert "feat(encoding): support BOM detection (#5550)"Gravatar Jarred Sumner 4-47/+7
This reverts commit 5f66b4e729105286863a13955b1ed8897b45210e. This caused test failures in text-encoder. cc @WingLim
2023-09-21Fixes #5859jarred/5859Gravatar Jarred Sumner 1-6/+13
2023-09-20fix: add check to sqlite extension loading logic (#5773)Gravatar Liz 2-0/+9
The sqlite3 logic to dynamically load extensions can be disabled to save space, which macos does by default. sqlite3 provides a api to check for these compile time settings at runtime, we can use that to throw a js error rather then crashing. It is worth noting though that the api to check for these settings at runtime itself can be disabled through SQLITE_OMIT_COMPILEOPTION_DIAGS but this seams to be a edge case.
2023-09-20fix(console.log): change default depth from 8 to 2 (#5839)Gravatar Jibran Kalia 1-1/+1
This make it as the same default depth in Node. Source: https://github.com/nodejs/node/blob/480ab8c3a40451d5ea459dd35b4039679b26e195/doc/api/console.md?plain=1#L285
2023-09-20fix(run): interpret extensionless files as typescript (#5711)Gravatar dave caruso 2-10/+17
* test * gadsgsagdsa * add better err msg * r * oops * ok
2023-09-20fix(ffi) fix size limit for dlopen (#5516)Gravatar Ciro Spaciari 2-3/+7
* fix size limit * 63 * throw error * ffi.test.js * add macos tests * oops
2023-09-20feat(encoding): support BOM detection (#5550)Gravatar WingLim 4-7/+47
* fix(encoding): export `getIgnoreBOM` * feat(encoding): support ignoreBOM * fix(encoding): not replace BOM to 0xFFFD * chore: use strict equal
2023-09-20feat(node:dns): implement `dns.lookupService` (#5613)Gravatar Ai Hoshino 2-4/+305
* feat(node:dns): implement dns.lookupService Close: #4347 * fix flags * add `getSockaddr` * fix sockaddr size * flaky test
2023-09-20implement `Module.prototype._compile` (#5840)Gravatar dave caruso 3-2/+61
2023-09-20feat(runtime): implement `console._stdout` (#5842)Gravatar dave caruso 1-1/+35
* implement console._stdout * nonenum
2023-09-20Treat `undefined` value as empty in expect.toThrow (#5788)Gravatar LongYinan 1-3/+3
Fix: https://github.com/napi-rs/napi-rs/blob/main/examples/napi/__tests__/test.framework.js#L16-L19
2023-09-20add `emitDecoratorMetadata` (#5777)Gravatar Dylan Conway 1-0/+2
* some progess * needs more tests * make tests easier to debug * get metadata for constructor arg decorators * fix some things * merge `emitDecoratorMetadata` option * remove `^` * bundler tests and get option from tsconfig earlier * remove spaces * fix tests
2023-09-20Call `Error.prepareStackTrace` on `new Error().stack` (#5802)Gravatar Jarred Sumner 4-144/+217
* Always call `Error.prepareStackTrace` * Support node:vm * Remove this * Handle more cases --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-19Fixes #5769 (#5775)Gravatar Jarred Sumner 1-3/+14
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-18fix: remove unneeded branch in toJSONWithBytes (#5684)Gravatar Liz 1-5/+1
This branch resulted in the same the same statement so having the branch, is not needed
2023-09-18fix(runtime/node): Allow `new Buffer.alloc()` + Upgrade WebKit (#5699)Gravatar dave caruso 3-156/+395
* make bufferconstructor a static hash table * chore: Upgrade WebKit to 4d995edbc44062b251be638818edcd88d7d14dd7 * make it constructable now * fix comment * yippee * update CI workflows
2023-09-18Implement `node_api_create_external_string_latin1` and ↵Gravatar Jarred Sumner 2-0/+79
`node_api_create_external_string_utf16` (#5675) Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-18feat(runtime): Implement `console.Console` (#5448)Gravatar dave caruso 2-1/+35
* prototype * asdfg * It works! * okay its done now fr * self review * ok * fix * fix test --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-18Fix HTTP listen behavior being non-compliant with node (#5689)Gravatar dave caruso 1-16/+10
* Fix HTTP listen behavior being non-compliant with node * Add error code for address in use * use SystemError --------- Co-authored-by: SuperAuguste <19855629+SuperAuguste@users.noreply.github.com>
2023-09-18In `bun:sqlite`, make sure we set the number tag correctly when creating the ↵Gravatar Jarred Sumner 1-5/+10
JSValue (#5655) * Make sure we set the number tag correctly when returning values from SQLite * Add DOMJIT test * Update JSSQLStatement.cpp --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-18feat(test): Implement `arrayContaining` (#5572)Gravatar WingLim 11-3/+416
* feat(test): implement `arrayContaining` * feat: early return when expectedArray is empty * feat: add test for toEqual * chore: use `JSC::isArray` * chore: use getIndex for performance * fix: use deepEqual --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-18feat(console.log): Print annonymus when class name is unknown (#5595)Gravatar Jibran Kalia 1-1/+1
This matches the functionality in Node.
2023-09-18Add a way to disable the GC timer (#5656)Gravatar Jarred Sumner 1-2/+10
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-17Fix `make headers`Gravatar Jarred Sumner 1-0/+1
2023-09-17Workaround #5604 (#5615)Gravatar Jarred Sumner 1-8/+12
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-16fix(child_process) unref next tick so exit/close event can be fired before ↵Gravatar Ciro Spaciari 1-4/+28
application exits (#5481) * unref next tick so exit callback can be called * fmt + test * oops * add ref_count * update pending * comment and fix
2023-09-16feat(encoding): TextDecoder support undefined (#5387)Gravatar WingLim 1-0/+3
* feat(encoding): TextDecoder support undefined * chore: format test file
2023-09-16fix: node compatibility with empty path string (#4693)Gravatar MrPalixir 1-10/+2
Co-authored-by: MrPalixir <73360179+MrPalixir@users.noreply.github.com>
2023-09-16webkit upgrade (#5535)Gravatar Dylan Conway 8-10/+28
* update files * Update cold-jsc-start.cpp * bump webkit
2023-09-15mark bindingGravatar Dylan Conway 1-0/+1
2023-09-15fix(node/fs.watch): Check first char before trimming event filenames (#5505)Gravatar David Hewitt 1-11/+2
* Add failing test * fix(node/fs.watch): Don't lose first char in event * run prettier
2023-09-15fix(request) handle undefined/null/empty signal on request (#5503)Gravatar Ciro Spaciari 1-2/+1
* handle undefined/null/empty signal on request * better approach
2023-09-15Add missing visitorsbun-v1.0.2Gravatar Jarred Sumner 1-1/+3
cc @paperdave
2023-09-15feat(runtime): add `process.binding` `uv`/`natives`/`config` + make global ↵Gravatar dave caruso 26-1102/+1595
object properties lazy (#5355) * binding uv * we did that * some more bindings * fix doc * fix uv * yo * static hash table nonsense <3 * huge refactor to the global object i am not ready for merge conflicts * it works part 3 * lose --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-15Implement `URL.canParse` (#5463)Gravatar Jarred Sumner 3-2/+41
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-15Does not fix #4622 (#5452)Gravatar Jarred Sumner 1-16/+25
* Fixes #4622 * cleanup --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-15Add missing `"size"` getter to `URLSearchParams` prototypeGravatar Jarred Sumner 1-0/+1
2023-09-15dup and close file descriptors (#5341)Gravatar Dylan Conway 2-35/+41
* track one shot fds * dup fd * skip for rearm on mac * dup if fd * cleanup * force unregister on close * deinitForceUnregister * test * add prompts --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-15remove `convertToASCIILowercase`Gravatar Dylan Conway 1-1/+1
2023-09-14fix(nitro) fix sourcemaps and JSSink closing (#5422)Gravatar Ciro Spaciari 2-31/+41
* fix JSSink progress on sourcemap checking * fix sourcemaps * update JSSink fix * undo + tests --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-14fix http set cookie headers (#5428)Gravatar Dylan Conway 3-12/+112
* allow multiple set-cookie values * make it work for `getHeader` * move `getHeader` to cpp * remove set-cookie check * move `setHeader` to cpp --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-14async-ify all node:fs functions (#5360)Gravatar Jarred Sumner 4-1342/+1263
* async all node:fs functions * draw the rest of the owl * LLVM & Clang 16 --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-09-14v8 date parser tests (#5332)Gravatar Dylan Conway 1-0/+1
* Create v8-date-parser.test.js * one more test * add permalinks and enable parser in bun --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-14fix(runtime): emit `node:net` connect error event vs throw (#5336)Gravatar dave caruso 1-2/+18
* fix(runtime): emit `node:net` connect error event vs throw * oops * finally * ok * we are good
2023-09-13fix(Bun.serve) fix buffering edge case (#5152)Gravatar Ciro Spaciari 2-3/+4
* fix buffering clean * fix resolveMaybeNeedsTrailingSlash and try to fix ci/cd error * fix resolveMaybeNeedsTrailingSlash and try to fix ci/cd error * oops --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-09-13fix(runtime): make most globals configurable/deletable, allow resuming the ↵Gravatar dave caruso 4-362/+238
console iterator (#5216) * Fix #5177 * Fix #5175 * make most globals deletable/overridable * not done * cool * a * done * fix test * oops * yippee
2023-09-13fix(BunFile.slice) fix slice when length is greater than the size (#5186)Gravatar Ciro Spaciari 1-3/+5
* check the limits for file, when slicing * check eof * undo test