@buoy-gg/network 7.0.40 → 7.0.41
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/README.md +6 -0
- package/lib/commonjs/index.js +7 -0
- package/lib/commonjs/network/components/NetworkListScreen.js +2 -3
- package/lib/commonjs/network/components/NetworkListScreen.web.js +2 -3
- package/lib/commonjs/network/components/NetworkModal.js +1 -1
- package/lib/commonjs/network/conditions/xhr.js +26 -1
- package/lib/commonjs/network/overrides/applyToXhr.js +99 -42
- package/lib/commonjs/network/overrides/matchRule.js +7 -1
- package/lib/commonjs/network/overrides/overriddenRows.js +37 -0
- package/lib/commonjs/network/utils/networkEventStore.js +24 -6
- package/lib/commonjs/network/utils/networkListener.js +104 -11
- package/lib/commonjs/network/utils/networkSavedStore.js +4 -4
- package/lib/commonjs/network/utils/requestId.js +16 -0
- package/lib/commonjs/network/utils/resolveRequestUrl.js +15 -0
- package/lib/commonjs/network/utils/startNetworkCapture.js +24 -0
- package/lib/commonjs/preset.js +3 -12
- package/lib/module/index.js +1 -0
- package/lib/module/network/components/NetworkListScreen.js +2 -3
- package/lib/module/network/components/NetworkListScreen.web.js +2 -3
- package/lib/module/network/components/NetworkModal.js +1 -1
- package/lib/module/network/conditions/xhr.js +27 -2
- package/lib/module/network/overrides/applyToXhr.js +98 -42
- package/lib/module/network/overrides/matchRule.js +7 -1
- package/lib/module/network/overrides/overriddenRows.js +33 -0
- package/lib/module/network/utils/networkEventStore.js +25 -7
- package/lib/module/network/utils/networkListener.js +104 -12
- package/lib/module/network/utils/networkSavedStore.js +4 -4
- package/lib/module/network/utils/requestId.js +12 -0
- package/lib/module/network/utils/resolveRequestUrl.js +11 -0
- package/lib/module/network/utils/startNetworkCapture.js +21 -0
- package/lib/module/preset.js +3 -12
- package/lib/typescript/index.d.ts +1 -0
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/network/components/NetworkListScreen.d.ts.map +1 -1
- package/lib/typescript/network/components/NetworkListScreen.web.d.ts.map +1 -1
- package/lib/typescript/network/conditions/xhr.d.ts.map +1 -1
- package/lib/typescript/network/overrides/applyToXhr.d.ts +1 -0
- package/lib/typescript/network/overrides/applyToXhr.d.ts.map +1 -1
- package/lib/typescript/network/overrides/matchRule.d.ts.map +1 -1
- package/lib/typescript/network/overrides/overriddenRows.d.ts +16 -0
- package/lib/typescript/network/overrides/overriddenRows.d.ts.map +1 -0
- package/lib/typescript/network/utils/networkEventStore.d.ts.map +1 -1
- package/lib/typescript/network/utils/networkListener.d.ts +3 -4
- package/lib/typescript/network/utils/networkListener.d.ts.map +1 -1
- package/lib/typescript/network/utils/networkSavedStore.d.ts +4 -4
- package/lib/typescript/network/utils/requestId.d.ts +2 -0
- package/lib/typescript/network/utils/requestId.d.ts.map +1 -0
- package/lib/typescript/network/utils/resolveRequestUrl.d.ts +3 -0
- package/lib/typescript/network/utils/resolveRequestUrl.d.ts.map +1 -0
- package/lib/typescript/network/utils/startNetworkCapture.d.ts +6 -0
- package/lib/typescript/network/utils/startNetworkCapture.d.ts.map +1 -0
- package/lib/typescript/preset.d.ts.map +1 -1
- package/lib/web/index.mjs +146 -0
- package/package.json +32 -10
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
import { resolveRequestUrl } from "./resolveRequestUrl";
|
|
4
|
+
import { nextRequestId } from "./requestId";
|
|
3
5
|
import { runConditionXhr } from "../conditions/xhr";
|
|
4
6
|
import { snapshotNetworkCondition } from "../conditions/store";
|
|
5
7
|
import { throwIfAborted, waitBeforeDispatch } from "../conditions/wait";
|
|
@@ -9,10 +11,62 @@ import { throwIfAborted, waitBeforeDispatch } from "../conditions/wait";
|
|
|
9
11
|
*/
|
|
10
12
|
|
|
11
13
|
import { overrideForRequest } from "../overrides/engine";
|
|
12
|
-
import { runOverride } from "../overrides/applyToXhr";
|
|
14
|
+
import { runOverride, hasPendingStandardRequest } from "../overrides/applyToXhr";
|
|
13
15
|
import { canSynthesizeResponse, synthesizeFetchError, synthesizeResponse } from "../overrides/applyToFetch";
|
|
14
16
|
import { markForOutcome } from "../overrides/types";
|
|
15
17
|
import { httpStatusText, xhrCompletionKind } from "./httpCompletion";
|
|
18
|
+
let devOrigin;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Headers another Buoy tool adds to a request inside our wrapper.
|
|
22
|
+
*
|
|
23
|
+
* Impersonate patches fetch/XHR at boot, so this listener usually wraps it
|
|
24
|
+
* and records the request before the impersonation header is added. The
|
|
25
|
+
* request on the wire carried the header and the Network row did not. Tools
|
|
26
|
+
* that add headers register a function here, keyed by URL, so the row shows
|
|
27
|
+
* what was actually sent.
|
|
28
|
+
*/
|
|
29
|
+
function injectedHeaders(url) {
|
|
30
|
+
const injectors = globalThis.__buoyHeaderInjectors;
|
|
31
|
+
if (!injectors || injectors.length === 0) return undefined;
|
|
32
|
+
let out;
|
|
33
|
+
for (const inject of injectors) {
|
|
34
|
+
try {
|
|
35
|
+
const h = inject(url);
|
|
36
|
+
if (h) out = {
|
|
37
|
+
...out,
|
|
38
|
+
...h
|
|
39
|
+
};
|
|
40
|
+
} catch {
|
|
41
|
+
/* a broken injector must not break capture */
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
return out;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Origin of the Metro dev server this JS bundle was loaded from, read once from
|
|
49
|
+
* the bundle URL React Native reports. `null` in release builds (the bundle is
|
|
50
|
+
* a file) and anywhere react-native isn't present.
|
|
51
|
+
*/
|
|
52
|
+
function devServerOrigin() {
|
|
53
|
+
if (devOrigin !== undefined) return devOrigin;
|
|
54
|
+
devOrigin = null;
|
|
55
|
+
try {
|
|
56
|
+
if (typeof __DEV__ !== "undefined" && !__DEV__) return devOrigin;
|
|
57
|
+
// eslint-disable-next-line @typescript-eslint/no-require-imports
|
|
58
|
+
const rn = require("react-native");
|
|
59
|
+
const sc = rn?.NativeModules?.SourceCode;
|
|
60
|
+
const url = sc?.getConstants?.().scriptURL ?? sc?.scriptURL;
|
|
61
|
+
if (typeof url === "string" && /^https?:\/\//.test(url)) {
|
|
62
|
+
const u = new URL(url);
|
|
63
|
+
devOrigin = `${u.protocol}//${u.host}`;
|
|
64
|
+
}
|
|
65
|
+
} catch {
|
|
66
|
+
devOrigin = null;
|
|
67
|
+
}
|
|
68
|
+
return devOrigin;
|
|
69
|
+
}
|
|
16
70
|
|
|
17
71
|
/**
|
|
18
72
|
* True only while `originalFetch` is being CALLED (not awaited).
|
|
@@ -119,7 +173,6 @@ function isInternalBuoyHost(url) {
|
|
|
119
173
|
class NetworkListener {
|
|
120
174
|
listeners = [];
|
|
121
175
|
isListening = false;
|
|
122
|
-
requestCounter = 1000;
|
|
123
176
|
|
|
124
177
|
// Store original methods
|
|
125
178
|
|
|
@@ -167,6 +220,11 @@ class NetworkListener {
|
|
|
167
220
|
if ((parsed.hostname === "buoy.gg" || parsed.hostname === "www.buoy.gg") && parsed.pathname.startsWith("/api/license")) return true;
|
|
168
221
|
const local = parsed.hostname === "localhost" || parsed.hostname === "127.0.0.1" || parsed.hostname === "10.0.2.2";
|
|
169
222
|
if (local && ["8081", "8802"].includes(parsed.port)) return true;
|
|
223
|
+
// The dev server this bundle actually came from, whatever its host and
|
|
224
|
+
// port (a LAN address, --port 8082…): Metro's own traffic — symbolicate,
|
|
225
|
+
// logs, HMR, the bundle — is not the app's.
|
|
226
|
+
const dev = devServerOrigin();
|
|
227
|
+
if (dev && `${parsed.protocol}//${parsed.host}` === dev) return true;
|
|
170
228
|
} catch {
|
|
171
229
|
return false;
|
|
172
230
|
}
|
|
@@ -622,7 +680,7 @@ class NetworkListener {
|
|
|
622
680
|
this.originalFetch = globalThis.fetch;
|
|
623
681
|
const generation = ++this.fetchGeneration;
|
|
624
682
|
const wrappedFetch = async (input, init) => {
|
|
625
|
-
const url = typeof input === "string" ? input : input instanceof URL ? input.href : input.url;
|
|
683
|
+
const url = resolveRequestUrl(typeof input === "string" ? input : input instanceof URL ? input.href : input.url);
|
|
626
684
|
|
|
627
685
|
// A newer install supersedes this wrapper. If it is still stranded in
|
|
628
686
|
// another tool's chain it must pass through silently, or one request
|
|
@@ -636,7 +694,7 @@ class NetworkListener {
|
|
|
636
694
|
return passthroughFetch(input, init);
|
|
637
695
|
}
|
|
638
696
|
const startTime = Date.now();
|
|
639
|
-
const requestId =
|
|
697
|
+
const requestId = nextRequestId("fetch");
|
|
640
698
|
const inputRequest = typeof input === "object" && "method" in input ? input : undefined;
|
|
641
699
|
const method = init?.method ?? inputRequest?.method ?? "GET";
|
|
642
700
|
const signal = init?.signal !== undefined ? init.signal : inputRequest?.signal;
|
|
@@ -660,9 +718,12 @@ class NetworkListener {
|
|
|
660
718
|
requestHeaders[key] = value;
|
|
661
719
|
});
|
|
662
720
|
} else {
|
|
663
|
-
requestHeaders =
|
|
721
|
+
requestHeaders = {
|
|
722
|
+
...headers
|
|
723
|
+
};
|
|
664
724
|
}
|
|
665
725
|
}
|
|
726
|
+
Object.assign(requestHeaders, injectedHeaders(url));
|
|
666
727
|
|
|
667
728
|
// Parse request body
|
|
668
729
|
// Explicitly typed: the late emit for a streamed reply reads this from
|
|
@@ -711,6 +772,35 @@ class NetworkListener {
|
|
|
711
772
|
override,
|
|
712
773
|
condition
|
|
713
774
|
});
|
|
775
|
+
|
|
776
|
+
// Clone before dispatch; inspect the body without delaying or consuming the app's upload.
|
|
777
|
+
if (init?.body === undefined && inputRequest?.body && !inputRequest.bodyUsed) {
|
|
778
|
+
try {
|
|
779
|
+
const bodyCopy = inputRequest.clone();
|
|
780
|
+
void self.readStreamedBody(bodyCopy).then(({
|
|
781
|
+
body
|
|
782
|
+
}) => {
|
|
783
|
+
try {
|
|
784
|
+
requestData = JSON.parse(body);
|
|
785
|
+
} catch {
|
|
786
|
+
requestData = body;
|
|
787
|
+
}
|
|
788
|
+
self.emit({
|
|
789
|
+
type: "request-body",
|
|
790
|
+
timestamp: new Date(),
|
|
791
|
+
request: {
|
|
792
|
+
id: requestId || "unknown",
|
|
793
|
+
url: cleanUrl,
|
|
794
|
+
method,
|
|
795
|
+
data: requestData,
|
|
796
|
+
client: clientType
|
|
797
|
+
}
|
|
798
|
+
});
|
|
799
|
+
}).catch(() => {});
|
|
800
|
+
} catch {
|
|
801
|
+
// An unreadable body must not prevent the app's request.
|
|
802
|
+
}
|
|
803
|
+
}
|
|
714
804
|
try {
|
|
715
805
|
if (condition || outcome) await waitBeforeDispatch((condition?.delayMs ?? 0) + (outcome?.delayMs ?? 0), signal);
|
|
716
806
|
throwIfAborted(signal);
|
|
@@ -909,9 +999,9 @@ class NetworkListener {
|
|
|
909
999
|
if (generation === self.xhrGeneration) {
|
|
910
1000
|
pendingCapture.get(this)?.();
|
|
911
1001
|
const xhr = this;
|
|
912
|
-
xhr._buoyRequestId =
|
|
1002
|
+
xhr._buoyRequestId = nextRequestId("xhr");
|
|
913
1003
|
xhr._method = method;
|
|
914
|
-
xhr._url = url;
|
|
1004
|
+
xhr._url = resolveRequestUrl(url);
|
|
915
1005
|
xhr._buoyStartTime = Date.now();
|
|
916
1006
|
xhr._requestHeaders = {};
|
|
917
1007
|
}
|
|
@@ -933,6 +1023,7 @@ class NetworkListener {
|
|
|
933
1023
|
if (generation !== self.xhrGeneration || insideFetchHandoff) {
|
|
934
1024
|
return passthroughSend.call(this, data);
|
|
935
1025
|
}
|
|
1026
|
+
if (hasPendingStandardRequest(this)) throw new DOMException("The request has already been sent.", "InvalidStateError");
|
|
936
1027
|
if (this.readyState !== 1 || this._sent) {
|
|
937
1028
|
return passthroughSend.call(this, data);
|
|
938
1029
|
}
|
|
@@ -944,6 +1035,7 @@ class NetworkListener {
|
|
|
944
1035
|
xhr._buoyStartTime = startTime;
|
|
945
1036
|
xhr._buoyTtfb = undefined;
|
|
946
1037
|
const requestHeaders = xhr._requestHeaders || {};
|
|
1038
|
+
Object.assign(requestHeaders, injectedHeaders(url));
|
|
947
1039
|
|
|
948
1040
|
// Skip ignored URLs
|
|
949
1041
|
if (self.shouldIgnoreUrl(url)) {
|
|
@@ -1205,7 +1297,7 @@ export const startNetworkListener = () => getNetworkListener().startListening();
|
|
|
1205
1297
|
/**
|
|
1206
1298
|
* Stop network traffic monitoring
|
|
1207
1299
|
*/
|
|
1208
|
-
export const stopNetworkListener = () =>
|
|
1300
|
+
export const stopNetworkListener = () => _networkListener?.stopListening();
|
|
1209
1301
|
|
|
1210
1302
|
/**
|
|
1211
1303
|
* Add a listener for network events
|
|
@@ -1228,25 +1320,25 @@ export const addNetworkListener = listener => getNetworkListener().addListener(l
|
|
|
1228
1320
|
/**
|
|
1229
1321
|
* Remove all registered network event listeners
|
|
1230
1322
|
*/
|
|
1231
|
-
export const removeAllNetworkListeners = () =>
|
|
1323
|
+
export const removeAllNetworkListeners = () => _networkListener?.removeAllListeners();
|
|
1232
1324
|
|
|
1233
1325
|
/**
|
|
1234
1326
|
* Check if network monitoring is currently active
|
|
1235
1327
|
*
|
|
1236
1328
|
* @returns True if currently intercepting network traffic
|
|
1237
1329
|
*/
|
|
1238
|
-
export const isNetworkListening = () =>
|
|
1330
|
+
export const isNetworkListening = () => _networkListener?.isActive ?? false;
|
|
1239
1331
|
|
|
1240
1332
|
/**
|
|
1241
1333
|
* Get the number of registered network event listeners
|
|
1242
1334
|
*
|
|
1243
1335
|
* @returns Number of active listeners
|
|
1244
1336
|
*/
|
|
1245
|
-
export const getNetworkListenerCount = () =>
|
|
1337
|
+
export const getNetworkListenerCount = () => _networkListener?.listenerCount ?? 0;
|
|
1246
1338
|
|
|
1247
1339
|
/**
|
|
1248
1340
|
* Whether both interceptors are actually reachable through the live global
|
|
1249
1341
|
* chain — the honest version of `isNetworkListening` (whose flag stays true
|
|
1250
1342
|
* even after another tool re-assigns `globalThis.fetch` over the wrapper).
|
|
1251
1343
|
*/
|
|
1252
|
-
export const isNetworkInterceptionLive = () =>
|
|
1344
|
+
export const isNetworkInterceptionLive = () => _networkListener?.isInterceptionLive() ?? false;
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
* A record exists while either flag is true and is dropped when both go false,
|
|
16
16
|
* so all four states fall out without special cases.
|
|
17
17
|
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
18
|
+
* Request IDs include a runtime session and a counter. Saved records also
|
|
19
|
+
* track their owning session because live rows disappear on app reload.
|
|
20
|
+
* Records use a generated `key`, carry the `sessionId` that captured them,
|
|
21
|
+
* and only trust `liveId` while that
|
|
22
22
|
* session is the current one. Snapshots restored from an earlier session get
|
|
23
23
|
* their event `id` rewritten to `saved:<key>` so a restored pin can never
|
|
24
24
|
* resolve to (or dedupe against) an unrelated live request.
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
const runtime = globalThis;
|
|
4
|
+
|
|
5
|
+
// Keep identity across Fast Refresh; distinguish requests from earlier app runs.
|
|
6
|
+
export function nextRequestId(client) {
|
|
7
|
+
const sequence = runtime.__BUOY_NETWORK_REQUEST_SEQUENCE__ ??= {
|
|
8
|
+
session: `${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`,
|
|
9
|
+
next: 0
|
|
10
|
+
};
|
|
11
|
+
return `${client}_${sequence.session}_${++sequence.next}`;
|
|
12
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/** Resolve browser-relative URLs for capture without changing the request arguments. */
|
|
4
|
+
export function resolveRequestUrl(url) {
|
|
5
|
+
if (typeof document === "undefined") return url;
|
|
6
|
+
try {
|
|
7
|
+
return new URL(url, document.baseURI).href;
|
|
8
|
+
} catch {
|
|
9
|
+
return url;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { networkEventStore } from "./networkEventStore";
|
|
4
|
+
import { overrideRulesStore } from "../overrides/overrideRulesStore";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Keep local capture active while the Network panel is closed.
|
|
8
|
+
* Call in the app being inspected and dispose during unmount or HMR cleanup.
|
|
9
|
+
*/
|
|
10
|
+
export function startNetworkCapture() {
|
|
11
|
+
const native = typeof navigator !== "undefined" && navigator.product === "ReactNative";
|
|
12
|
+
if (!native && (typeof window === "undefined" || typeof document === "undefined")) return () => {};
|
|
13
|
+
void overrideRulesStore.ensureLoaded();
|
|
14
|
+
const unsubscribe = networkEventStore.subscribeToEvents(() => {});
|
|
15
|
+
let stopped = false;
|
|
16
|
+
return () => {
|
|
17
|
+
if (stopped) return;
|
|
18
|
+
stopped = true;
|
|
19
|
+
unsubscribe();
|
|
20
|
+
};
|
|
21
|
+
}
|
package/lib/module/preset.js
CHANGED
|
@@ -23,18 +23,6 @@ import { NetworkModal } from "./network/components/NetworkModal";
|
|
|
23
23
|
import { overrideRulesStore } from "./network/overrides/overrideRulesStore";
|
|
24
24
|
import { networkEventStore } from "./network/utils/networkEventStore";
|
|
25
25
|
|
|
26
|
-
/**
|
|
27
|
-
* Load persisted response-override rules as soon as the tool is registered.
|
|
28
|
-
*
|
|
29
|
-
* Deliberately at import time rather than when the Network modal mounts: an
|
|
30
|
-
* override has to fire from app boot, with the tool closed and nothing
|
|
31
|
-
* capturing — that is the whole point of persisting rules ("force this endpoint
|
|
32
|
-
* to 500, then restart and watch the boot path"). Hydrating also re-installs
|
|
33
|
-
* the interceptor if any rule is still active. One storage read, dev-only.
|
|
34
|
-
*/
|
|
35
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
36
|
-
void overrideRulesStore.ensureLoaded();
|
|
37
|
-
|
|
38
26
|
/**
|
|
39
27
|
* Install interception at IMPORT time and buffer boot traffic.
|
|
40
28
|
*
|
|
@@ -51,7 +39,10 @@ void overrideRulesStore.ensureLoaded();
|
|
|
51
39
|
* never intercept their OWN process's traffic.
|
|
52
40
|
* - Dev-only, like the rest of the automatic capture behavior.
|
|
53
41
|
*/
|
|
42
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
54
43
|
const isReactNativeRuntime = typeof navigator !== "undefined" && navigator.product === "ReactNative";
|
|
44
|
+
// Browser capture initializes persisted rules explicitly through startNetworkCapture.
|
|
45
|
+
if (isReactNativeRuntime) void overrideRulesStore.ensureLoaded();
|
|
55
46
|
if (isReactNativeRuntime && typeof __DEV__ !== "undefined" && __DEV__) {
|
|
56
47
|
networkEventStore.startBootCapture();
|
|
57
48
|
}
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* bypassing the tool's intended usage patterns.
|
|
9
9
|
*/
|
|
10
10
|
export { networkToolPreset, createNetworkTool } from "./preset";
|
|
11
|
+
export { startNetworkCapture } from "./network/utils/startNetworkCapture";
|
|
11
12
|
export { NetworkModal, NetworkToolView } from "./network/components/NetworkModal";
|
|
12
13
|
export type { NetworkToolViewProps } from "./network/components/NetworkModal";
|
|
13
14
|
export { NetworkEventDetailView } from "./network/components/NetworkEventDetailView";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAKH,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAKH,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,MAAM,qCAAqC,CAAC;AAO1E,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AAClF,YAAY,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAC9E,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,uBAAuB,EAAE,MAAM,8CAA8C,CAAC;AACvF,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AA2B,CAAC;AAQnC,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,wBAAwB,EACxB,YAAY,GACb,MAAM,oBAAoB,CAAC;AAK5B,OAAO,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAC;AACvE,OAAO,EACL,2BAA2B,EAC3B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB,MAAM,oCAAoC,CAAC;AAO5C,gBAAgB;AAChB,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AACtE;;;GAGG;AACH,OAAO,EACL,iBAAiB,EACjB,eAAe,EACf,qBAAqB,EACrB,UAAU,EACV,SAAS,EACT,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,GACvB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,gBAAgB;AAChB,OAAO,EACL,eAAe,EACf,kBAAkB,EAClB,yBAAyB,GAC1B,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,0BAA0B,EAAE,MAAM,4BAA4B,CAAC;AACtI,YAAY,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NetworkListScreen.d.ts","sourceRoot":"","sources":["../../../../src/network/components/NetworkListScreen.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAIH,OAAO,EAML,KAAK,cAAc,EAKpB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA6I5D,UAAU,sBAAsB;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,EAAE,aAAa,CAAC;IACtB,eAAe,EAAE,SAAS,cAAc,EAAE,CAAC;IAC3C,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,wEAAwE;IACxE,YAAY,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAC5C,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,MAAM,EACN,MAAM,EACN,eAAe,EACf,KAAK,EACL,UAAU,EACV,YAAY,EACZ,cAAc,GACf,EAAE,sBAAsB,
|
|
1
|
+
{"version":3,"file":"NetworkListScreen.d.ts","sourceRoot":"","sources":["../../../../src/network/components/NetworkListScreen.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAIH,OAAO,EAML,KAAK,cAAc,EAKpB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA6I5D,UAAU,sBAAsB;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,EAAE,aAAa,CAAC;IACtB,eAAe,EAAE,SAAS,cAAc,EAAE,CAAC;IAC3C,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,wEAAwE;IACxE,YAAY,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAC5C,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,MAAM,EACN,MAAM,EACN,eAAe,EACf,KAAK,EACL,UAAU,EACV,YAAY,EACZ,cAAc,GACf,EAAE,sBAAsB,sCAgLxB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NetworkListScreen.web.d.ts","sourceRoot":"","sources":["../../../../src/network/components/NetworkListScreen.web.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA8Q5D,UAAU,sBAAsB;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,EAAE,aAAa,CAAC;IACtB,eAAe,EAAE,SAAS,cAAc,EAAE,CAAC;IAC3C,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,wEAAwE;IACxE,YAAY,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAC5C,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,MAAM,EACN,MAAM,EACN,eAAe,EACf,KAAK,EACL,UAAU,EACV,YAAY,EACZ,cAAc,GACf,EAAE,sBAAsB,
|
|
1
|
+
{"version":3,"file":"NetworkListScreen.web.d.ts","sourceRoot":"","sources":["../../../../src/network/components/NetworkListScreen.web.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA8Q5D,UAAU,sBAAsB;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,EAAE,aAAa,CAAC;IACtB,eAAe,EAAE,SAAS,cAAc,EAAE,CAAC;IAC3C,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,wEAAwE;IACxE,YAAY,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAC5C,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,MAAM,EACN,MAAM,EACN,eAAe,EACf,KAAK,EACL,UAAU,EACV,YAAY,EACZ,cAAc,GACf,EAAE,sBAAsB,sCAwHxB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"xhr.d.ts","sourceRoot":"","sources":["../../../../src/network/conditions/xhr.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAYrD,gFAAgF;AAChF,wBAAgB,eAAe,CAC7B,MAAM,EAAE,cAAc,EACtB,GAAG,EAAE,MAAM,EACX,SAAS,EAAE,qBAAqB,EAChC,OAAO,EAAE,eAAe,GAAG,IAAI,EAC/B,QAAQ,EAAE,MAAM,IAAI,GACnB,IAAI,
|
|
1
|
+
{"version":3,"file":"xhr.d.ts","sourceRoot":"","sources":["../../../../src/network/conditions/xhr.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAYrD,gFAAgF;AAChF,wBAAgB,eAAe,CAC7B,MAAM,EAAE,cAAc,EACtB,GAAG,EAAE,MAAM,EACX,SAAS,EAAE,qBAAqB,EAChC,OAAO,EAAE,eAAe,GAAG,IAAI,EAC/B,QAAQ,EAAE,MAAM,IAAI,GACnB,IAAI,CAyFN"}
|
|
@@ -57,6 +57,7 @@ export declare function canSynthesize(xhr: XMLHttpRequest): boolean;
|
|
|
57
57
|
* rules out half-mocks that could take the branch and then leak listeners.
|
|
58
58
|
*/
|
|
59
59
|
export declare function canSynthesizeStandard(xhr: XMLHttpRequest): boolean;
|
|
60
|
+
export declare function hasPendingStandardRequest(xhr: XMLHttpRequest): boolean;
|
|
60
61
|
/**
|
|
61
62
|
* Apply an outcome to a request that has NOT been sent yet.
|
|
62
63
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"applyToXhr.d.ts","sourceRoot":"","sources":["../../../../src/network/overrides/applyToXhr.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAkC/C;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAM1D;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAMlE;
|
|
1
|
+
{"version":3,"file":"applyToXhr.d.ts","sourceRoot":"","sources":["../../../../src/network/overrides/applyToXhr.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAkC/C;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAM1D;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAMlE;AAqQD,wBAAgB,yBAAyB,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAEtE;AAqGD;;;;;;;GAOG;AACH,wBAAgB,WAAW,CACzB,GAAG,EAAE,cAAc,EACnB,GAAG,EAAE,MAAM,EACX,OAAO,EAAE,eAAe,EACxB,WAAW,EAAE,MAAM,IAAI,GACtB,OAAO,CAmET;AAED,iFAAiF;AACjF,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,eAAe,GAAG,IAAI,CAGvG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"matchRule.d.ts","sourceRoot":"","sources":["../../../../src/network/overrides/matchRule.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAU5C;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAUnD;AAWD,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"matchRule.d.ts","sourceRoot":"","sources":["../../../../src/network/overrides/matchRule.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAU5C;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAUnD;AAWD,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAmBtD;AAED,kFAAkF;AAClF,wBAAgB,WAAW,CACzB,IAAI,EAAE,YAAY,EAClB,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,MAAM,GACb,OAAO,CAWT"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { NetworkEvent } from "../types";
|
|
2
|
+
import type { OverrideRule } from "./types";
|
|
3
|
+
/**
|
|
4
|
+
* Which captured requests belong in the list's OVERRIDDEN strip.
|
|
5
|
+
*
|
|
6
|
+
* A row belongs there when an active rule actually changed it (it carries the
|
|
7
|
+
* rule's override mark) or matched it after the rule existed (while overrides
|
|
8
|
+
* are paused those pass through, and the strip is how you find the rule again).
|
|
9
|
+
* Before a rule existed nothing overrode anything, so older matching requests
|
|
10
|
+
* are real server responses and stay in the list, with one exception: the
|
|
11
|
+
* newest of them, which is the request the rule was built from. That one hoists
|
|
12
|
+
* right away, so creating a rule shows where it points without waiting for the
|
|
13
|
+
* endpoint to be called again.
|
|
14
|
+
*/
|
|
15
|
+
export declare function overriddenEvents(events: NetworkEvent[], activeRules: OverrideRule[]): NetworkEvent[];
|
|
16
|
+
//# sourceMappingURL=overriddenRows.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overriddenRows.d.ts","sourceRoot":"","sources":["../../../../src/network/overrides/overriddenRows.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C;;;;;;;;;;;GAWG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,YAAY,EAAE,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,YAAY,EAAE,CAkBpG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"networkEventStore.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/networkEventStore.ts"],"names":[],"mappings":"AACA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"networkEventStore.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/networkEventStore.ts"],"names":[],"mappings":"AACA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAUzD;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;AAEjE;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,MAAM,EAAE,YAAY,EAAE,KAAK,IAAI,CAAC;AAU1E,cAAM,iB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Y,EAAE;CAyCnB;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,mBAA0B,CAAC"}
|
|
@@ -6,7 +6,7 @@ import { type NetworkConditionStamp } from "../conditions/store";
|
|
|
6
6
|
import type { NetworkTimings } from "../types";
|
|
7
7
|
import { type NetworkOverrideMark } from "../overrides/types";
|
|
8
8
|
export interface NetworkingEvent {
|
|
9
|
-
type: "request" | "response" | "error";
|
|
9
|
+
type: "request" | "request-body" | "response" | "error";
|
|
10
10
|
timestamp: Date;
|
|
11
11
|
/** Total: request start → body fully received. */
|
|
12
12
|
duration?: number;
|
|
@@ -52,7 +52,6 @@ export declare const BUOY_XHR_INTERCEPTOR_FLAG = "__buoyNetworkXhrIntercepted";
|
|
|
52
52
|
declare class NetworkListener {
|
|
53
53
|
private listeners;
|
|
54
54
|
private isListening;
|
|
55
|
-
private requestCounter;
|
|
56
55
|
private originalFetch;
|
|
57
56
|
private originalXHROpen;
|
|
58
57
|
private originalXHRSend;
|
|
@@ -194,7 +193,7 @@ export declare const startNetworkListener: () => void;
|
|
|
194
193
|
/**
|
|
195
194
|
* Stop network traffic monitoring
|
|
196
195
|
*/
|
|
197
|
-
export declare const stopNetworkListener: () => void;
|
|
196
|
+
export declare const stopNetworkListener: () => void | undefined;
|
|
198
197
|
/**
|
|
199
198
|
* Add a listener for network events
|
|
200
199
|
*
|
|
@@ -215,7 +214,7 @@ export declare const addNetworkListener: (listener: NetworkingEventListener) =>
|
|
|
215
214
|
/**
|
|
216
215
|
* Remove all registered network event listeners
|
|
217
216
|
*/
|
|
218
|
-
export declare const removeAllNetworkListeners: () => void;
|
|
217
|
+
export declare const removeAllNetworkListeners: () => void | undefined;
|
|
219
218
|
/**
|
|
220
219
|
* Check if network monitoring is currently active
|
|
221
220
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"networkListener.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/networkListener.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"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Cb;;;;;OAKG;IACH,WAAW,CAAC,QAAQ,EAAE,uBAAuB;IAa7C,kBAAkB;IAKlB,IAAI,QAAQ,YAEX;IAGD,IAAI,aAAa,WAEhB;CACF;AAsBD;;;;GAIG;AACH,eAAO,MAAM,eAAe,uBAAqB,CAAC;AAElD;;;;;;;;GAQG;AACH,eAAO,MAAM,oBAAoB,YAA8C,CAAC;AAEhF;;GAEG;AACH,eAAO,MAAM,mBAAmB,wBAA0C,CAAC;AAE3E;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,GAAI,UAAU,uBAAuB,eACxB,CAAC;AAE7C;;GAEG;AACH,eAAO,MAAM,yBAAyB,wBACE,CAAC;AAEzC;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,eAA4C,CAAC;AAE5E;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,cAA6C,CAAC;AAElF;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,eACW,CAAC"}
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
* A record exists while either flag is true and is dropped when both go false,
|
|
14
14
|
* so all four states fall out without special cases.
|
|
15
15
|
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
16
|
+
* Request IDs include a runtime session and a counter. Saved records also
|
|
17
|
+
* track their owning session because live rows disappear on app reload.
|
|
18
|
+
* Records use a generated `key`, carry the `sessionId` that captured them,
|
|
19
|
+
* and only trust `liveId` while that
|
|
20
20
|
* session is the current one. Snapshots restored from an earlier session get
|
|
21
21
|
* their event `id` rewritten to `saved:<key>` so a restored pin can never
|
|
22
22
|
* resolve to (or dedupe against) an unrelated live request.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requestId.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/requestId.ts"],"names":[],"mappings":"AAOA,wBAAgB,aAAa,CAAC,MAAM,EAAE,OAAO,GAAG,KAAK,GAAG,MAAM,CAM7D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolveRequestUrl.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/resolveRequestUrl.ts"],"names":[],"mappings":"AAAA,wFAAwF;AACxF,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAIrD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"startNetworkCapture.d.ts","sourceRoot":"","sources":["../../../../src/network/utils/startNetworkCapture.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,wBAAgB,mBAAmB,IAAI,MAAM,IAAI,CAWhD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"preset.d.ts","sourceRoot":"","sources":["../../src/preset.tsx"],"names":[],"mappings":"AAmBA,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;
|
|
1
|
+
{"version":3,"file":"preset.d.ts","sourceRoot":"","sources":["../../src/preset.tsx"],"names":[],"mappings":"AAmBA,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AA4BjE;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB;;;;;qBAKX;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE;;;;;CAKjC,CAAC;AAEH;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,iBAAiB;IAG1B,qCAAqC;kCACP,OAAO;;;;;;qBA1BtB;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE;;;;;CA8BlC,CAAC"}
|