@veryfront/ext-content-mdx 0.1.1289-rc.26257 → 0.1.1289-rc.26273
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/deno.js +1 -1
- package/esm/src/observability/telemetry-error.d.ts.map +1 -1
- package/esm/src/observability/telemetry-error.js +6 -2
- package/esm/src/platform/compat/http/pinned-fetch.d.ts +1 -1
- package/esm/src/runtime/provider-stream-error-provenance.d.ts +13 -0
- package/esm/src/runtime/provider-stream-error-provenance.d.ts.map +1 -1
- package/esm/src/runtime/provider-stream-error-provenance.js +23 -0
- package/esm/src/utils/version-constant.d.ts +1 -1
- package/esm/src/utils/version-constant.js +1 -1
- package/package.json +4 -4
package/esm/deno.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"telemetry-error.d.ts","sourceRoot":"","sources":["../../../src/src/observability/telemetry-error.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"telemetry-error.d.ts","sourceRoot":"","sources":["../../../src/src/observability/telemetry-error.ts"],"names":[],"mappings":"AA0LA,MAAM,MAAM,uBAAuB,GAC/B,MAAM,GACN,MAAM,GACN,OAAO,GACP,SAAS,CAAC,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,EAAE,GACtC,SAAS,CAAC;AAUd,6EAA6E;AAC7E,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAK9E;AAcD,qDAAqD;AACrD,wBAAgB,+BAA+B,CAC7C,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,uBAAuB,GAC7B,uBAAuB,CAsBzB;AAQD,wEAAwE;AACxE,wBAAgB,2BAA2B,CACzC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,uBAAuB,CAAC,GAAG,SAAS,EAC7D,UAAU,EAAE,CAAC,GAAG,CAAC,CAuClB;AAkLD;;;GAGG;AACH,wBAAgB,+BAA+B,CAAC,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AAgB,EAAE,GAAG,SAAS,CA0BzF"}
|
|
@@ -3,7 +3,7 @@ import { LOG_PREVIEW_MAX_LENGTH_CHARS, MAX_STRING_DISPLAY_LENGTH, MAX_TRACE_ATTR
|
|
|
3
3
|
import { MAX_OBSERVABILITY_CONFIG_TEXT_LENGTH, MAX_STRUCTURED_TELEMETRY_CONTAINER_ENTRIES, MAX_STRUCTURED_TELEMETRY_DEPTH, MAX_STRUCTURED_TELEMETRY_NODES, MAX_TELEMETRY_ATTRIBUTE_ARRAY_LENGTH, MAX_TELEMETRY_ATTRIBUTE_COUNT, MAX_TELEMETRY_ATTRIBUTE_KEY_LENGTH, } from "./limits.js";
|
|
4
4
|
import { snapshotVeryfrontError } from "../errors/types.js";
|
|
5
5
|
import { isNativeErrorWithoutHooks, isProxyWithoutHooks, readNativeErrorNameWithoutHooks, readNativeErrorStackWithoutHooks, } from "../platform/compat/error-introspection.js";
|
|
6
|
-
import { readRuntimeProviderStreamFailureCause } from "../runtime/provider-stream-error-provenance.js";
|
|
6
|
+
import { readRuntimeProviderStreamFailureCause, readStreamFailureDiagnosticCause, } from "../runtime/provider-stream-error-provenance.js";
|
|
7
7
|
import { readProviderErrorDiagnostic } from "../provider/runtime-loader/provider-error-diagnostic.js";
|
|
8
8
|
import { readStreamProtocolClassification } from "../provider/runtime-loader/stream-protocol-classification.js";
|
|
9
9
|
const apply = Reflect.apply;
|
|
@@ -518,13 +518,17 @@ const NO_CAUSE = Symbol("no-cause");
|
|
|
518
518
|
const MAX_LOGGED_ERROR_CAUSES = 4;
|
|
519
519
|
/**
|
|
520
520
|
* The failure an error wraps: the private cause of a provider stream failure,
|
|
521
|
-
* else a native error's own `cause` data
|
|
521
|
+
* else a recorded diagnostic cause, else a native error's own `cause` data
|
|
522
|
+
* property. Accessors are never run.
|
|
522
523
|
*/
|
|
523
524
|
function readErrorCause(error) {
|
|
524
525
|
try {
|
|
525
526
|
const providerFailure = readRuntimeProviderStreamFailureCause(error);
|
|
526
527
|
if (providerFailure.found)
|
|
527
528
|
return providerFailure.cause;
|
|
529
|
+
const diagnosticCause = readStreamFailureDiagnosticCause(error);
|
|
530
|
+
if (diagnosticCause.found)
|
|
531
|
+
return diagnosticCause.cause;
|
|
528
532
|
if (!isNativeErrorWithoutHooks(error))
|
|
529
533
|
return NO_CAUSE;
|
|
530
534
|
const descriptor = getOwnPropertyDescriptor(error, "cause");
|
|
@@ -49,7 +49,7 @@ export declare function assertNodeRequestMembersUnchanged(intrinsics: NodeTransp
|
|
|
49
49
|
* Client identity for guarded egress, standing in for the runtime-supplied
|
|
50
50
|
* `user-agent` (`node`, `Deno/x.y.z`) that this transport cannot inherit.
|
|
51
51
|
*/
|
|
52
|
-
export declare const DEFAULT_OUTBOUND_USER_AGENT = "veryfront/0.1.1289-rc.
|
|
52
|
+
export declare const DEFAULT_OUTBOUND_USER_AGENT = "veryfront/0.1.1289-rc.26273";
|
|
53
53
|
export interface PinnedFetchTlsOptions {
|
|
54
54
|
/**
|
|
55
55
|
* Complete trusted CA set for this connection. Passing this replaces the
|
|
@@ -7,4 +7,17 @@ export declare function readRuntimeProviderStreamFailureCause(error: unknown): {
|
|
|
7
7
|
found: true;
|
|
8
8
|
cause: unknown;
|
|
9
9
|
};
|
|
10
|
+
/**
|
|
11
|
+
* Record what a stream failure wraps, for diagnostics only. Unlike
|
|
12
|
+
* {@link createRuntimeProviderStreamFailure}, this does not mark the error as
|
|
13
|
+
* provider-owned, so its classification and public message do not change.
|
|
14
|
+
*/
|
|
15
|
+
export declare function recordStreamFailureDiagnosticCause(error: Error, cause: unknown): void;
|
|
16
|
+
/** Read a diagnostic cause without exposing it on the public error object. */
|
|
17
|
+
export declare function readStreamFailureDiagnosticCause(error: unknown): {
|
|
18
|
+
found: false;
|
|
19
|
+
} | {
|
|
20
|
+
found: true;
|
|
21
|
+
cause: unknown;
|
|
22
|
+
};
|
|
10
23
|
//# sourceMappingURL=provider-stream-error-provenance.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"provider-stream-error-provenance.d.ts","sourceRoot":"","sources":["../../../src/src/runtime/provider-stream-error-provenance.ts"],"names":[],"mappings":"AAcA,kEAAkE;AAClE,wBAAgB,kCAAkC,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,CAGxE;AAED,kFAAkF;AAClF,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,OAAO,GACb;IAAE,KAAK,EAAE,KAAK,CAAA;CAAE,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAcpD"}
|
|
1
|
+
{"version":3,"file":"provider-stream-error-provenance.d.ts","sourceRoot":"","sources":["../../../src/src/runtime/provider-stream-error-provenance.ts"],"names":[],"mappings":"AAcA,kEAAkE;AAClE,wBAAgB,kCAAkC,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,CAGxE;AAED,kFAAkF;AAClF,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,OAAO,GACb;IAAE,KAAK,EAAE,KAAK,CAAA;CAAE,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAcpD;AAID;;;;GAIG;AACH,wBAAgB,kCAAkC,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CAErF;AAED,8EAA8E;AAC9E,wBAAgB,gCAAgC,CAC9C,KAAK,EAAE,OAAO,GACb;IAAE,KAAK,EAAE,KAAK,CAAA;CAAE,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAcpD"}
|
|
@@ -30,3 +30,26 @@ export function readRuntimeProviderStreamFailureCause(error) {
|
|
|
30
30
|
cause: reflectApply(weakMapGet, runtimeProviderStreamFailureCauses, [error]),
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
|
+
const streamFailureDiagnosticCauses = new WeakMap();
|
|
34
|
+
/**
|
|
35
|
+
* Record what a stream failure wraps, for diagnostics only. Unlike
|
|
36
|
+
* {@link createRuntimeProviderStreamFailure}, this does not mark the error as
|
|
37
|
+
* provider-owned, so its classification and public message do not change.
|
|
38
|
+
*/
|
|
39
|
+
export function recordStreamFailureDiagnosticCause(error, cause) {
|
|
40
|
+
reflectApply(weakMapSet, streamFailureDiagnosticCauses, [error, cause]);
|
|
41
|
+
}
|
|
42
|
+
/** Read a diagnostic cause without exposing it on the public error object. */
|
|
43
|
+
export function readStreamFailureDiagnosticCause(error) {
|
|
44
|
+
if ((typeof error !== "object" || error === null) &&
|
|
45
|
+
typeof error !== "function") {
|
|
46
|
+
return { found: false };
|
|
47
|
+
}
|
|
48
|
+
if (!reflectApply(weakMapHas, streamFailureDiagnosticCauses, [error])) {
|
|
49
|
+
return { found: false };
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
found: true,
|
|
53
|
+
cause: reflectApply(weakMapGet, streamFailureDiagnosticCauses, [error]),
|
|
54
|
+
};
|
|
55
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@veryfront/ext-content-mdx",
|
|
3
|
-
"version": "0.1.1289-rc.
|
|
3
|
+
"version": "0.1.1289-rc.26273",
|
|
4
4
|
"description": "Veryfront first-party extension package for ext-content-mdx",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"veryfront",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
"@types/hast": "3.0.3",
|
|
54
54
|
"@types/mdast": "4.0.3",
|
|
55
55
|
"@types/unist": "3.0.2",
|
|
56
|
-
"@veryfront/ext-parser-babel": "0.1.1289-rc.
|
|
56
|
+
"@veryfront/ext-parser-babel": "0.1.1289-rc.26273",
|
|
57
57
|
"acorn": "8.17.0",
|
|
58
58
|
"acorn-jsx": "5.3.2",
|
|
59
59
|
"github-slugger": "2.0.0",
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
"vfile": "6.0.3"
|
|
83
83
|
},
|
|
84
84
|
"peerDependencies": {
|
|
85
|
-
"veryfront": "^0.1.1289-rc.
|
|
85
|
+
"veryfront": "^0.1.1289-rc.26273"
|
|
86
86
|
},
|
|
87
87
|
"type": "module",
|
|
88
88
|
"types": "./esm/extensions/ext-content-mdx/src/index.d.ts",
|
|
@@ -92,5 +92,5 @@
|
|
|
92
92
|
"NOTICE",
|
|
93
93
|
"README.md"
|
|
94
94
|
],
|
|
95
|
-
"gitHead": "
|
|
95
|
+
"gitHead": "00d6e032498eba285a2f29a1e63a790a70130e2f"
|
|
96
96
|
}
|