1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-24 15:19:26 -05:00
denoland-deno/cli
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
..
args feat: deno remove (#24952) 2024-08-12 16:17:25 -04:00
bench chore: update the copyright of c, mjs, and jsx (#25005) 2024-08-12 12:41:32 -04:00
cache perf: skip saving to emit cache after first failure (#24896) 2024-08-08 09:41:30 +00:00
js feat(jupyter): support confirm and prompt in notebooks (#23592) 2024-07-04 22:12:14 +00:00
lsp fix(lsp): directly use file referrer when loading document (#24997) 2024-08-12 15:45:27 +01:00
napi chore: forward v1.45.5 release commit to main (#24818) 2024-07-31 15:14:27 -07:00
npm fix(install): Properly handle dist tags when setting up node_modules (#24968) 2024-08-09 13:35:54 +00:00
ops fix: adapt to new jupyter runtime API and include session IDs (#24762) 2024-07-27 10:39:08 +02:00
schemas feat(workspace): support object config (#24483) 2024-07-09 17:06:50 -04:00
standalone fix: Don't shell out to unzip in deno upgrade/compile (#24926) 2024-08-08 00:19:05 -07:00
tools fix(upgrade): return no RC versions if fetching fails (#25013) 2024-08-12 23:44:14 +00:00
tsc fix: rename watch event missing (#24893) 2024-08-07 18:15:57 +02:00
util feat: refresh "Download" progress bar with a spinner (#24913) 2024-08-08 13:54:29 +00:00
auth_tokens.rs fix(cli): Add IP address support to DENO_AUTH_TOKEN (#22297) 2024-02-06 19:45:40 +01:00
build.rs Revert "fix(cli): add NAPI support in standalone mode (#24642)" (#24682) 2024-07-23 02:42:26 +02:00
Cargo.toml fix: update deno_doc (#24972) 2024-08-12 12:57:50 -07:00
cdp.rs chore: upgrade to rust 1.79 (#24207) 2024-06-14 17:10:57 +05:30
clippy.toml refactor: don't share reqwest::HttpClient across tokio runtimes (#24092) 2024-06-03 21:17:08 +00:00
deno.ico
emit.rs perf: skip saving to emit cache after first failure (#24896) 2024-08-08 09:41:30 +00:00
entitlements.plist chore: start codesigning mac release builds (#21303) 2023-11-23 15:30:26 -07:00
errors.rs fix(compile): support workspace members importing other members (#24909) 2024-08-07 07:43:05 +00:00
factory.rs feat: deno remove (#24952) 2024-08-12 16:17:25 -04:00
file_fetcher.rs refactor: remove PermissionsContainer in deno_runtime (#24119) 2024-06-06 23:37:53 -04:00
graph_container.rs refactor: update to deno_config 0.25 (#24645) 2024-07-19 15:56:07 -04:00
graph_util.rs perf: skip saving to emit cache after first failure (#24896) 2024-08-08 09:41:30 +00:00
http_util.rs fix(ext/fetch): include URL and error details on fetch failures (#24910) 2024-08-07 23:18:33 -07:00
integration_tests_runner.rs chore: continue tests/ re-org (#22396) 2024-02-12 17:13:14 -07:00
js.rs chore: rename __runtime_js_source to hmr (#24442) 2024-07-05 17:47:53 +05:30
jsr.rs feat(lsp): workspace jsr resolution (#24121) 2024-06-10 17:03:17 +01:00
main.rs feat: deno remove (#24952) 2024-08-12 16:17:25 -04:00
mainrt.rs feat: codesign for deno compile binaries (#24604) 2024-08-01 09:45:13 +05:30
module_loader.rs feat: upgrade V8 to 12.8 (#24693) 2024-07-31 23:22:34 +00:00
node.rs refactor: decouple node resolution from deno_core (#24724) 2024-07-25 19:08:14 -04:00
README.md docs(cli): do not need gen doc for cli (#17260) 2023-01-04 13:19:58 +01:00
resolver.rs fix(compile): support workspace members importing other members (#24909) 2024-08-07 07:43:05 +00:00
task_runner.rs fix(cli): Respect implied BYONM from DENO_FUTURE in deno task (#24652) 2024-07-19 18:59:04 +00:00
version.rs chore: update copyright to 2024 (#21753) 2024-01-01 19:58:21 +00:00
worker.rs refactor: decouple node resolution from deno_core (#24724) 2024-07-25 19:08:14 -04:00

Deno CLI Crate

crates

This provides the actual deno executable and the user-facing APIs.

The deno crate uses the deno_core to provide the executable.