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
Ai Hoshino
910daeff27
Fix the crash when importing a module that does not exist. ( #4348 )
...
Close : #4240
2023-08-26 01:14:40 -07:00
Dylan Conway
097ae4e982
fix build
2023-08-24 19:05:40 -07:00
Alex Lam S.L
213f5bef9d
[install] fix stale life-cycle scripts from lockfile ( #4307 )
...
fixes #4269
2023-08-24 17:18:51 -07:00
Alex Lam S.L
e115638cba
[install] fix crash when installing package that uses loose semver pre-release ( #4302 )
...
- also fix parsing of `1.2.3pre+build`
fixes #4266
2023-08-24 17:17:48 -07:00
Jarred Sumner
c60385716b
Bunch of streams fixes ( #4251 )
...
* Update WebKit
* Don't do async hooks things when async hooks are not enabled
* Smarter scheduling of event loop tasks with the http server
* less exciting approach
* Bump WebKit
* Another approach
* Fix body-stream tests
* Fixes #1886
* Fix UAF in fetch body streaming
* Missing from commit
* Fix leak
* Fix the other leak
* Fix test
* Fix crash
* missing duperef
* Make this code clearer
* Ignore empty chunks
* Fixes #3969
* Delete flaky test
* Update bun-linux-build.yml
* Fix memory issue
* fix result body, and .done status before the last callback, dont touch headers after sent once
* refactor HTTPClientResult
* less flasky corrupted test
* oops
* fix mutex invalid state
* fix onProgressUpdate deinit/unlock
* fix onProgressUpdate deinit/unlock
* oops
* remove verbose
* fix posible null use
* avoid http null
* metadata can still be used onReject after toResponse
* dont leak task.http
* fix flask tests
* less flask close tests
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
Co-authored-by: cirospaciari <ciro.spaciari@gmail.com >
2023-08-23 14:05:05 -07:00
Jarred Sumner
ca26780b27
Deprecate loading node_modules.bun ( #4131 )
...
* Deprecate loading `node_modules.bun`
* realpath
* regenerate schema
* More
* more
* Update cli.zig
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-08-11 22:13:46 -07:00
Alex Lam S.L
a32097aa9f
implement bun update ( #4046 )
...
- analogous to `npm update`
- `bun update <name>` to refresh specified package under `package.json`
- `bun update` to refresh all package to latest versions
2023-08-07 20:11:32 -07:00
Alex Lam S.L
b93f304c06
[install] handle bun add of existing peerDependencies correctly ( #4028 )
2023-08-06 17:42:08 -07:00
Colin McDonnell
78081cbb40
Support --dev/-D and support more flags on bun install ( #3989 )
2023-08-04 20:41:16 -07:00
Alex Lam S.L
190ba6b743
[install] handle workspace:* correctly ( #3994 )
...
- parse as path so it works on unversioned workspaces
- fix missed storage of workspace version
fixes #3985
2023-08-04 18:21:13 -07:00
Alex Lam S.L
ff315a3bf2
[install] store resolved workspace path in lockfile ( #3974 )
...
- resolve cwd consistently
- speed up package diff
- update `test/bun.lockb`
fixes #3685
fixes #3958
2023-08-04 23:28:42 +03:00
Alex Lam S.L
9a2c3dea88
[install] fix stale bun.lockb on workspaces ( #3945 )
...
- handle workspaces under `--production` correctly
- fix `Makefile`
2023-08-03 12:37:29 -07:00
Jarred Sumner
a9dc5d51e3
Fixes #3884
2023-07-30 04:04:06 -07:00
Jarred Sumner
da7c1d84e9
Fix bug with /path/to/absolute/bun.lockb
2023-07-28 18:52:04 -07:00
Jarred Sumner
1490cdc4ff
Fix assertion failure and possible infinite loop when printing as yarn lock files
2023-07-28 17:40:05 -07:00
Alex Lam S.L
06503663b1
[install] handle workspace:[alias@]range ( #3819 )
2023-07-26 15:35:47 -07:00
Alex Lam S.L
961312eab0
[install] fix workspace override of aliased npm dependency ( #3784 )
2023-07-24 17:01:43 -07:00
Alex Lam S.L
07e08b086a
[install] improve workspace substitution of npm dependencies ( #3754 )
...
- respect semver ranges
2023-07-22 20:05:24 -07:00
Jarred Sumner
636cec03e1
Use WebKit's URL parser in fetch() and bun install ( #3730 )
...
* Use WebKit's URL parser in fetch() and `bun install`
* Allocate less memory
* Fix test
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-07-21 23:27:28 -07:00
Jarred Sumner
d74d95d9ab
Better error for workspace dependency not found ( #3678 )
2023-07-20 00:08:52 +03: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
Alex Lam S.L
9f031b3642
[install] handle duplicated workspace declarations gracefully ( #3662 )
...
fixes #3644
2023-07-17 16:06:31 -07:00
dave caruso
a1fb289c96
typo ( #3610 )
2023-07-11 18:50:34 -07:00
Alex Lam S.L
3d0ffc48cb
[install] fix run-time module loading ( #3510 )
...
- fix version buffer confusion
- improve workaround to handle cached modules
fixes #3507
2023-07-04 02:09:58 -07:00
Alex Lam S.L
2a73d3c793
[install] handle workspace: specifier correctly ( #3474 )
...
fixes #3430
2023-06-30 10:03:53 -07:00
Alex Lam S.L
0de5bb22af
[install] workaround run-time module loading issue ( #3432 )
2023-06-28 01:20:59 -07:00
Jarred Sumner
28f27f733b
[bun install] Implement --exact flag ( #3409 )
...
* [bun install] Implement `--exact` flag
* Rename to --save-exact
* Rename --exact to --save-exact
* Update bun-add.test.ts
* We're going with --exact as the flag name
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-26 15:51:57 -07:00
Alex Lam S.L
318879d174
[install] support trustedDependencies ( #3288 )
...
* [install] support trustedDependencies
closes #2073
* use `strings.indexOfChar()`
* use hashes instead of strings
* utilise `inline else`
2023-06-26 11:55:26 -07:00
Tiago Teixeira
d8817c2d32
Add support for install with --frozen-lockfile ( #3365 )
...
* Add support for install with --frozen-lockfile
* Add test
* Add test for frozenLockfile in config file
2023-06-25 16:43:39 -07:00
Alex Lam S.L
33903ea892
[install] fix hang in bun install --production ( #3406 )
2023-06-26 01:43:58 +03:00
Jarred Sumner
c4c714f10b
Speculative fix for regression causing a hang with install --production ( #3400 )
...
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-25 04:52:43 -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
b9c950bfb7
Improve error message for error.DependencyLoop ( #3368 )
...
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-20 19:29:47 -07:00
Jarred Sumner
bdb1b7124a
Fix crash in CJS ( #3294 )
...
* Fix crash in CJS
* Add std.heap.ArenaAllocator
* Use our arena allocator
* Reduce JS parser memory usage and make HMR faster
* Write some comments
* fix test failure & clean up this code
* Update javascript.zig
* make arena usage safer
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-13 09:15:05 -07:00
Keyhan Vakil
9a8d9b5e91
add --save argument to install ( #3277 )
2023-06-11 07:10:55 -07:00
Jarred Sumner
02eafd5019
Make cold bun install use 2x less memory ( #3271 )
...
* Make cold `bun install` use 2x less memory
In this benchmark: https://github.com/orogene/orogene/blob/main/BENCHMARKS.md
This brings us from around 2.7 GB to 1.2 GB of memory
* Address comments
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2023-06-10 15:38:09 -07:00
Alex Lam S.L
f18423cf45
[install] fix lockfile fallback for life cycle scripts ( #3265 )
2023-06-09 21:02:37 -07:00
Alex Lam S.L
dbcaa02d89
[install] fix life cycle scripts execution ( #3235 )
...
[install] fix life cycle scripts execution
- scripts from dependencies did not run during re-installation
- `bun.lockb` now contains data on life cycle scripts
- handle prior lockfile format by reading missing info from every `package.json`
- suppress spurious log output from tests
2023-06-10 03:30:43 +03:00
ytakhs
6565bd89d5
Fix to retain a newline after removing a package ( #3231 )
2023-06-09 08:42:38 -07:00
Alex Lam S.L
4c566f56c1
[install] fix .bin linking ( #3067 )
...
- causes intermittent `bun install` failures on `bun-types`
2023-05-25 21:58:30 -07:00
Jarred Sumner
63740a382b
Load .env.test, set NODE_ENV=test in bun test, load .env.{test,production,development}.local ( #3037 )
...
* Support `.env.test` & `.env.{test,production,development}.local`
* Fix bug preventing inlining of process.env.NODE_ENV by default
* Update env_loader.zig
* add env tests
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
Co-authored-by: dave caruso <me@paperdave.net >
2023-05-24 18:52:50 -07:00
Ciro Spaciari
f9831e1f6f
feat(fetch) add redirect: 'error' support ( #2845 )
...
* add redirect: 'error' support
* fix typo
* fix typo
* refactor FetchRedirect enum
* fix FetchRedirect
* updated
2023-05-10 23:55:39 -07:00
Alex Lam S.L
5fd838b9e4
bun add from root folder when call within workspaces (#2841 )
...
- ignore invalid `package.json` from parent directories
- `echo` new lines from `make` targets correctly
2023-05-10 17:22:01 +03:00
Alex Lam S.L
4ccca13001
[install] operator on root package of workspaces ( #2834 )
...
- parse `bunfig.toml` from same directory as `package.json`
- handle `--cwd` correctly
fixes #2592
2023-05-10 08:26:29 +03: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
Alex Lam S.L
c05a6744bb
[install] handle devDependencies of local folders ( #2781 )
...
fixes #2653
2023-05-01 06:41:33 +03:00
Alex Lam S.L
dd03a4f95d
[install] handle repeated install of GitHub dependency correctly ( #2780 )
...
fixes #2602
2023-04-30 09:45:08 -07:00
Alex Lam S.L
460563ee89
fix make setup ( #2731 )
...
- minor clean-ups
2023-04-25 15:13:57 +03:00
Alex Lam S.L
6e16bb67eb
[install] fix bun add on non-aliased dependency ( #2728 )
2023-04-24 17:56:43 -07:00