Dennis Dudek
1bb211df56
bustDirCache on FileSystemRouter.reload & fix of dir_cache keys in windows ( #15091 )
...
Co-authored-by: dave caruso <me@paperdave.net >
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com >
2024-11-27 12:21:32 -08:00
Dylan Conway
62881ee36b
Redact secrets in bunfig.toml and npmrc logs ( #14919 )
2024-10-31 18:44:24 -07:00
dave caruso
514d37b3d2
kit: implement server components dev server ( #14025 )
2024-09-27 20:53:39 -07:00
Jarred Sumner
688844b472
refactor: ban std.debug.assert ( #10168 )
...
* Ban `std.debug.assert`
* Create .clangd
* Update lint.yml
* Update linter.ts
* update
* lint
* Update linter.ts
* Update linter.ts
* update
* Update linter.ts
* update
* Update linter.ts
* more
* Update install.zig
* words
* Remove UB
2024-04-11 17:52:29 -07:00
Meghan Denny
e209ae81dd
meta: ensure there's a single 'bun' import per file in zig ( #10137 )
...
* meta: ensure there's a single 'bun' import per file in zig
* undo this change in codegen
2024-04-09 22:41:07 -07:00
Dylan Conway
5934b17f00
fix(windows): fix a few more tests ( #8644 )
...
* fix regression tests
* fix fs.test.ts bigintstats
* enable transpiler cache lol
* remove failing
* fix filesystem router
* update
* fix run-unicode test
* update comment
* add updated snapshot
* fix remaining node-module-module tests
* fixup
* [autofix.ci] apply automated fixes
* fix tty tests
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-02-02 18:58:16 -08:00
Meghan Denny
be0896e204
remove while loops where a for would be more efficient ( #8131 )
...
* remove while loops where a for would be more efficient
* this needs to be a stack copy
* this can use the better loop
* this was translated wrong
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2024-01-13 19:13:54 -08:00
Meghan Denny
9846383b01
all: make bun.FileDescriptor a unique type ( #8022 )
...
* all: make bun.FileDescriptor a unique type
# Conflicts:
# src/bun.js/api/bun/socket.zig
# src/bun.js/api/bun/spawn.zig
# src/deps/uws.zig
* need this change too
* convert another bun.FD.asDir call
* more fixes + linux
* fix this size
* accidentally flipped these fd numbers
* more fixes + windows
# Conflicts:
# src/deps/uws.zig
* dont include type name in serialization
* add another TODO
* resolve review comments
* address more pr comments
* build fixes post-rebase
* another rebase fix
---------
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com >
2024-01-11 19:59:48 -08:00
dave caruso
369e3022e4
chore: upgrade zig to 0.12.0-dev.1828+225fe6ddb ( #7671 )
...
* chore: upgrade zig to 0.12.0-dev.1828+225fe6ddb
* open as iterable
* fix building identifier cache
* fix windows build
* fix linux build
* fix linux build
2023-12-16 00:14:15 -08:00
Jarred Sumner
351810e5bc
Switch to std.sort.pdq from std.sort.block ( #7574 )
...
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-12-10 19:49:21 -08:00
Jarred Sumner
e2a17344dc
just kernel32 things ( #4354 )
...
* just kernel32 things
* more
* Update linux_c.zig
* Update windows_c.zig
* Add workaround
Workaround https://github.com/ziglang/zig/issues/16980
* Rename http.zig to bun_dev_http_server.zig
* Rename usages
* more
* more
* more
* thanks tigerbeetle
* Rename `JSC.Node.Syscall` -> `bun.sys`
* more
* woops
* more!
* hmm
* it says there are only 37 errors, but that's not true
* populate argv
* it says 32 errors!
* 24 errors
* fix regular build
* 12 left!
* Still 12 left!
* more
* 2 errors left...
* 1 more error
* Add link to Tigerbeetle
* Fix the remainign error
* Fix test timeout
* Update syscall.zig
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-08-28 04:39:16 -07:00
Jarred Sumner
943a664224
Remove most C API usages, add debugger pretty printers for Headers, URLSearchParams, FormData, Worker, EventTarget ( #4187 )
...
* Add pretty printers for `Headers`, `URLSearchParams`, and `FormData`
* [untested] Add way to code generate getInternalProperties
* bump
* Bump Webkit
* Ref the event loop while loaded
* wip
* checkpoint
* another checkpoint
* The code has been written
* Fixup exports
* Fix all the errors
* Fix bug
* [console.log] Fix bug when printing non-reified types missing values
* Fix loading hash table
* fix plugin
* Fix ref & unref
* auto-unref
* various fixes
* Update bun.zig
* Set toStringTag
* Delete code for macro JSX
* Delete code for `bun dev` HTTP JS
* Move Bun.serve to C++ API
* Delete JSC C API code
* ✂️ 💀 code
* Use JSC C++ for `confirm`, `Crypto`, `prompt`, `alert`
* more dead code
* Update exports.zig
* Use JSC C++ API for FFI
* Remove remaining usages
* Remove remaining usages
* Update ffi.ts
* Update InternalModuleRegistryConstants.h
* draw the rest of the owl
* Update webcore.zig
* bind it
* Fix performance regression in crypto.randomUIUD()
* Update js_parser.zig
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-08-18 19:58:03 -07:00
Dylan Conway
661355546a
zig upgrade ( #3667 )
...
* upgrade
* more fixes
* Bump Zig
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-07-18 01:20:20 -07:00
Dylan Conway
5fa13625a1
upgrade zig to v0.11.0-dev.3737+9eb008717 ( #3374 )
...
* progress
* finish `@memset/@memcpy` update
* Update build.zig
* change `@enumToInt` to `@intFromEnum` and friends
* update zig versions
* it was 1
* add link to issue
* add `compileError` reminder
* fix merge
* format
* upgrade to llvm 16
* Revert "upgrade to llvm 16"
This reverts commit cc930ceb1c .
---------
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com >
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-21 23:38:18 -07:00
Jarred Sumner
e422c849d5
Fix bug in Bun.build() where it wouldn't pick up changes to directories on rebuilds ( #2824 )
...
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-05-08 21:14:56 -07:00
dave caruso
96e113f41c
bundler tests: rest of default.test.ts and starting jsx tests ( #2765 )
2023-04-28 21:08:48 -07:00
Jarred Sumner
4b24bb464c
Make Bun.build more reliable ( #2718 )
...
* One possible implementation to make `Bun.build` work better
* Pass allocator in
* Make our temporary buffers a little safer
* rename
* Fix memory corruption in symbol table
* Add support for deferred idle events in ThreadPool
* Free more memory
* Use a global allocator FS cache
* more `inline`
* Make duping keys optional in StringMap
* Close file handles more often
* Update router.zig
* wip possibly delete this commit
* Fix memory issues and reduce memory usage
* > 0.8
* Switch to AsyncIO.Waker and fix memory leak in JSBundleCompletionTask
* We don't need to clone this actually
* Fix error
* Format
* Fixup
* Fixup
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-04-22 19:44:23 -07:00
Jarred Sumner
ea47ed0ee5
Fix broken autocomplete
2023-04-19 00:01:27 -07:00
Alex Lam S.L
e887a064fb
prefer bun.copy() over std.mem.copy() ( #2152 )
2023-02-24 05:53:26 -08:00
Dylan Conway
3f04f8d0a6
Upgrade Zig ( #2151 )
...
* fixup
* Upgrade Zig
* Remove bad assertion
* strings
* bump
* mode -> optimize
* optimize
* Linux build
* Update bindgen.zig
2023-02-23 23:57:19 -08:00
Jarred Sumner
a345efd270
Fix getFdPath when /proc/fd is not mounted
2023-01-16 13:59:52 -08:00
Jarred SUmner
168bb1427f
move more things
2023-01-13 11:38:16 -08:00
Alex Lam S.L
270b07e85e
use strings.hasPrefixComptime() ( #1755 )
2023-01-10 05:35:20 -08:00
Jarred Sumner
c0dd284136
Upgrade to latest Zig ( #1610 )
...
* @min and @max
* builtins and some trivial ones
* Most of them
* more
* more!
* More Progress
* wip
* Update tagged_pointer.zig
* Update http_client_async.zig
* Most of the iterable dir changes
* alright
* Remove usages of deprecated formatters
* 📷
* fmt
* Update shimmer.zig
* wip
* wip
* wip
* progress
* more
* Latest
* stuck on error
* latest
* workaround stage2
* wip
* Update string_immutable.zig
* wip
* Migrate `Dirent` and `require("fs')` to use JSC<>Zig bindings
* Fix build errors
* Fixup most of the test failures
* Fix `make headers`
* Fix "outside package path" error
* Fixup aligned alloc
* Add missing file
* linux
* More linux fixes
* use latest peechy
* Fix transpiler test failure
* Forgot about these
* Fixup test failure
* Update node-timers.test.ts
* [node:htt] Fix `undefined is not an object` error
Fixes https://github.com/oven-sh/bun/issues/1618
* Update http.exports.js
* Make this test less flaky
* fix hashes
* Fix hex formatting and zls issues
* Download zig version
* Update Dockerfile
* Update Dockerfile
* Update uws
* Update Dockerfile
* Set llvm version
* Update README.md
* Update uws
* Update Dockerfile
* Update io_linux.zig
* Update bun.zig
* Log output
* workaround strange @cInclude error
* Make ffi tests better
* Don't use cImport
* Update c.zig
* Update c-bindings.cpp
* call setOutputDir
* Update Dockerfile
* Use a longer name
* latest
* Update serve.test.ts
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
Co-authored-by: Veikka Tuominen <git@vexu.eu >
2022-12-28 00:51:22 -08:00
Jarred Sumner
714ce7619d
[internal] Make string comparisons faster
2022-12-04 06:53:53 -08:00
Jarred Sumner
7b70ed52fa
[bun bun] Fix incorrect package.hash
2022-12-01 21:37:25 -08:00
Jarred Sumner
b631ea7d72
import everything from "bun" where possible
2022-11-29 02:42:56 -08:00
Jarred Sumner
d21aee5143
Introduce Bun.FileSystemRouter API
2022-11-22 02:13:03 -08:00
Jarred Sumner
93b663e43d
New Zig <> C++ bindings generator. +20% faster HTTP server
2022-08-17 07:37:14 -07:00
Jarred Sumner
77a0f335cb
wip ReadableStream for HTTP(s) Server
2022-06-26 06:01:22 -07:00
Jarred Sumner
729d445b68
change the directory structure
2022-06-22 23:21:48 -07:00
Jarred Sumner
7a978f9381
move some code around
2022-03-17 01:28:56 -07:00
Jarred Sumner
5aae8726ef
Switch to std.HashMap for DirEntry store
2022-03-14 23:40:17 -07:00
Jarred Sumner
701d6ec45d
rename _global -> bun
2022-03-08 18:54:54 -08:00
Jarred Sumner
51fbbea1d3
upgrade zig
2022-03-04 00:20:22 -08:00
Jarred Sumner
50560e169c
WASM
2022-02-27 23:20:10 -08:00
Jarred Sumner
931670b7cb
Wrap some usages of assert in a conditional
...
See https://github.com/ziglang/zig/issues/10942
2022-02-21 16:27:44 -08:00
Jarred Sumner
e75c711c68
Upgrade to latest Zig, remove dependency on patched version of Zig ( #96 )
...
* Prepare to upgrade zig
* zig fmt
* AllocGate
* Update data_url.zig
* wip
* few files
* just headers now?
* I think everything works?
* Update mimalloc
* Update hash_map.zig
* Perf improvements to compensate for Allocgate
* Bump
* 📷
* Update bun.lockb
* Less branching
* [js parser] Slightly reduce memory usage
* Update js_parser.zig
* WIP remove unused
* [JS parser] WIP support for `with` keyword
* Remove more dead code
* Fix all the build errors!
* cleanup
* Move `network_thread` up
* Bump peechy
* Update README.md
2021-12-30 21:12:32 -08:00
Jarred Sumner
336a4b6ac2
Prepare to run unit tests & remove some dead code ( #92 )
...
* Remove some dead code
* 💀 code
* Fix the zig tests
* [JS Printer] Print integers faster & less scientific notation on decimals
* 💀 dead code
* skip
* Run all the unit tests
2021-12-27 18:06:31 -08:00
Jarred Sumner
8d03e0cf02
[router] Improve test coverage & handle case-sensitive static routes better
2021-11-16 21:26:37 -08:00
Jarred Sumner
265b1035f4
[router] Fix case sensitivity bug with route params
2021-11-16 16:57:02 -08:00
Jarred Sumner
8e0230b756
[router] Tweak sorting order & update routing tests
2021-11-16 16:33:33 -08:00
Jarred Sumner
478273e044
[router] Update router tests
2021-11-16 15:34:22 -08:00
Jarred Sumner
4a09ad51f0
[router] Fix bug with dynamic route params for route segments in the middle
2021-11-16 15:32:50 -08:00
Jarred Sumner
5bef1b46d3
[router] small cleanup
2021-11-16 15:31:47 -08:00
Jarred Sumner
3bec430192
[router] Fix edgecase with trailing slashes in directory path
2021-11-16 15:29:52 -08:00
Jarred Sumner
e69f8c36d2
[router] Don't log the route names since that's not necessary anymore
2021-10-25 17:06:38 -07:00
Jarred Sumner
4e3aa3c289
Fix index + static route
2021-10-20 05:12:01 -07:00
Jarred Sumner
58b196c583
rewrote most of the router
2021-10-20 04:18:29 -07:00
Jarred Sumner
3dc53c3d13
Starting to rewrite the router to fix some bugs and support catch-all + optional routes
2021-10-18 23:55:17 -07:00