mirror of
https://github.com/denoland/deno.git
synced 2025-09-26 12:19:12 +00:00
refactor(cli/js): Replace constructError() with getErrorClass() (#4189)
Flattens dispatch error handling to produce one less useless stack frame on op errors.
This commit is contained in:
parent
f55b22e195
commit
1f9d158bdc
10 changed files with 32 additions and 39 deletions
|
@ -1,7 +1,6 @@
|
|||
[WILDCARD]
|
||||
error: Uncaught BadResource: bad resource id
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at BadResource ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at constructError ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at unwrapResponse ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
at sendAsync ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught NotFound: Cannot resolve module "[WILDCARD]/bad-module.ts" from "[WILDCARD]/error_004_missing_module.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at NotFound ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at constructError ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at unwrapResponse ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
at sendAsync[WILDCARD] ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught NotFound: Cannot resolve module "[WILDCARD]/bad-module.ts" from "[WILDCARD]/error_005_missing_dynamic_import.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at NotFound ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at constructError ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at unwrapResponse ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
at sendAsync[WILDCARD] ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught NotFound: Cannot resolve module "[WILDCARD]/non-existent" from "[WILDCARD]/error_006_import_ext_failure.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at NotFound ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at constructError ([WILDCARD]errors.ts:[WILDCARD])
|
||||
at unwrapResponse ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
at sendAsync[WILDCARD] ([WILDCARD]dispatch_json.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught URIError: relative import path "bad-module.ts" not prefixed with / or ./ or ../ Imported from "[WILDCARD]/error_011_bad_module_specifier.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
at constructError ($deno$/errors.ts:[WILDCARD])
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at unwrapResponse ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at sendSync ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at resolveModules ($deno$/compiler_imports.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught URIError: relative import path "bad-module.ts" not prefixed with / or ./ or ../ Imported from "[WILDCARD]/error_012_bad_dynamic_import_specifier.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
at constructError ($deno$/errors.ts:[WILDCARD])
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at unwrapResponse ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at sendSync ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at resolveModules ($deno$/compiler_imports.ts:[WILDCARD])
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[WILDCARD]error: Uncaught URIError: relative import path "baz" not prefixed with / or ./ or ../ Imported from "[WILDCARD]/type_definitions/bar.d.ts"
|
||||
[WILDCARD]errors.ts:[WILDCARD]
|
||||
at constructError ($deno$/errors.ts:[WILDCARD])
|
||||
[WILDCARD]dispatch_json.ts:[WILDCARD]
|
||||
at unwrapResponse ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at sendSync ($deno$/dispatch_json.ts:[WILDCARD])
|
||||
at resolveModules ($deno$/compiler_imports.ts:[WILDCARD])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue