aztrx-cli 0.2.2 → 0.2.4
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 +4 -4
- package/dist/core/interceptor.js +7 -1
- package/dist/core/networkGuard.js +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -196,7 +196,7 @@ jobs:
|
|
|
196
196
|
permissions: { contents: read, pull-requests: write }
|
|
197
197
|
steps:
|
|
198
198
|
- uses: actions/checkout@v4
|
|
199
|
-
- uses: DanisChaparov/aztrx@
|
|
199
|
+
- uses: DanisChaparov/aztrx@40570783592a768b5e012a984eee1ff334850a5d
|
|
200
200
|
with:
|
|
201
201
|
url: http://localhost:3000
|
|
202
202
|
start-command: npm run dev # optional — boot the app in the background
|
|
@@ -210,7 +210,7 @@ Or as a reusable workflow:
|
|
|
210
210
|
on: pull_request
|
|
211
211
|
jobs:
|
|
212
212
|
aztrx:
|
|
213
|
-
uses: DanisChaparov/aztrx/.github/workflows/aztrx-pr.yml@
|
|
213
|
+
uses: DanisChaparov/aztrx/.github/workflows/aztrx-pr.yml@40570783592a768b5e012a984eee1ff334850a5d
|
|
214
214
|
with:
|
|
215
215
|
url: http://localhost:3000
|
|
216
216
|
start-command: npm run dev
|
|
@@ -261,7 +261,7 @@ jobs:
|
|
|
261
261
|
sleep 2
|
|
262
262
|
done
|
|
263
263
|
- name: Generate badge
|
|
264
|
-
run: npx --yes aztrx-cli@0.2.
|
|
264
|
+
run: npx --yes aztrx-cli@0.2.4 run http://localhost:3000 --badge badge.svg
|
|
265
265
|
- name: Commit badge
|
|
266
266
|
run: |
|
|
267
267
|
git config user.name "github-actions[bot]"
|
|
@@ -320,7 +320,7 @@ LLM call.
|
|
|
320
320
|
CORS.
|
|
321
321
|
- **`.aztrx/` is gitignored** on `init` — repro specs, reports, and patches stay
|
|
322
322
|
out of history.
|
|
323
|
-
- **Pinned supply chain.** The GitHub Action pins `aztrx-cli@0.2.
|
|
323
|
+
- **Pinned supply chain.** The GitHub Action pins `aztrx-cli@0.2.4` (never
|
|
324
324
|
`@latest`).
|
|
325
325
|
|
|
326
326
|
## Telemetry & privacy
|
package/dist/core/interceptor.js
CHANGED
|
@@ -83,9 +83,15 @@ export function attachInterceptor(page, bus) {
|
|
|
83
83
|
});
|
|
84
84
|
page.on("requestfailed", (req) => {
|
|
85
85
|
const f = req.failure();
|
|
86
|
+
const errText = f?.errorText ?? "unknown";
|
|
87
|
+
// Cancelled/blocked requests are not bugs — a video preload dropped when the
|
|
88
|
+
// walk navigates away, a `mailto:` click, or an adblocker all surface as
|
|
89
|
+
// `requestfailed`. Skip them so they don't become false-positive errors.
|
|
90
|
+
if (/ERR_ABORTED|ERR_BLOCKED_BY_CLIENT|ERR_BLOCKED_BY_RESPONSE/.test(errText))
|
|
91
|
+
return;
|
|
86
92
|
bus.emit("telemetry", {
|
|
87
93
|
type: "network_timeout",
|
|
88
|
-
rawMessage: `Request failed: ${req.url()} (${
|
|
94
|
+
rawMessage: `Request failed: ${req.url()} (${errText})`,
|
|
89
95
|
rawStack: "",
|
|
90
96
|
});
|
|
91
97
|
});
|
|
@@ -11,7 +11,7 @@ export async function attachNetworkGuard(page, opts) {
|
|
|
11
11
|
host = new URL(url).hostname.toLowerCase();
|
|
12
12
|
}
|
|
13
13
|
catch {
|
|
14
|
-
await route.abort();
|
|
14
|
+
await route.abort("blockedbyclient");
|
|
15
15
|
return;
|
|
16
16
|
}
|
|
17
17
|
if (host === "localhost" || host === "127.0.0.1" || host === "::1") {
|
|
@@ -25,7 +25,7 @@ export async function attachNetworkGuard(page, opts) {
|
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
opts.onBlock?.(url);
|
|
28
|
-
await route.abort();
|
|
28
|
+
await route.abort("blockedbyclient");
|
|
29
29
|
});
|
|
30
30
|
}
|
|
31
31
|
/** Builds the allow-list: target origin + each `--allow-host`. */
|