Commit graph

3257 commits

Author SHA1 Message Date
David Sherret 5d60ee7f12
chore(test_util): use pretty_assertions::assert_eq when not pattern matching (#13965) 2022-03-15 18:15:56 -04:00
Ryan Dahl 163e1d6192
disable flakes (#13962) 2022-03-15 11:19:59 -04:00
Aaron O'Mullan 88d0f01948
feat(ops): custom arity (#13949)
Also cleanup & drop ignored wildcard op-args
2022-03-14 23:38:53 +01:00
Andreu Botella 9f494dc405
feat(ext/web): Add AbortSignal.timeout() (#13687) 2022-03-14 20:19:22 +01:00
Leo Kettmeir 5eb0e4c2df
fix: shell completion hints (#13876) 2022-03-14 19:41:35 +01:00
Andreu Botella c6bf07ec6d
fix(core): Don't override structured clone error messages from V8 (#13942)
In the implementation of structured serialization in
`Deno.core.serialize`, whenever there is a serialization error, an
exception will be thrown with the message "Failed to serialize
response", even though V8 provides a message to use in such cases.
This change instead throws an exception with the V8-provided message,
if there is one.
2022-03-14 19:35:15 +01:00
Divy Srivastava b4e42953e1
feat(core): codegen ops (#13861)
Co-authored-by: Aaron O'Mullan <aaron.omullan@gmail.com>
2022-03-14 18:44:15 +01:00
Divy Srivastava 4e3ed37037
chore: improve build times for ext/ changes (#13927) 2022-03-14 09:08:54 +05:30
Bartek Iwańczuk 9d9e60b694
feat(task): log task script (#13922)
Logs task name and associated script with additional args.
This is disabled if "--quiet/-q" flag is present.
2022-03-12 02:35:18 +01:00
Bartek Iwańczuk 1a764790f2
test: fix flaky compat tests (#13921) 2022-03-12 02:08:55 +01:00
Bartek Iwańczuk 5ebaa7943a
feat(task): allow colons in task name (#13918) 2022-03-11 18:22:45 -05:00
Bartek Iwańczuk 09ae512ccb
feat: "deno bench" subcommand (#13713)
This commit adds "deno bench" subcommand and "Deno.bench()"
API that allows to register bench cases. 

The API is modelled after "Deno.test()" and "deno test" subcommand.

Currently the output is rudimentary and bench cases and not
subject to "ops" and "resource" sanitizers.

Co-authored-by: evan <github@evan.lol>
2022-03-11 23:07:02 +01:00
David Sherret 32c059544b
chore(test): fix flaky tasks (#13916) 2022-03-11 13:20:14 -05:00
Yoshiya Hinosawa b198bfd795
refactor(core): validate promise id in refOp (#13905) 2022-03-12 01:18:49 +09:00
Filip Skokan f9b4d262b3
fix(ext/crypto): handle JWK import with "use" (#13912) 2022-03-11 20:26:16 +05:30
Bartek Iwańczuk 47f22777be
feat: "deno task" subcommand (#13725)
Co-authored-by: David Sherret <dsherret@gmail.com>
2022-03-10 20:56:14 -05:00
Bartek Iwańczuk 808f797633
fix(compat): cjs/esm interop for dynamic imports (#13792)
This commit fixes CJS/ESM interop in compat mode for dynamically
imported modules.

"ProcState::prepare_module_load" was changed to accept a list
of "graph roots" without associated "module kind". That module kind
was always hardcoded to "ESM" which is not true for CJS/ESM interop -
a CommonJs module might be imported using "import()" function. In
such case the root of the graph should have "CommonJs" module kind
instead of "ESM".
2022-03-11 02:33:02 +01:00
Geert-Jan Zwiers 8db3a9546b
fix(test): skip typechecking for blocks inside HTML comments (#13889) 2022-03-11 02:14:32 +01:00
Geert-Jan Zwiers 38e88e32b7
fix(info): print deno info paths with unescaped backslashes on windows (#13847) 2022-03-10 19:57:57 -05:00
Bartek Iwańczuk 8dc26971ec
types: add Deno.PermissionOptions and Deno.PermissionOptionsObject (#13892)
Co-authored-by: Kitson Kelly <me@kitsonkelly.com>
2022-03-11 01:35:33 +01:00
Yoshiya Hinosawa 3c11768aab
v1.19.3 2022-03-10 23:29:14 +09:00
Bartek Iwańczuk 2e30112e62
test: update expected test output for 'deno test' (#13882) 2022-03-09 14:48:20 +01:00
Divy Srivastava a5957f46ee
chore(ext/crypto): remove old todos (#13887) 2022-03-09 18:13:11 +05:30
Bartek Iwańczuk 85cb6f2563
refactor(test): use tokio::sync::mpsc::unbounded_channel (#13881)
This causes to block one less thread when running "deno test"
subcommand.
2022-03-09 01:34:31 +01:00
Bartek Iwańczuk 22dbbf75f3
refactor: add cli/display.rs module (#13879) 2022-03-09 00:19:02 +01:00
Bartek Iwańczuk 32ef9bfa47
refactor(test): don't spawn additional thread (#13877) 2022-03-08 23:42:21 +01:00
Divy Srivastava 61fbecfd5b
chore: update regex to 1.5.5 (#13875) 2022-03-08 22:00:17 +05:30
Geert-Jan Zwiers e53b6c16bc
fix(test): typecheck blocks annotated with long js/ts notations (#13785) 2022-03-08 02:10:40 +01:00
Satya Rohith 670aef5c1a
fix(ext/http): drop content-length header on compression (#13866) 2022-03-07 22:43:15 +05:30
Aaron O'Mullan f65529aa67
bench(common): base64 short strings (#13851) 2022-03-07 11:12:16 +01:00
Divy Srivastava 18a3a0ba75
bench: add base64 roundtrip (#13839) 2022-03-04 21:45:24 +01:00
Bartek Iwańczuk 060dabee4c
feat(net): add Deno.UnixConn interface (#13787) 2022-03-04 20:33:13 +01:00
Kitson Kelly d1db500cda
feat(ext/http): auto-compression of fixed response bodies (#13769)
Co-authored-by: Ryan Dahl <ry@tinyclouds.org>
Co-authored-by: Satya Rohith <me@satyarohith.com>
Co-authored-by: Luca Casonato <lucacasonato@yahoo.com>
2022-03-04 16:04:39 +11:00
Satya Rohith 975f413c46 1.19.2 (#13825) 2022-03-03 15:05:18 -05:00
Satya Rohith 95459e60f6 chore: bump crate version for 1.19.2 (#13824) 2022-03-03 15:05:18 -05:00
David Sherret e8c47755bb
chore(lsp): log more for "unexpected positions" lsp error (#13815)
Ref #13657
2022-03-03 08:06:38 +11:00
Divy Srivastava 8b2989c417
feat(ext/crypto): AES-GCM support for 128bit IVs (#13805) 2022-03-02 10:56:10 +05:30
Yoshiya Hinosawa b751e97a01
fix(repl): fix null eval result (#13804)
Co-authored-by: Satya Rohith <me@satyarohith.com>
2022-03-02 13:39:08 +09:00
Kitson Kelly 7fc5bfe51b
feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
Antonio Musolino 6a030a5396
fix(runtime): disable console color for non tty stdout (#13782) 2022-03-01 12:37:50 +09:00
Elisée Maurer a41d399f5f
chore: Add "noImplicitOverride" to config-file.v1.json (#13780) 2022-02-28 09:39:47 +11:00
Bartek Iwańczuk 7e3d9084b6
feat: Add Deno.TcpConn class, change return type from Deno.connect (#13714) 2022-02-27 15:18:30 +01:00
Bartek Iwańczuk a65ce33fab
feat(compat): CJS/ESM interoperability (#13553)
This commit adds CJS/ESM interoperability when running in --compat mode.

Before executing files, they are analyzed and all CommonJS modules are
transformed on the fly to a ES modules. This is done by utilizing analyze_cjs()
functionality from deno_ast. After discovering exports and reexports, an ES
module is rendered and saved in memory for later use.

There's a caveat that all files ending with ".js" extension are considered as
CommonJS modules (unless there's a related "package.json" with "type": "module").
2022-02-27 14:38:45 +01:00
Bartek Iwańczuk 4bea1d06c7
fix(test): use --no-prompt by default (#13777)
This commit changes "deno test" subcommand, to
always never prompt for permissions (ie. as if "deno test"
was run with "--no-prompt" flag).
2022-02-26 14:49:50 +01:00
Bartek Iwańczuk d332bf1132
feat: deno test --trace-ops (#13770)
This commit adds "--trace-ops" flag to "deno test" subcommand.

This flag enables saving of stack traces for async ops, that before were always
saved. While the feature proved to be very useful it comes with a significant performance
hit, it's caused by excessive source mapping of stack frames.
2022-02-25 16:14:46 +01:00
Yoshiya Hinosawa 111c343281
fix(cli): disable config discovery for remote script (#13745) 2022-02-25 14:39:18 +09:00
David Sherret 3b12afd072
chore: upgrade to Rust 1.59 (#13767) 2022-02-24 20:03:12 -05:00
Simon Lecoq c59152e400
feat(cli): support data url (#13667)
Closes #11141
2022-02-25 11:26:13 +11:00
David Sherret 5f28066204 1.19.1 (#13762) 2022-02-24 17:45:39 -05:00
David Sherret 4deefafdd1 chore: bump crate versions for 1.19.1 (#13760) 2022-02-24 17:45:39 -05:00