Commit graph

1708 commits

Author SHA1 Message Date
Bartek Iwańczuk c3dd19c5d3
refactor(cli): remove ProgramState::permissions (#8228)
This commit removes ProgramState::permissions field.

Having permissions parsed from CLI flags stored on globally
accessible state object made it easy to mistakenly use these
permissions in situations which required "runtime" permissions.
2020-11-02 23:37:55 +01:00
Kitson Kelly d672e1405d
refactor(cli): cleanup compiler snapshot and tsc/module_graph (#8220) 2020-11-03 06:41:20 +11:00
Trivikram Kamat 40cd4db974
feat(cli): bump TypeScript to 4.0.5 (#8138) 2020-11-03 06:39:39 +11:00
Yoshiya Hinosawa 397fec63d1
fix(op_crates/web): fix URLSearchParams, malformed url handling (#8092)
Co-authored-by: Evan <c4t@tuta.io>
2020-11-02 18:58:29 +01:00
Benjamin Gruenbaum a8ca9fe7bb
test(op_crates/web): add EventTarget tests (#8205) 2020-11-02 18:42:22 +01:00
Yoshiya Hinosawa 0e5c8c03ac
add commit hash and target to long_version output (#8133) 2020-11-02 12:40:33 -05:00
Kitson Kelly 272e9b82eb
fix(cli): inject helpers when transpiling via swc (#8221)
Fixes #8212
2020-11-02 22:33:43 +11:00
Kitson Kelly fdcc78500c
refactor(cli): migrate runtime compile/bundle to new infrastructure (#8192)
Fixes #8060
2020-11-02 13:51:56 +11:00
Benjamin Gruenbaum 9397cf508e
fix(op_crates/web): make TextEncoder work with forced non-strings (#8206)
Fixes: #8201
2020-11-02 10:57:18 +11:00
Nayeem Rahman d9b8778c45
refactor(cli/permissions): Cleanup Flags to Permissions conversion (#8213) 2020-10-31 23:44:42 +01:00
Luca Casonato 03769f11b5
v1.5.1 2020-10-31 15:32:43 +01:00
Bartek Iwańczuk 2a36e2f892
upgrade: deno_doc, deno_lint, dprint, swc (#8197)
- deno_doc 0.1.14
- deno_lint 0.2.7
- dprint-plugin-typescript 0.32.7
- swc_bundler 0.14.1
- swc_ecmascript 0.13.1
2020-10-30 20:39:53 +01:00
Bartek Iwańczuk ce75101e3e
fix: Deno.fdata(), Deno.fdatasync() (#8193)
These APIs were stabilized in 1.5.0, but were
never added to the "stable" Deno namespace. This
commit fixes that.
2020-10-30 13:06:09 +01:00
Bartek Iwańczuk 4f57ca0daf
fix: panic in bundler (#8168)
This commit fixes panic in bundler which was caused
by not setting thread-local slots.
2020-10-30 12:19:49 +01:00
Nayeem Rahman 6be6c517d0
fix(cli/fmt): Strip "\\?\" prefix when displaying Windows paths (#8135) 2020-10-30 03:19:03 +01:00
Sander Hahn 1854c6f73b
fix(cli): prompt works with windows eol and eof (#8149) 2020-10-29 18:35:58 +01:00
Luca Casonato 8d99adb6c4
refactor: don't spin up V8 for deno cache (#8186) 2020-10-29 14:19:55 +01:00
Kitson Kelly b0482400c9
fix(cli): make hashes of tsconfig deterministic (#8167)
Fixes #8163
2020-10-29 21:18:18 +11:00
Yusuke Tanaka bfce376c68
refactor(watch): create single watcher for whole process (#8083)
This commit rewrites file watcher used with --watch flag.

Instead of creating new watcher after each restart, only a single
watcher is created for whole process. Additionally debouncing
mechanism has been added to prevent infinite restart loops 
if multiple files were changed in quick succession.

Co-authored-by: bartossh <lenart.consulting@gmail.com>
2020-10-28 12:41:18 +01:00
Kevin (Kun) "Kassimo" Qian 07359b7957
fix(repl): don't hang on unpaired braces (#8151)
Previously, entering a single ']' would cause repl to forever accepting
new lines, due to that `ValidationResult::Invalid` would actually be
consumed by the editor itself while continue building the lines. Instead
we should mark it as `Valid` and send the bad input for evaluation to
get the proper error from V8.

Before:
```
> ]
(you can keep entering new line here, and it will never consume input
until you Ctrl-C)
```

After:
```
> ]
Uncaught SyntaxError: Unexpected token ']'
>
```
2020-10-28 06:03:17 -04:00
Kitson Kelly e01664d0ae
fix(cli): module graph handles redirects properly (#8159)
Fixes #8154
2020-10-28 20:38:09 +11:00
Kitson Kelly 6844caa9a5
fix(cli): restore tripleslash lib refs support (#8157)
Fixes #8147
2020-10-28 11:52:20 +11:00
Bartek Iwańczuk dd01f206da
v1.5.0
Co-authored-by: Ryan Dahl <ry@tinyclouds.org>
2020-10-27 16:00:23 +01:00
Ross Weir 60cd7695ef
fix(cli): handle URL paths in Deno.mkdir() (#8140) 2020-10-27 13:21:32 +01:00
Kitson Kelly 5af1dcfe29
fix(cli): do not throw on empty typescript files (#8143)
Co-authored-by: Luca Casonato <lucacasonato@yahoo.com>
Co-authored-by: Ryan Dahl <ry@tinyclouds.org>
2020-10-27 13:19:27 +01:00
Ross Weir 9fb4931a95
fix(op_crates/web): Expose event properties in console output (#8103)
Fixes #8073
2020-10-27 09:22:03 +11:00
Kitson Kelly b03f4a4a1c
fix(cli): restore permission check on workers (#8123)
Fixes #8120
2020-10-27 06:56:00 +11:00
Luca Casonato acc201625f
chore: add bundle_no_check benchmark (#8130) 2020-10-26 19:57:29 +01:00
Ryan Dahl c4d33e8d77
fix: Use -rw-r--r-- for cache files (#8132) 2020-10-26 12:58:58 -04:00
Tim Reichen ae86cbb551
rename(std/testing): rename assert*Contains to assert*Includes (#7951)
This commit renames two assertion functions to better align with JS API:
- assertStringContains -> assertStringIncludes
- assertArrayContains -> assertArrayIncludes
2020-10-26 16:03:30 +01:00
Elias Sjögreen 305a9c04ba
feat(unstable): add Deno.systemCpuInfo() (#7774) 2020-10-26 10:54:27 -04:00
Kid 4c41ba5ad7
fix(op_crates/fetch): ensure Request.method to be string (#8100)
Ensure "Request.method" to be the default value ("GET") if 
"init.method" is not defined, which follows browser's behavior.
2020-10-26 15:02:08 +01:00
Bartek Iwańczuk 57cad53945
refactor(cli): rewrite Deno.transpileOnly() to use SWC (#8090)
Co-authored-by: Kitson Kelly <me@kitsonkelly.com>
2020-10-26 14:03:03 +01:00
Bartek Iwańczuk aebbdd5cc2
Revert "feat(lint): stabilize "deno lint" subcommand (#8075)" (#8128)
This reverts commit c5c48f845a.
2020-10-26 13:36:13 +01:00
Nayeem Rahman 822e5b6536
fix(core/runtime): Indicate exceptions in promises (#8124)
Fixes #4879
2020-10-26 14:34:00 +11:00
Ross Weir ece1e1d5f1
feat(cli): pass script args for test command (#8121)
Closes #8096
2020-10-26 11:25:43 +11:00
Kitson Kelly 3d19fb493b
fix(cli): properly handle roots with extensions that don't match media type (#8114) 2020-10-26 07:17:58 +11:00
Bartek Iwańczuk 95854b88ad
refactor(run): use new module graph for run --watch (#8085)
This commit changes how "deno run --watch" is implemented
by migrating to use ModuleGraph2.
2020-10-25 01:27:00 +02:00
Kitson Kelly dd952818bc
test(cli): ensure modules can export typed JS files (#8101)
Closes #5935
2020-10-25 07:05:33 +11:00
Kitson Kelly 117fcf61f0
test(cli): dynamic imports not evaluated until runtime (#8102)
Closes #7997
2020-10-25 07:02:11 +11:00
Bartek Iwańczuk 35f184cdcc
refactor: use of lock file in ModuleGraph2 (#8087) 2020-10-23 23:01:54 +02:00
Bartek Iwańczuk 9d36331278
Revert "feat(cli): Add deno cache --test and --worker (#7920)" (#8089)
This reverts commit be15cf285d.
2020-10-23 16:56:25 +02:00
Nayeem Rahman be15cf285d
feat(cli): Add deno cache --test and --worker (#7920) 2020-10-23 13:31:49 +02:00
Toan Nguyen 29e05bb014
fix: typos in cli and core (#8082) 2020-10-23 13:19:37 +02:00
Kitson Kelly ab898556a4
refactor(cli): move bundle check to new infrastructure (#8071) 2020-10-23 22:05:41 +11:00
Nayeem Rahman a3024a6dc5
BREAKING(cli/tsc): Enable isolatedModules by default (#8050) 2020-10-23 12:38:35 +02:00
Nikolai Vavilov f56c7868ab
docs(cli): update link to dprint-plugin-typescript (#8052) 2020-10-23 12:21:02 +11:00
Kitson Kelly 7e2c7fb6c5
refactor(cli): migrate run and cache to new infrastructure (#7996)
Co-authored-by: Ryan Dahl <ry@tinyclouds.org>
2020-10-23 11:50:15 +11:00
Bartek Iwańczuk c5c48f845a
feat(lint): stabilize "deno lint" subcommand (#8075)
This commit stabilizes "deno lint" by removing
the need to pass --unstable flag.

--unstable is still required when using --json flag.
2020-10-22 21:52:37 +02:00
Bartek Iwańczuk 9b20cfbee8
upgrade: deno_doc, deno_lint, dprint, swc (#8077)
- deno_doc 0.1.13
- deno_lint 0.2.5
- dprint-plugin-typescript 0.32.6
- swc_bundler 0.12.0
- swc_ecmascript 0.11.1
2020-10-22 20:36:06 +02:00