1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-01 09:24:20 -04:00
Commit graph

8627 commits

Author SHA1 Message Date
Mike Mulchrone
fc90c5fb5c
docs: fix minor typo in AsyncRefCell comment (#17732) 2023-02-11 02:11:16 +00:00
Bert Belder
cf06a7c7e6
refactor(ext/http): use String.prototype.trim() instead of regex (#17722) 2023-02-10 19:41:20 +00:00
Kamil Ogórek
68008bee51
fix(dts): make Deno.Command accept readonly prop in options.args (#17718) 2023-02-10 18:09:02 +01:00
Divy Srivastava
39f131cd76
fix(cli/napi): correct name handling in napi property descriptor (#17716)
Fixes https://github.com/denoland/deno/issues/17712
2023-02-10 21:46:56 +05:30
Bartek Iwańczuk
46817a0e3d
refactor: clean up "cli/node/mod.rs" and "ext/node" (#17713)
This commit moves some code around from "cli/node/mod.rs" to
"ext/node". Additionally "ext/node" was changed to factor out
"ops.rs" and "polyfill.rs" modules.
2023-02-10 10:26:39 -05:00
Kamil Ogórek
5778e1196e
feat(install): follow redirects for urls with no path (#17449)
This change makes absolute urls, that contain no path like `deno install
https://my-cli.io` to follow redirects and extract the name from it.

It allows modifies `test_util` server listener on port `4550`
(`REDIRECT_ABSOLUTE_PORT`) to allow for specifying `redirect_to` query
param, that fill use that value for it's next redirect.

Fixes https://github.com/denoland/deno/issues/17409
2023-02-10 10:11:11 -05:00
Divy Srivastava
4baaa246a2
fix(cli/napi): handle all property variants in napi_define_properties (#17680)
Fixes https://github.com/denoland/deno/issues/17509

This fixes the bug that blocked loading `fsevents` in Deno.
2023-02-10 12:50:47 +00:00
Bartek Iwańczuk
1740e0fc36
chore: upgrade rusty_v8 to 0.63.0 (#17705) 2023-02-10 12:40:03 +00:00
Bert Belder
c83abb80fe
perf(core): speed up promise hook dispatch (#17616) 2023-02-10 13:06:19 +01:00
Bartek Iwańczuk
ed3a7ce2f7
refactor: allow to provide polyfills for Node modules from the snapshot (#17706)
This commit does preparatory work to allow snapshotting Node.js
compatibility layer, that currently lives in `std/node`. The logic was 
changed to allow loading some modules from the snapshot and 
some from the remote URL.

Additionally "module_es_shim.js" that provides exports for "node:module"
is now snapshotted.
2023-02-10 11:40:45 +00:00
Bartek Iwańczuk
9ea899afa7
refactor(permissions): use less space for permissions prompt (#17708) 2023-02-10 12:29:03 +01:00
David Sherret
b3e88e0681
refactor: deno_graph 0.43 upgrade (#17692) 2023-02-09 22:00:23 -05:00
Kenta Moriuchi
8da235adce
refactor(ext/webidl): use TypedArrayPrototypeGetSymbolToStringTag (#17602) 2023-02-09 22:45:47 +01:00
David Sherret
717daf4748
perf: module info cache - avoid MediaType.to_string() allocation (#17699)
Micro optimization because these allocations were coming up on a flame
graph I was looking at (only 0.28% of total).
2023-02-09 09:17:48 -05:00
David Sherret
8b0a612e30
perf: disable fetching graph cache info except for deno info (#17698) 2023-02-08 19:45:04 -05:00
Kamil Ogórek
ef9b66950f
fix: use static Reflect methods in nodeGlobalThis proxy (#17696)
Co-authored-by: David Sherret <dsherret@gmail.com>
2023-02-08 19:11:12 -05:00
Leo Kettmeir
286e5d0be9
refactor: internal runtime code TS support (#17672)
This is a proof of concept for being able to snapshot TypeScript files.

Currently only a single runtime file is authored in TypeScript -
"runtime/js/01_version.ts".

Not needed infrastructure was removed from "core/snapshot_util.rs".

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-02-08 22:40:18 +01:00
Bartek Iwańczuk
bef50416b9
fix(core): don't allow to import internal code is snapshot is loaded (#17694)
Addressing Luca concerns from
https://github.com/denoland/deno/pull/17648#discussion_r1099352286
2023-02-08 18:13:33 +01:00
Waldir Pimenta
19543ffec3
fix(ext/console): Only right-align integers in console.table() (#17389) 2023-02-08 18:14:40 +09:00
Ikko Eltociear Ashimine
0597499e9e
chore(cli/tools): fix typo in upgrade.rs (#17690)
vesion -> version
2023-02-08 03:32:30 +00:00
Bartek Iwańczuk
161a4fea47
refactor(core): change SourcePair to ExtensionFileSource (#17686) 2023-02-08 00:21:43 +01:00
Leo Kettmeir
49af1ab18d
refactor: remove prefix from include_js_files & use extension name (#17683) 2023-02-07 21:09:50 +00:00
Leo Kettmeir
b4aa153097
refactor: Use ES modules for internal runtime code (#17648)
This PR refactors all internal js files (except core) to be written as
ES modules.
`__bootstrap`has been mostly replaced with static imports in form in
`internal:[path to file from repo root]`.
To specify if files are ESM, an `esm` method has been added to
`Extension`, similar to the `js` method.
A new ModuleLoader called `InternalModuleLoader` has been added to
enable the loading of internal specifiers, which is used in all
situations except when a snapshot is only loaded, and not a new one is
created from it.

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-02-07 20:22:46 +01:00
Bartek Iwańczuk
65500f36e8
chore: upgrade rusty_v8 to 0.62.2 (#17604)
Co-authored-by: Bert Belder <bertbelder@gmail.com>
2023-02-07 13:36:41 +01:00
denobot
a4988d00da
chore: forward v1.30.3 release commit to main (#17677)
Co-authored-by: bartlomieju <bartlomieju@users.noreply.github.com>
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-02-07 04:15:38 +00:00
Bartek Iwańczuk
4d7145dd5a
chore: update std submodule to 0.176.0 (#17668) 2023-02-06 23:22:52 +01:00
Leo Kettmeir
7f23063329
fix: revert lsp related internal specifiers (#17673)
To fix reports of breakage from #17655
2023-02-06 22:49:49 +01:00
Bartek Iwańczuk
34bfa2cb2c
refactor(npm): use per-thread package.json cache (#17644)
This commit adds a per-thread cache for `package.json` files. It's
similar to what Node.js is doing.
2023-02-06 16:20:20 +01:00
Leo Kettmeir
fd511d5755
refactor: create JsRuntime outside of run_in_task (#17667) 2023-02-06 13:49:26 +00:00
Leo Kettmeir
84a96110cd
refactor: rename deno specifiers to internal (#17655) 2023-02-05 17:49:20 +01:00
Waldir Pimenta
a09296322e
chore(core): improve error message in module loader example (#17654)
Just a small tweak to the error message to avoid confusion.
2023-02-05 13:15:58 +05:30
Gasman
0eb5be9a12
fix(ext/console): log class for class constructor (#17615)
Co-authored-by: tannal <tannal.cn@gmail.com>
2023-02-05 00:34:36 +01:00
David Sherret
1e75e5ecc7
refactor: remove old cjs_esm_translations in graph_util (#17643)
This isn't used.
2023-02-03 23:00:50 -05:00
Nayeem Rahman
a635c9700c
refactor: reland "preserve ProcState::file_fetcher between restarts" (#17636)
Just some watcher init step that I thought would be "cloned over" but
needs to be done again on reset.
2023-02-03 20:15:16 +01:00
David Sherret
b16a958c4f
fix(lsp): prevent crash analyzing module (#17642)
Closes #17640
2023-02-03 14:10:51 -05:00
denobot
f8ecd236fb
chore: forward v1.30.2 release commit to main (#17641)
This is the release commit being forwarded back to main for 1.30.2

Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
2023-02-03 16:26:43 +00:00
David Sherret
09d9437897
chore: add release checklist step to check the benchmarks page (#17632)
The 1.30.1 release had a performance regression that would have been
caught by looking at the benchmarks page. This adds a pre-flight step to
the release checklist for the person doing the release to go to this
page and look at the output.

This would have prevented #17629
2023-02-02 23:41:46 +00:00
Bartek Iwańczuk
3f8c217bb1
Revert "chore(core): remove have_unpolled_ops on rt state (#17601)" (#17631)
This reverts commit e85ca8be0d.

This commit caused a huge spike in various benchmarks we track at
https://deno.land/benchmarks
2023-02-03 00:24:20 +01:00
Leo Kettmeir
1876577d64
fix(webgpu): specify viewFormats in surface configuration (#17626) 2023-02-02 23:34:31 +01:00
denobot
65755a115a
chore: forward v1.30.1 release commit to main (#17623)
This is the release commit being forwarded back to main for 1.30.1
2023-02-02 16:28:40 +00:00
David Sherret
dc854e83a4
fix(repl): handle @types/node not being cached in the repl (#17617)
Closes #17599
2023-02-01 16:37:05 -05:00
David Sherret
f6f76a76b2
fix(lockfile): emit trailing newline (#17618) 2023-02-01 15:57:02 -05:00
Divy Srivastava
690b6ac39e
fix(napi): remove wrong length check in napi_create_function (#17614)
This check is not needed. 

This PR + #17613 makes `npm:ref-napi` work with Deno.
2023-02-01 20:18:03 +05:30
Divy Srivastava
524bccdf6a
fix(napi): return node globalThis from napi_get_global (#17613)
Fixes https://github.com/denoland/deno/issues/17587
2023-02-01 15:41:04 +01:00
luketpeterson
1b46b2f0e4
chore: bump serde & serde_json deps to use semver minimums (#17610)
Changing serde & serde_json dependencies to use semver minimums rather
than exact crate version.

Fixes https://github.com/denoland/deno/issues/17609
2023-02-01 14:40:35 +00:00
David Sherret
600fff79cd
refactor(semver): generalize semver related structs (#17605)
- Generalizes the npm version code (ex. `NpmVersion` -> `Version`,
`NpmVersionReq` -> `VersionReq`). This is a slow refactor towards
extracting out this code for deno specifiers and better usage in
deno_graph.
- Removes `SpecifierVersionReq`. Consolidates `NpmVersionReq` and
`SpecifierVersionReq` to just `VersionReq`
- Removes `NpmVersionMatcher`. This now just looks at `VersionReq`.
- Paves the way to allow us to create `NpmPackageReference`'s from a
package.json's dependencies/dev dependencies
(`VersionReq::parse_from_npm`).
2023-01-31 21:27:40 -05:00
Luca Casonato
e85ca8be0d
chore(core): remove have_unpolled_ops on rt state (#17601)
It's not needed - `!state.have_unpolled_ops.is_empty()` does the same
thing.

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-01-31 01:17:51 +01:00
Bartek Iwańczuk
d318e38b76
Revert "fix(watch): preserve ProcState::file_fetcher between restarts (#15466) (#17591)
This reverts commit 3545bff678.
2023-01-30 16:22:17 +01:00
Leo Kettmeir
3035dee9f1
chore: update webgpu (#17534) 2023-01-30 15:14:16 +01:00
Kenta Moriuchi
266915d5ce
fix(ext): internal structuredClone for ArrayBuffer and TypedArray subclasses (#17431) 2023-01-29 15:15:01 +01:00