Kevin (Kun) "Kassimo" Qian
7de86ab605
cli: don't panic on Deno.close invalid argument ( #5320 )
2020-05-14 06:59:56 -04:00
Dante Calderón
c3a205bae8
Fix typos across the repo ( #5295 )
...
Corrections made:
* cli/js/tests/README.md:44:7: corrected "discoveres" to "discovers"
* cli/js/tests/chown_test.ts:111:37: corrected "priviledge" to "privilege"
* cli/worker.rs:231:56: corrected "decendants" to "descendants"
* deno_typescript/lib.rs:136:50: corrected "emmited" to "emitted"
* core/es_isolate.rs:492:67: corrected "registerd" to "registered"
* core/isolate.rs:103:28: corrected "initalize" to "initialize"
* docs/runtime.md:29:14: corrected "ect" to "etc"
* docs/tools/debugger.md:122:16: corrected "implementes" to "implements"
* std/encoding/_yaml/dumper/dumper_state.ts:57:63: corrected "everwhere" to "everywhere"
* std/encoding/csv.ts:37:43: corrected "referal" to "referral"
* std/fmt/sprintf.ts:209:20: corrected "unusuable" to "unusable"
* std/fmt/README.md:21:40: corrected "Alternativly" to "Alternatively"
* std/fmt/README.md:35:68: corrected "seperated" to "separated"
* std/fmt/README.md:179:59: corrected "provded" to "provided"
* std/mime/multipart.ts:581:46: corrected "writen" to "written"
* std/path/_globrex.ts:19:52: corrected "equivelant" to "equivalent"
* std/node/events_test.ts:447:9: corrected "asyncronous" to "asynchronous"
* std/node/events_test.ts:475:9: corrected "asyncronous" to "asynchronous"
* std/node/events_test.ts:500:29: corrected "asyncronous" to "asynchronous"
* std/node/events_test.ts:530:40: corrected "asyncronous" to "asynchronous"
* std/node/events_test.ts:555:9: corrected "asyncronous" to "asynchronous"
* tools/deno_tcp_proxy.ts:1:42: corrected "perfromance" to "performance"
* std/node/module.ts:1003:18: corrected "existend" to "existed"
2020-05-14 06:38:42 +02:00
Bartek Iwańczuk
55d2c6bd10
v1.0.0
2020-05-13 18:07:15 -04:00
Pavan Kumar
9c01403865
default to 0.0.0.0 for Deno.listen ( #5203 )
2020-05-13 09:18:41 -04:00
Kitson Kelly
3d7552af2e
Update to TypeScript 3.9 ( #4510 )
2020-05-13 08:03:04 -04:00
Bert Belder
e34a3b61f4
Make --inspect-brk pause on the first line of _user_ code ( #5250 )
2020-05-13 00:12:46 +02:00
A.E Clarence
e90c95b465
fix example of readTextFile ( #5247 )
2020-05-12 13:38:44 -04:00
Bartek Iwańczuk
053c568c8c
fix: source maps in inspector for local files ( #5245 )
...
This commit changes handling of source maps by setting proper
file URLs for "file" and "sources" fields in the source map.
2020-05-12 17:44:25 +02:00
Bartek Iwańczuk
35e8bc8de6
v1.0.0-rc3
2020-05-12 08:33:18 -04:00
Bartek Iwańczuk
d062ffc1ba
fix: source maps in inspector ( #5223 )
...
This commit fixes problems with source maps in Chrome Devtools
by substituting source map URL generated by TS compiler with
actual file URL pointing to DENO_DIR.
Dummy value of "source_map_url" has been removed from
"ScriptOrigin".
Also fixes lock file which used compiled source code to generate
lock hash; it now uses source code of the file that is
being compiled.
2020-05-11 23:48:36 +02:00
Ryan Dahl
73d8fa74c6
BREAKING: There is no public Rust API for the CLI ( #5226 )
2020-05-11 17:33:36 -04:00
Bert Belder
3cccadcf0f
Change plugin interface to prevent segfaults when unloading plugin ( #5210 )
...
Fixes: #3473
Closes: #5193
2020-05-11 22:39:13 +02:00
Ryan Dahl
fb7d7f40ed
Merge std_tests.rs into integration_tests.rs.rs ( #5228 )
...
* Remove usage of url_to_filename from integration_tests
* Make test ports not conflict with each other
2020-05-11 14:49:19 -04:00
Kitson Kelly
d16c7394cb
fix: Expose ErrorEvent globally ( #5222 )
2020-05-11 14:28:13 +02:00
Bartek Iwańczuk
32aeec9630
refactor: check permissions in SourceFileFetcher ( #5011 )
...
This PR hot-fixes permission escapes in dynamic imports, workers
and runtime compiler APIs.
"permissions" parameter was added to public APIs of SourceFileFetcher
and appropriate permission checks are performed during loading of
local and remote files.
2020-05-11 13:13:27 +02:00
Bartek Iwańczuk
0d148c6e80
fix: remove default --allow-read perm for deno test ( #5208 )
2020-05-10 23:24:36 +02:00
David Sherret
e9318aa2c0
Update to dprint 0.17.2 ( #5195 )
2020-05-10 08:49:00 -04:00
Bartek Iwańczuk
d8f5b37218
1.0.0-rc2
2020-05-09 15:37:22 -04:00
Bartek Iwańczuk
1fddcc3721
refactor(cli): unify display of errors from Rust and JS ( #5183 )
2020-05-09 21:09:46 +02:00
Kitson Kelly
670d01d012
fix: Allow multiple Set-Cookie headers ( #5100 )
2020-05-09 19:20:18 +02:00
Nayeem Rahman
7a635eda5e
fix(cli/installer): Fix concurrent env handling in tests ( #5182 )
2020-05-09 19:14:56 +02:00
Ryan Dahl
b8364a2636
BREAKING: make Deno.hostname unstable ( #5108 )
2020-05-09 12:44:35 -04:00
Ryan Dahl
eb505f8afc
Add support for X-Deno-Warning header ( #5161 )
2020-05-09 12:43:24 -04:00
Nayeem Rahman
f184332c09
BREAKING(std): reorganization ( #5087 )
...
* Prepend underscores to private modules
* Remove collectUint8Arrays() It would be a misuse of Deno.iter()'s result.
* Move std/_util/async.ts to std/async
* Move std/util/sha*.ts to std/hash
2020-05-09 08:34:47 -04:00
crowlKats
abbf0339cd
feat(upgrade): allow specifying a version ( #5156 )
2020-05-09 06:31:15 -04:00
Michał Zdunek
9790399bce
add option to lint and format only staged files ( #5172 )
2020-05-09 06:22:27 -04:00
Ryan Dahl
4e5e6da348
Add hint on how to exit REPL ( #5143 )
...
Removes exit and help commands
2020-05-08 18:58:51 -04:00
Bartek Iwańczuk
f9f10229a4
refactor: Remove cli::compilers module ( #5138 )
...
This PR removes "cli/compilers/" directory.
"cli/compilers/ts.rs" has been renamed to "cli/tsc.rs"
2020-05-08 16:18:00 +02:00
Oliver Lenehan
a08a4abac1
feat(workers): "crypto" global accessible in Worker scope ( #5121 )
2020-05-08 14:30:53 +02:00
Chris Knight
5fea4e826c
fix: correct type error text ( #5150 )
2020-05-08 14:28:46 +02:00
Bartek Iwańczuk
aca21dad1b
BREAKING: make Worker.deno unstable ( #5128 )
...
This commit makes "Worker.deno" option unstable.
Added new manual entry "docs/runtime/workers.md".
Removed stale workers tests.
2020-05-07 21:15:59 +02:00
Bartek Iwańczuk
2b66b8a03e
BREAKING: Remove support for .wasm imports ( #5135 )
...
Importing .wasm files is non-standardized therefore deciding to
support current functionality past 1.0 release is risky.
Besides that .wasm import posed many challenges in our codebase
due to complex interactions with TS compiler which spawned
thread for each encountered .wasm import.
This commit removes:
- cli/compilers/wasm.rs
- cli/compilers/wasm_wrap.js
- two integration tests related to .wasm imports
2020-05-07 20:43:27 +02:00
Yoshiya Hinosawa
93cf3bd534
feat: format deno bundle output ( #5139 )
2020-05-07 14:39:00 -04:00
Ryan Dahl
9a8d948420
Remove REPL/Windows hack ( #5136 )
2020-05-07 12:01:27 -04:00
Bartek Iwańczuk
53265fb6db
feat(bundle): add --config flag ( #5130 )
2020-05-07 17:02:03 +02:00
Bartek Iwańczuk
0ba90c8c11
fix(imports): fix panic on unsupported scheme ( #5131 )
2020-05-07 15:57:10 +02:00
Yoshiya Hinosawa
dabe88f854
fix(deno_dir): better error message ( #5120 )
...
Add better error messages when a cache subdirectory in
`DENO_DIR` cannot be created.
2020-05-07 14:32:57 +02:00
zjopy
761b7efb3b
fix(docs): add missing "deno run" ( #5126 )
2020-05-07 13:48:48 +02:00
Bert Belder
7e00b2471d
Upgrade to rusty_v8 0.4.2 / V8 8.4.300 ( #5113 )
2020-05-06 22:35:24 +02:00
Ryan Dahl
6666f1d36a
remove target_test.py ( #5112 )
2020-05-06 16:34:48 -04:00
Ryan Dahl
221221cc97
BREAKING: execPath should require allow-read ( #5109 )
2020-05-06 15:51:33 -04:00
Nikolai Vavilov
76c77bb32c
Check destination length in encodeInto ( #5078 )
2020-05-06 13:10:15 -04:00
Bartek Iwańczuk
91369841ef
refactor(ts): make processImports logic more verbose ( #5089 )
2020-05-06 16:59:43 +02:00
Ryan Dahl
2b15e53d5a
Upgrade crates ( #5104 )
2020-05-06 10:10:51 -04:00
Bartek Iwańczuk
e18aaf49cf
feat: deno doc handles default exports ( #4873 )
2020-05-06 14:48:48 +02:00
Bert Belder
e513751ee9
Clean up 'inspector_break_on_first_line' test and fix its flakiness ( #5098 )
2020-05-06 04:32:14 +02:00
Bartek Iwańczuk
2ecdbb62ae
refactor: merge TS compiler into single file ( #5091 )
2020-05-06 00:19:18 +02:00
Bartek Iwańczuk
9cd7d59840
fix(cli): fix paths in internal stack traces ( #5093 )
...
This commit updates "deno_typescript" crate to properly map
bundle entrypoint file to internal specifier.
All import specifiers were remapped from "file:///a/b/c.ts" to
"$deno$/a/b/c.ts", but that was not the case for entrypoint file
"main.ts" and "compiler.ts".
Because of that internal stack traces were inconsistent; showing
"file:///some/random/path/on/ci/machine.ts" URL in frames that
originate from "main.ts" or "compiler.ts" and "$deno$/file.ts"
for all other imports.
2020-05-05 23:13:04 +02:00
Ryan Dahl
5875bb9c0d
Simplify ProcessStdio ( #5092 )
2020-05-05 16:54:25 -04:00
Bartek Iwańczuk
cf5a39a361
refactor(ts): remove op_cache ( #5071 )
...
This PR removes op_cache and refactors how Deno interacts with TS compiler.
Ultimate goal is to completely sandbox TS compiler worker; it should operate on
simple request -> response basis. With this commit TS compiler no longer
caches compiled sources as they are generated but rather collects all sources
and sends them back to Rust when compilation is done.
Additionally "Diagnostic" and its children got refactored to use "Deserialize" trait
instead of manually implementing JSON deserialization.
2020-05-05 18:23:15 +02:00
Bert Belder
e574437922
Fix inspector hanging when task budget is exceeded ( #5083 )
...
The issue is solved by proxying websocket messages over a pair of
`futures::mpsc::unbounded` channels. As these are are implemented in
the 'futures' crate, they can't participate in Tokio's cooperative
task yielding.
2020-05-05 16:12:45 +02:00
Ryan Dahl
5f67a202ff
v1.0.0-rc1
2020-05-04 15:46:39 -04:00
David Sherret
60f2d57fb7
feat(fmt): Add deno-fmt-ignore
and deno-fmt-ignore-file
comment support ( #5075 )
2020-05-04 15:17:15 -04:00
Nayeem Rahman
8c509bd885
feat(URL): Support drive letters for file URLs on Windows ( #5074 )
...
refactor: Parse URLs more sequentially. This makes it easier to change matching behaviour depending on the protocol.
fix: Fail when a host isn't given for certain protocols.
fix: Convert back-slashes info forward-slashes.
2020-05-04 14:32:54 -04:00
Ryan Dahl
6c02b061ce
stabilize Deno.cwd and require --allow-read ( #5068 )
2020-05-04 14:23:06 -04:00
Ryan Dahl
191c59a591
Rename DenoPermissions, add abs path asserts ( #5076 )
2020-05-04 14:10:59 -04:00
Ryan Dahl
38ecabf205
Simplify ts-compiler's normalizeString ( #5072 )
2020-05-04 12:22:42 -04:00
Ryan Dahl
92c0591fcb
simplify unit tests: compiler_api, workers ( #5073 )
2020-05-04 10:40:18 -04:00
Daniel Lenksjö
1500547afa
fix: URL constructor throws confusing error on invalid scheme ( #5057 )
2020-05-04 10:06:47 -04:00
Ryan Dahl
821a4ae5fd
Make it so ts compiler doesn't call cwd op ( #5070 )
...
Removes duplicate implementation of the module resolution algorithm
2020-05-04 09:39:40 -04:00
木杉
58d0c4f9d6
fix(console): formatting misalignment on console.table ( #5046 )
2020-05-04 13:36:26 +02:00
Divya
36ad4e3b77
fix(install): Propagate --unstable flag ( #5061 )
2020-05-04 13:35:00 +02:00
Bartek Iwańczuk
a913b7a1ba
BREAKING: remove CLI 'deno script.ts' hack ( #5026 )
...
This PR removes the hack in CLI that allows to run scripts with shorthand: deno script.ts.
Removing this functionality because it hacks around short-comings of clap our CLI parser. We agree that this shorthand syntax is desirable, but it needs to be rethinked and reimplemented. For 1.0 we should go with conservative approach that is correct.
2020-05-04 13:03:30 +02:00
Kitson Kelly
7e32269f3f
Add TransformStream and TransformStreamController ( #5042 )
2020-05-03 15:10:52 -04:00
Nayeem Rahman
0f3e6e2eea
fix(cli/fmt_errors): Respect NO_COLOR for stack frames ( #5051 )
2020-05-02 23:55:16 -04:00
Ryan Dahl
bbbf9f299c
Deno.chdir should require allow-read not allow-write ( #5033 )
2020-05-02 18:33:43 -04:00
Bartek Iwańczuk
2872b362ff
BREAKING: disallow static import of local modules from remote modules ( #5050 )
...
This commit changes module loading logic to disallow statically import
local module (file:// scheme) from remote modules (http://, https://
schemes).
2020-05-02 15:51:08 +02:00
Bartek Iwańczuk
de2c042482
BREAKING: remove support for JSON imports ( #5037 )
...
This commit removes support for importing JSON files as modules.
This change is dictated by security; browsers rolled back on this
support as well.
2020-05-02 00:32:05 +02:00
Nayeem Rahman
96fd0f4692
BREAKING: feat(cli/installer): Support guessing the executable name ( #5036 )
2020-05-01 15:33:11 -04:00
Bartek Iwańczuk
6661e7e287
BREAKING: remove window.location and self.location ( #5034 )
...
This commit removes "location" global available on "window",
"globalThis" and "self".
2020-05-01 20:15:28 +02:00
Ryan Dahl
5d3c49082f
Correct copyright in cli/js/web/decode_utf8.ts ( #5035 )
2020-05-01 13:29:00 -04:00
Fenzland
25b765c123
fix misaligned error reporting on tab char ( #5032 )
2020-05-01 13:03:54 -04:00
Marcos Casagrande
4297b865f9
internal: reorder Buffer's copyBytes arguments ( #5021 )
2020-04-30 15:46:44 -04:00
David Sherret
3e72d63205
fix(fmt): Format abstract async
as abstract async
( #5020 )
2020-04-30 21:05:30 +02:00
Bartek Iwańczuk
f79cb08e0b
feat: add SWC dependency analyzer ( #5015 )
...
This commit adds "analyze_dependencies" function that uses SWC
(by the means of AstParser) to perform analysis of static and dynamic
imports.
2020-04-30 20:18:50 +02:00
Luca Casonato
80e2211141
Unstable methods should not appear in runtime or d.ts ( #4957 )
...
Co-authored-by: Kitson Kelly <me@kitsonkelly.com>
2020-04-30 11:23:40 -04:00
Bartek Iwańczuk
4993a6504b
fix(doc): better repr for object literal types ( #4998 )
2020-04-30 16:40:51 +02:00
Kitson Kelly
81c75332fb
feat: Add WritableStreams (and enable ReadableStreams piping) ( #4980 )
2020-04-30 10:40:10 -04:00
Bartek Iwańczuk
46bfcbbaa8
refactor(core): add "prepare_load" hook to ModuleLoader trait ( #4866 )
...
This PR adds prepare_load hook method to ModuleLoader trait. It allows implementors to perform preparation work before starting actual module loading into isolate. It's meant to be used in CLI; where "transpilation" step will be explicitly performed during prepare_load instead of doing it adhoc for each module if needed.
2020-04-30 14:37:06 +02:00
Bartek Iwańczuk
f92bb9cf4d
v0.42.0
2020-04-29 17:04:05 -04:00
Ryan Dahl
bc792c0267
make camel case readDir, readLink, realPath ( #4995 )
2020-04-29 16:39:37 -04:00
Bartek Iwańczuk
d308e8d0c0
BREAKING: remove custom implementation of Deno.Buffer.toString() ( #4992 )
...
Keep in mind Buffer.toString() still exists, but returns [object Object].
Reason for removal of Buffer.toString() was that it implicitly used
TextDecoder with fixed "utf-8" encoding and no way to customize
the encoding.
2020-04-29 22:38:10 +02:00
Nayeem Rahman
b51c863550
feat(std/path): Add fromFileUrl() ( #4993 )
...
Fix: URL constructor accepts a URL object which is not a base
2020-04-29 16:20:55 -04:00
Bert Belder
3e6ea62841
BREAKING: Include limited metadata in 'DirEntry' objects ( #4941 )
...
This change is to prevent needed a separate stat syscall for each file
when using readdir.
For consistency, this PR also modifies std's `WalkEntry` interface to
extend `DirEntry` with an additional `path` field.
2020-04-29 16:00:31 -04:00
Valentin Anger
721a4ad59d
BREAKING: Map-like interface for Deno.env ( #4942 )
2020-04-29 14:48:19 -04:00
Brayden
2337fca277
Make Deno.isatty stable ( #4937 )
2020-04-29 12:43:34 +02:00
Marcos Casagrande
0703431ec2
fix: bug in Deno.copy ( #4977 )
2020-04-28 21:30:48 -04:00
Bartek Iwańczuk
640f6878f6
refactor: Deno.listener closes when breaking out of async iterator ( #4976 )
2020-04-29 01:08:02 +02:00
Bartek Iwańczuk
1b6181e434
refactor: factor out datagram from Deno.listen(), make it unstable ( #4968 )
...
This commit changes Deno.listen() API by factoring out datagram listeners to Deno.listenDatagram(). New Deno.listenDatagram() is unstable.
2020-04-28 21:46:39 +02:00
Ryan Dahl
ea28a088a4
Remove Conn.closeRead ( #4970 )
2020-04-28 15:17:55 -04:00
David Sherret
f899d76667
Fix stdin not formatting JSX ( #4971 )
2020-04-28 15:17:40 -04:00
Bartek Iwańczuk
6ee00e4da3
refactor: change InspectOptions, make Deno.inspect stable ( #4967 )
2020-04-28 20:11:50 +02:00
Nayeem Rahman
678313b176
BREAKING: Remove Deno.EOF, use null instead ( #4953 )
2020-04-28 12:40:43 -04:00
Ali Hasani
47c2f034e9
BREAKING: address renamed to path in UnixAddr UnixConnectOptions UnixListenOptions ( #4959 )
2020-04-28 12:37:59 -04:00
Ryan Dahl
e0ca60e770
BREAKING: Use LLVM target triple for Deno.build ( #4948 )
...
Deno.build.os values have changed to correspond to standard LLVM target triples
"win" -> "windows"
"mac" -> "darwin"
2020-04-28 12:35:23 -04:00
Bartek Iwańczuk
f7ab19b1b7
mark Deno.startTls as unstable ( #4965 )
2020-04-28 18:01:13 +02:00
Nayeem Rahman
76ee6fb335
refactor(cli/js/permissions): Split read and write permission descriptors ( #4774 )
2020-04-28 16:43:58 +02:00
Marcos Casagrande
927a771fa4
url: Make zero a valid port ( #4963 )
2020-04-28 10:40:17 -04:00
Bartek Iwańczuk
2cb875bcfb
refactor: rename sync io interfaces ( #4945 )
...
This commit renames sync io interfaces:
* SyncReader -> ReaderSync
* SyncWriter -> WriterSync
* SyncSeeker -> SeekerSync
2020-04-28 13:23:30 +02:00
Chris Knight
b980b26d85
doc: remove unstable API marker form Deno.Metrics and Deno.RunOptions ( #4949 )
2020-04-28 12:35:43 +02:00