1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-21 15:04:11 -05:00
Commit graph

6599 commits

Author SHA1 Message Date
Bartek Iwańczuk
768132b85f
feat(upgrade): print info links for Deno 2 RC releases (#25225)
In addition to printing a blog post information (if it's available),
this will also print a link to migration guide and the bug tracker.

---------

Signed-off-by: Bartek Iwańczuk <biwanczuk@gmail.com>
Co-authored-by: Asher Gomez <ashersaupingomez@gmail.com>
2024-08-30 02:32:01 +02:00
Nathan Whitaker
86d5b919d8
feat(config): Node modules option for 2.0 (#25299) 2024-08-29 15:57:43 -07:00
denobot
0fb8df6c0c
chore: forward v1.46.2 release commit to main (#25296)
This is the release commit being forwarded back to main for 1.46.2
2024-08-29 22:13:28 +02:00
Leo Kettmeir
055cdd00f7
fix: update deno_doc (#25290) 2024-08-29 02:34:43 -07:00
David Sherret
2afbc1aa39
feat: deprecate import assertions (#25281)
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-08-29 01:06:09 +00:00
Asher Gomez
d183533404
docs: refer to globalThis instead of window in declaration files (#25286) 2024-08-29 00:22:40 +00:00
Bartek Iwańczuk
27d0897841
test: run specs::npm::exec_file_inside_npm_package with DENO_FUTURE=1 (#25282)
The test is failing if run with `DENO_FUTURE=1` which is blocking
https://github.com/denoland/deno/pull/25213.

---------

Co-authored-by: David Sherret <dsherret@gmail.com>
2024-08-29 02:21:59 +02:00
David Sherret
3afa3db4d3
fix: delete old Deno 1.x headers file when loading cache (#25283) 2024-08-28 23:47:15 +00:00
Nathan Whitaker
37501aa323
fix(napi): Don't run microtasks in napi_resolve_deferred (#25246)
Fixes an incredibly obscure bug that causes parcel's file watcher to not
get any file update notifications on macOS.

The issue was that the native addon was calling `napi_resolve_deferred`,
but when we resolved the promise, v8 was running microtasks
automatically. That executed JS, which called back into the native addon
and broke the addon's assumption that the call wouldn't be reentrant.
2024-08-28 13:42:42 -07:00
David Sherret
b708a13eb0
feat: improve lockfile v4 to store normalized version constraints and be more terse (#25247)
Stores normalized version constraints in the lockfile, which will
improve reproducibility and will fix a bug with duplicate specifiers
ending up in the lockfile. Also, gets rid of some duplicate data in the
specifiers area of the lockfile.
2024-08-28 14:17:47 -04:00
Bartek Iwańczuk
044e7c4e63
build: Allow building 'rc' release from source (#25227)
We're not gonna use it, but this might help distribution tools like
Homebrew to also release Deno 2.0 RC releases.
2024-08-28 14:31:25 +00:00
Pig Fang
f6c537f898
fix(fmt): fix incorrect quotes in components (#25249)
Unlike in dprint, `single_quote` option is shared between all
formatters, so we shouldn't change this option when formatting
attributes in components. This PR fixes this.

This problem doesn't affect formatting HTML.
2024-08-28 09:48:14 -04:00
Nayeem Rahman
97d1635343
fix(lsp): panic on url_to_uri() (#25238) 2024-08-28 05:15:48 +01:00
Bartek Iwańczuk
efcabce1c1
feat: remove --lock-write flag (#25214)
This commit remove `--lock-write` that was deprecated in v1.45 release.

Closes https://github.com/denoland/deno/issues/24167.

---------

Co-authored-by: Asher Gomez <ashersaupingomez@gmail.com>
2024-08-28 13:23:51 +10:00
Bartek Iwańczuk
3dba98532a
fix: replace npm install hint with deno install hint (#25244)
Needed for https://github.com/denoland/deno/pull/25213.

With Deno 2, we should suggest using `deno install` instead of `npm
install`.
2024-08-28 02:31:41 +00:00
HasanAlrimawi
672ce3041a
fix: removed unstable-htttp from deno help (#25216)
Closes #25210 .

Removed --unstable-http from being displayed on deno run --help=unstable

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-08-27 13:45:27 +02:00
Marvin Hagemeister
7e68cce815
fix(task): support tasks with colons in name in deno run (#25233)
Fix task names containing a colon not being found with `deno run`. We
were only checking for a `module not found` error message, but strings
containing a colon throw a different error.

Fixes https://github.com/denoland/deno/issues/25232
2024-08-27 11:27:10 +02:00
David Sherret
c89a20b428
perf(cache): single cache file for remote modules (#24983)
This changes the global cache to store the cache file for remote modules
in one file instead of two.
2024-08-26 23:59:17 +00:00
David Sherret
e13230226f
feat: lockfile v4 by default (#25165)
This won't be fully stabilized until 2.0 is released.
2024-08-26 23:01:50 +00:00
David Sherret
631d931973
fix(fmt/markdown): fix regression with multi-line footnotes and inline math (#25222)
What happened in this specific case was the parser used to actually
treat these as code block. Now it treats it as a multi-paragraph
footnote and that caused the issue

- https://github.com/dprint/dprint-plugin-markdown/pull/121/files
2024-08-26 18:36:24 +00:00
David Sherret
a8ce02473a
perf(cache): single cache file for typescript emit (#24994) 2024-08-26 15:43:57 +00:00
Armaan Salam
675539c7ab
fix(bench): Fix table column alignments and NO_COLOR=1 (#25190)
Fix table layout for `deno bench` command with and without color
(`NO_COLOR=1`).

Fixes issue in #25156
2024-08-26 11:56:04 +02:00
Nayeem Rahman
2ab4afc6b8
refactor(lsp): changes for lsp_types 0.97.0 (#25169) 2024-08-24 01:21:21 +01:00
David Sherret
bbd3a7e637
fix: handle showing warnings while the progress bar is shown (#25187) 2024-08-23 22:07:59 +00:00
Yusuke Tanaka
d54d29662f
chore: enable log feature for tracing crate (#25078)
This commit enables the `log` feature for the `tracing` crate.

This allows us to examine additional detailed logs emitted by third party crates
that use `tracing` crate for logging by setting `RUST_LOG` env var or passing
`-L` option in command line.

Closes #25045
2024-08-22 19:15:10 -07:00
Nathan Whitaker
f606402677
fix(install): Use relative symlinks in deno install (#25164)
Fixes https://github.com/denoland/deno/issues/25161
2024-08-22 21:55:17 +00:00
Kenta Moriuchi
b6475d0f36
chore: update config-file.v1.json (#25163) 2024-08-22 19:49:22 +00:00
denobot
716ae4d8cb
chore: forward v1.46.1 release commit to main (#25155) 2024-08-22 10:44:53 -07:00
Luca Casonato
e7026c5ee8
fix: trim space around DENO_AUTH_TOKENS (#25147) 2024-08-22 15:14:50 +02:00
denobot
3314a0ceb8
1.46.0 (#25139)
Bumped versions for 1.46.0

Co-authored-by: bartlomieju <bartlomieju@users.noreply.github.com>
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-08-22 02:16:45 +02:00
David Sherret
32a579d418
fix(fmt/markdown): metadata header sometimes missing trailing blank line (#25141)
* https://github.com/dprint/dprint-plugin-markdown/pull/119
2024-08-22 02:16:00 +02:00
Nathan Whitaker
48da3c17ea
fix(add): Handle packages without root exports (#25102)
Fixes #24607.

This PR makes the logic that caches top level dependencies (things
present in import map) smarter, so we handle JSR dependencies without
root exports.
2024-08-21 15:23:32 -07:00
Nayeem Rahman
c22ff197db
fix(lsp): resolve jsx import source with types mode (#25064) 2024-08-21 20:00:23 +01:00
David Sherret
1d4169204c
fix: warn about import assertions when using typescript (#25135)
1. On emit, checks for the prescence of import assertions.
1. Warns and doesn't store the parsed source in the emit cache in this
case.
2024-08-21 17:12:56 +00:00
Divy Srivastava
e2c50f7e8a
fix(upgrade): better error message when check_exe fails (#25133)
Fixes https://github.com/denoland/deno/issues/24971

Fixes the panic. We can give a more personalized error by checking the
macOS version but probably not worth the effort.
2024-08-21 19:55:17 +05:30
Nayeem Rahman
76990df6fa
chore(lsp): use 'install' terminology for jsr and npm packages (#25119) 2024-08-21 15:10:28 +01:00
Leo Kettmeir
7139337083
feat(flags): improve help output and make deno run list tasks (#25108)
- rewrite flag help
- use gray for indentation
- reorganize permission flags and split them up
- make help subcommand act like help flag
- `deno run` outputs list of tasks
- Fixes #25120

error handling for `deno run` in case of no config file being found
needs to be improved

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-08-21 06:54:59 -07:00
David Sherret
37279e0b0a
fix(add): error when config file contains importMap field (#25115)
The "imports" field has higher precedence than "importMap", so we should
error when `deno add` goes to add an `"imports"` field.

Closes https://github.com/denoland/deno/issues/24264
Closes https://github.com/denoland/deno/pull/24478
2024-08-20 16:32:01 -04:00
David Sherret
a7c002ae63
chore: enable no-console dlint rule (#25113) 2024-08-20 15:14:37 -04:00
Bartek Iwańczuk
7bfb93135d
chore(release): Release Deno v1.46.0-rc.3 (#25112) 2024-08-20 21:02:26 +02:00
Nayeem Rahman
acba2cd48c
fix(lsp): include scoped import map keys in completions (#25047) 2024-08-20 19:38:47 +01:00
Yazan AbdAl-Rahman
a7c8bb1596
feat: glob and directory support for deno check and deno cache cli arg paths (#25001)
Closes #24668
Closes #20813

---------

Co-authored-by: David Sherret <dsherret@gmail.com>
2024-08-20 18:38:06 +00:00
Bartek Iwańczuk
1f47248143
fix: adjust suggestion for lockfile regeneration (#25107)
Ref https://github.com/denoland/deno/pull/24436#issuecomment-2288568645
2024-08-20 20:13:17 +02:00
HasanAlrimawi
0704454755
feat: Print deprecation message for npm packages (#24992)
This commit adds ability to print deprecation notices
for npm packages that have been marked as deprecated.

Closes #24013
2024-08-20 19:53:53 +02:00
Nathan Whitaker
5168700be6
feat(config): Support frozen lockfile config option in deno.json (#25100)
Closes #24544
2024-08-20 14:55:47 +00:00
David Sherret
f1c58ec041
feat(unstable): ability to use a local copy of jsr packages (#25068) 2024-08-20 14:11:43 +00:00
Hajime-san
19bcb40059
feat(cli/tools): add a subcommand --hide-stacktraces for test (#24095) 2024-08-20 01:27:36 +00:00
Yazan AbdAl-Rahman
4f49f703c1
fix(cli): update permission prompt message for compiled binaries (#24081)
Co-authored-by: David Sherret <dsherret@gmail.com>
2024-08-20 01:20:06 +00:00
melbourne2991
0eba180fdb
fix(repl): Prevent panic on broken pipe (#21945) 2024-08-20 00:21:12 +00:00
Bartek Iwańczuk
1c4db2aca9
chore(release): Release Deno v1.46.0-rc.2 (#25101) 2024-08-19 21:13:04 +00:00
Yazan AbdAl-Rahman
4285cb339d
fix(lint): support linting tsx/jsx from stdin (#24955)
Co-authored-by: David Sherret <dsherret@users.noreply.github.com>
2024-08-19 20:42:13 +00:00
Bartek Iwańczuk
b5051e25c2
feat: Deprecate "import assertions" with a warning (#24743)
This commit deprecates "import assertions" proposal that has been
replaced with "import attributes".

Any time an import assertion is encountered a warning will be printed
to the terminal. This warning will be printed for both local and 
remote files (ie. user code and dependencies).

Import assertions support will be removed in Deno 2.
2024-08-19 22:36:35 +02:00
Łukasz Czerniawski
0f2e47dd69
feat(watch): add watch paths to test subcommand (#24771) 2024-08-19 17:09:51 +00:00
David Sherret
c9edb15f15
fix(compile): make output more deterministic (#25092)
Closes https://github.com/denoland/deno/issues/25084
2024-08-19 16:41:11 +00:00
David Sherret
a20418e2e8
fix(fmt): regression with pipe in code blocks in tables (#25098) 2024-08-19 16:35:51 +00:00
Bartek Iwańczuk
c94c5cddb1
feat(upgrade): support deno upgrade 1.46.0 (#25096)
This commit changes `deno upgrade` subcommand to accept
a positional argument that can be either a version, release channel
name or a git hash, making invocations of `deno upgrade` much
more concise:

```
# before
$ deno upgrade --version 1.46.0
# after 
$ deno upgrade 1.46.0
```

```
# before
$ deno upgrade --canary
# after
$ deno upgrade canary
```

```
# specific canary version before
$ deno upgrade --canary --version f042c39180
# after
$ deno upgrade f042c39180
```

Old flags are still supported, but hidden from the help output.
2024-08-19 17:05:10 +02:00
snek
c0aa68a1e2
feat: upgrade deno_core (#25042)
- Update ffi turbocall to use revised fast call api
- Remove `v8_version` function calls
- `*mut OwnedIsolate` is no longer stored in OpCtx gotham store
2024-08-19 14:51:16 +00:00
David Sherret
526f39fbb9
feat(FUTURE): terse lockfile (v4) (#25059) 2024-08-19 03:01:39 +00:00
David Sherret
28bebce544
chore: Rust 1.80.1 (#25089) 2024-08-18 22:24:56 -04:00
Bartek Iwańczuk
5c69b4861b
fix(upgrade): support RC release with --version flag (#25091)
This commit fixes scenarios like:
```
$ deno upgrade --version=v1.46.0-rc.0
Downloading https://github.com/denoland/deno/releases/download/v1.46.0-rc.0/deno-aarch64-apple-darwin.zip
Download could not be found, aborting
```

Now:
```
$ target/debug/deno upgrade --version=v1.46.0-rc.0
Downloading https://dl.deno.land/release/v1.46.0-rc.0/deno-aarch64-apple-darwin.zip
Deno is upgrading to version 1.46.0-rc.0

Upgraded successfully to Deno v1.46.0-rc.0

```

Also some unneeded code was removed.
2024-08-19 00:27:06 +00:00
David Sherret
52681a2a29
fix: correct JSON config schema to show vendor option as stable (#25090)
This has been considered stable for some time now.
2024-08-18 22:54:07 +00:00
Luca Casonato
9bc2dd29ad
fix: clean up flag help output (#24686)
Permission flags are unified in a clearer and concise output.
Unstable flags are hidden by default with exception of the `unstable`
flag itself. the remaining unstable flags can be seen with a
`--help=unstable`.
This also cleans up to show unstable flags only for subcommands that
actually need them.
Also sorts flags alphabetically, and gorups various flags together in a
set of categories.

---------

Co-authored-by: crowlkats <crowlkats@toaxl.com>
2024-08-18 15:39:53 -07:00
Bartek Iwańczuk
1ec12a8c5d
chore(release): Release Deno v1.46.0-rc.1 (#25088)
Just bumping the version to test out `deno upgrade --rc` some more.
2024-08-19 00:30:45 +02:00
Bartek Iwańczuk
f003d6498c
fix(upgrade): correctly compute latest version based on current release channel (#25087)
This commit fixes computation of the latest available version
by taking into account which release channel the current
binary is on.

Before this commit, if user was on "RC" channel, calling
`deno upgrade` would not switch back to the "stable"
channel.
2024-08-19 00:29:59 +02:00
HasanAlrimawi
2e9d3b688c
fix: log current version when using deno upgrade (#25079)
This PR addresses a suggestion in issue #21417

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-08-18 22:07:54 +00:00
David Sherret
4cd95589ec
fix: make deno add output more deterministic (#25083)
Will fix some flaky tests.
2024-08-18 23:02:32 +02:00
David Sherret
35a17f38f6
fix(fmt): upgrade to dprint-plugin-markdown 0.17.4 (#25075)
Closes https://github.com/denoland/deno/issues/20917
Closes https://github.com/denoland/deno/issues/21285
2024-08-17 12:51:36 +02:00
Bartek Iwańczuk
2eeea0a1d2
ci: add script to promote to RC release (#25072)
This commits add a CI script that allows to promote a certain
canary build to a "Release Candidate" release.

This is done using `libsui` and `patchver` utilities.
2024-08-16 23:59:10 +02:00
Bartek Iwańczuk
db75462bd6
refactor: show release channel in deno --version (#25061)
Also simplifies handling of various release channels in `deno upgrade`
subcommand.
2024-08-16 22:42:19 +02:00
David Sherret
4d1b263e91
feat(publish): suggest importing jsr:@std/ for deno.land/std urls (#25046) 2024-08-16 10:42:11 -04:00
David Sherret
57cd2951f1
feat(config/jsr): add license field (#25056)
1. Adds a new "license" field.
1. Adds this field by default when doing `deno init --lib`
2024-08-16 13:12:52 +00:00
Yoshiya Hinosawa
105d27bc7d
fix(ext/node): improve shelljs compat with managed npm execution (#24912)
This change improves the Node.js compatibility in managed npm resolution
mode by disabling the discovery of `node_modules` when the
main specifier is inside of `DENO_DIR`.

closes #22732
closes #24589
2024-08-16 12:48:48 +09:00
Bartek Iwańczuk
2bb013f9ba
refactor: version module exports a single const struct (#25014)
This commit rewrites the internal `version` module that exported
various information about the current executable. Instead of exporting
several consts, we are now exporting a single const structure that 
contains all the necessary information.

This is the first step towards cleaning up how we use this information
and should allow us to use SUI to be able to patch this information
in already produced binary making it easier to cut new releases.

---------

Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
2024-08-15 23:47:16 +02:00
Nathan Whitaker
5ec3c5c3a4
feat(lint): Add lint for usage of node globals (with autofix) (#25048)
From upgrading `deno_lint`.

Previously if you had a node project that used a bunch of node globals
(`process.env`, etc), you would have to fix the errors by hand. This PR
includes a new lint that detects usages of node globals (`process`,
`setImmediate`, `Buffer`, etc.) and provides an autofix to import the
correct value. For instance:

```ts
// main.ts
const _foo = process.env.FOO;
```

`deno lint` gives you

```ts
error[no-node-globals]: NodeJS globals are not available in Deno
 --> /home/foo.ts:1:14
  |
1 | const _foo = process.env.FOO;
  |              ^^^^^^^
  = hint: Add `import process from "node:process";`

  docs: https://lint.deno.land/rules/no-node-globals


Found 1 problem (1 fixable via --fix)
Checked 1 file
```
And `deno lint --fix` adds the import for you:

```ts
// main.ts
import process from "node:process";
const _foo = process.env.FOO;
```
2024-08-15 20:43:04 +00:00
Bartek Iwańczuk
e8d57cd3fe
refactor: remove version::is_canary(), use ReleaseChannel instead (#25053)
In preparation for https://github.com/denoland/deno/pull/25014, this
commit removes public `is_canary()` method and instead uses an enum
`ReleaseChannel` to be able to designate more "kinds" of builds.
2024-08-15 21:59:16 +02:00
Divy Srivastava
7ca95fc999
feat: deno compile --icon <ico> (#25039)
Add `--icon` flag to set deno compile'd executable icon on Windows.

```
deno compile --icon icon.ico game.tsx
```

Depends on https://github.com/denoland/sui/pull/24

<img width="447" alt="image"
src="https://github.com/user-attachments/assets/7f6f3aa0-6872-4975-ae9d-06701b7684b8">

Closes https://github.com/denoland/deno/issues/8912
2024-08-15 10:12:23 +05:30
Nathan Whitaker
e92a05b551
feat(serve): Opt-in parallelism for deno serve (#24920)
Adds a `parallel` flag to `deno serve`. When present, we spawn multiple
workers to parallelize serving requests.


```bash
deno serve --parallel main.ts
```

Currently on linux we use `SO_REUSEPORT` and rely on the fact that the
kernel will distribute connections in a round-robin manner.

On mac and windows, we sort of emulate this by cloning the underlying
file descriptor and passing a handle to each worker. The connections
will not be guaranteed to be fairly distributed (and in practice almost
certainly won't be), but the distribution is still spread enough to
provide a significant performance increase.

---
(Run on an Macbook Pro with an M3 Max, serving `deno.com`

baseline::
```
❯ wrk -d 30s -c 125 --latency http://127.0.0.1:8000
Running 30s test @ http://127.0.0.1:8000
  2 threads and 125 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   239.78ms   13.56ms 330.54ms   79.12%
    Req/Sec   258.58     35.56   360.00     70.64%
  Latency Distribution
     50%  236.72ms
     75%  248.46ms
     90%  256.84ms
     99%  268.23ms
  15458 requests in 30.02s, 2.47GB read
Requests/sec:    514.89
Transfer/sec:     84.33MB
```

this PR (`with --parallel` flag)
```
❯ wrk -d 30s -c 125 --latency http://127.0.0.1:8000
Running 30s test @ http://127.0.0.1:8000
  2 threads and 125 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   117.40ms  142.84ms 590.45ms   79.07%
    Req/Sec     1.33k   175.19     1.77k    69.00%
  Latency Distribution
     50%   22.34ms
     75%  223.67ms
     90%  357.32ms
     99%  460.50ms
  79636 requests in 30.07s, 12.74GB read
Requests/sec:   2647.96
Transfer/sec:    433.71MB
```
2024-08-14 22:26:21 +00:00
Nayeem Rahman
4eff1e8ec4
fix(lsp): import map lookup for jsr subpath auto import (#25025) 2024-08-14 22:38:18 +01:00
Pig Fang
3a3315cc7f
feat(fmt): support HTML, Svelte, Vue, Astro and Angular (#25019)
This commit adds capability to format HTML, Svelte, Vue, Astro and Angular
files.

"--unstable-html" is required to format HTML files, and "--unstable-component"
flag is needed to format other formats. These can also be specified in the config
file.

Close #25015
2024-08-14 22:58:48 +02:00
Asher Gomez
f89b531149
feat(node): support username and _password in .npmrc file (#24793)
Closes #23950
2024-08-14 18:53:15 +02:00
Luca Casonato
130a2592f1
fix(cli): support --watch when running cjs npm packages (#25038) 2024-08-14 15:21:11 +02:00
Bartek Iwańczuk
b325bf0a35
feat(clean): add progress bar (#25026)
Closes https://github.com/denoland/deno/issues/25020
2024-08-14 13:04:07 +02:00
Łukasz Czerniawski
e2faf50375
feat(coverage): add breadcrumbs to deno coverage --html report (#24860) 2024-08-14 16:37:19 +09:00
Bartek Iwańczuk
8537c4537b
fix(upgrade): use proper version display (#25029)
This commit fixes output of `deno upgrade` subcommand,
by displaying proper version numbers. Before this PR we were
prepending "v" before the canary version hash, which was
obviously wrong.
2024-08-13 22:32:20 +00:00
Bartek Iwańczuk
25bb59d2ce
fix(tls): print a warning if a system certificate can't be loaded (#25023)
This commit changes how system certificates are loaded on startup.

Instead of hard erroring if a certificate can't be decoded, we are now
printing a warning and bumping a hex representation of the certificate
and continue execution.

Ref https://github.com/denoland/deno/issues/24137
2024-08-13 16:12:45 +00:00
David Sherret
39a21fd78e
feat(publish): error on missing license file (#25011)
Closes https://github.com/denoland/deno/issues/24676
2024-08-12 19:51:58 -04:00
Bartek Iwańczuk
631e175498
fix(upgrade): return no RC versions if fetching fails (#25013)
This commit fixes errors on CI like this:
```
---- upgrade::upgrade_prompt stdout ----
command /home/runner/work/deno/deno/target/release/deno run --log-level=debug main.js
command cwd /tmp/deno-cli-testqDw5UR
command /home/runner/work/deno/deno/target/release/deno run --log-level=debug main.js
command cwd /tmp/deno-cli-testqDw5UR
------ Start Full Text ------
"DEBUG RS - deno::args:620 - No .npmrc file found\r\nDEBUG RS - deno::args:909 - Finished config loading.\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/dep_analysis_cache_v2...\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/node_analysis_cache_v2...\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/v8_code_cache_v2...\r\nDEBUG RS - deno::js:10 - Deno isolate init with snapshots.\r\nDEBUG RS - deno::worker:183 - main_module file:///tmp/deno-cli-testqDw5UR/main.js\r\nDEBUG RS - deno::module_loader:158 - Preparing module load.\r\nDEBUG RS - deno::module_loader:162 - Building module graph.\r\nDEBUG RS - deno::file_fetcher:573 - FileFetcher::fetch_no_follow_with_options - specifier: file:///tmp/deno-cli-testqDw5UR/main.js\r\nDEBUG RS - deno::module_loader:208 - Prepared module load.\r\nDEBUG RS - deno_runtime::worker:739 - received module evaluate Ok(\r\n    (),\r\n)\r\nDEBUG RS - deno::module_loader:831 - Updating V8 code cache for ES module: file:///tmp/deno-cli-testqDw5UR/main.js, [1577979522354460122]\r\n"
------- End Full Text -------
Next text: "DEBUG RS - deno::args:620 - No .npmrc file found\r\nDEBUG RS - deno::args:909 - Finished config loading.\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/dep_analysis_cache_v2...\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/node_analysis_cache_v2...\r\nDEBUG RS - deno::cache::cache_db:168 - Opening cache /tmp/deno-cli-testMKnYXP/v8_code_cache_v2...\r\nDEBUG RS - deno::js:10 - Deno isolate init with snapshots.\r\nDEBUG RS - deno::worker:183 - main_module file:///tmp/deno-cli-testqDw5UR/main.js\r\nDEBUG RS - deno::module_loader:158 - Preparing module load.\r\nDEBUG RS - deno::module_loader:162 - Building module graph.\r\nDEBUG RS - deno::file_fetcher:573 - FileFetcher::fetch_no_follow_with_options - specifier: file:///tmp/deno-cli-testqDw5UR/main.js\r\nDEBUG RS - deno::module_loader:208 - Prepared module load.\r\nDEBUG RS - deno_runtime::worker:739 - received module evaluate Ok(\r\n    (),\r\n)\r\nDEBUG RS - deno::module_loader:831 - Updating V8 code cache for ES module: file:///tmp/deno-cli-testqDw5UR/main.js, [1577979522354460122]\r\n"
thread 'upgrade::upgrade_prompt' panicked at tests/integration/upgrade_tests.rs:251:9:
Timed out.
```

These errors are caused by the fact that the test server doesn't have an
endpoint to return
RC releases. Which in turn causes an error to be raised which later just
short-circuits logic
for checking the version and storing it in file. Since fetching from a
remote host is always
fallible I elected to just return an empty vec of "rc" versions instead
of erroring. This might
lead to a slight mismatch in some situation when the request actually
failed and user is
prompted that there's a new canary version, but that is better than not
displaying
prompt at all. This issue will be fixed more robustly once we move to
using SUI for
specifying version of the binary.
2024-08-12 23:44:14 +00:00
David Sherret
085058cfff
feat: deno remove (#24952)
Co-authored-by: Satya Rohith <me@satyarohith.com>
2024-08-12 16:17:25 -04:00
Leo Kettmeir
b1036e4d9c
fix: update deno_doc (#24972)
For Better HTML titles and custom JSDoc module resolving
2024-08-12 12:57:50 -07:00
Bartek Iwańczuk
3c70b9435a
feat: deno upgrade --rc (#24905)
This commit adds the "--rc" flag to "deno upgrade" subcommand.

This flag allows to upgrade to the latest "release candidate" release.

The update checker was also updated to take this into account.
2024-08-12 18:32:53 +00:00
Kenta Moriuchi
76f4f202e7
chore: update the copyright of c, mjs, and jsx (#25005) 2024-08-12 12:41:32 -04:00
Leo Kettmeir
e5f0058b74
feat: better help output (#24958) 2024-08-12 08:55:33 -07:00
Nayeem Rahman
9bdab6fb6b
fix(lsp): directly use file referrer when loading document (#24997) 2024-08-12 15:45:27 +01:00
Bartek Iwańczuk
004b74c8c6
feat: Rename --unstable-hmr to --watch-hmr (#24975)
This commit stabilizes HMR functionality and renames
`--unstable-hmr` to `--watch-hmr`. The `--unstable-hmr`
flag is still working, but hidden from the help output.
It will be removed in Deno 2.

Once https://github.com/denoland/deno/pull/24958 lands
we should improve grouping of `--watch` and `--watch-hmr`
flags.
2024-08-12 00:10:55 +02:00
Pig Fang
82884348cb
feat(fmt): support CSS, SCSS, Sass and Less (#24870)
This PR integrates [Malva](https://github.com/g-plane/malva) into `deno
fmt`, which introduces the ability to format CSS, SCSS, Sass and Less
files.

On Linux x64 6.10, this PR increases about 800KiB:

```                                                                                                                                                                      
❯ wc -c target/release/deno
125168728 target/release/deno

❯ wc -c target/release/deno
124349456 target/release/deno
```
2024-08-09 18:52:23 +02:00
Nathan Whitaker
218ee1b1ff
fix(add): Better error message when missing npm specifier (#24970)
Before:
<img width="278" alt="Screenshot 2024-08-09 at 3 15 01 PM"
src="https://github.com/user-attachments/assets/91b0ada6-93ee-4be6-a996-078aef98c2a9">

After:
<img width="888" alt="Screenshot 2024-08-09 at 3 52 15 PM"
src="https://github.com/user-attachments/assets/3c88a0e8-c761-4f70-88bf-109355ac12f0">
2024-08-09 14:29:11 +00:00
Nathan Whitaker
854c7ba198
fix(install): Properly handle dist tags when setting up node_modules (#24968)
Fixes https://github.com/denoland/deno/issues/24966.
Fixes https://github.com/denoland/deno/issues/24932.
2024-08-09 13:35:54 +00:00
Bartek Iwańczuk
c9f626e251
refactor(upgrade): cleanup pass (#24954)
No functional changes, just factoring out some helpers to make it easier
to update and test.
2024-08-09 09:44:21 +00:00
David Sherret
c21f42c825
fix(lsp): don't always use byonm resolver when DENO_FUTURE=1 (#24865)
Co-authored-by: Nayeem Rahman <nayeemrmn99@gmail.com>
2024-08-09 09:50:37 +02:00
David Sherret
fb16868593
fix(add): better error message providing scoped pkg missing leading @ symbol (#24961)
* https://github.com/denoland/deno_semver/pull/30
2024-08-08 23:23:28 +02:00