@1aboveio/skills 1.0.7 → 1.0.9
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/.codex-plugin/plugin.json +13 -0
- package/.codex-plugin/resources.json +1827 -0
- package/README.md +22 -0
- package/package.json +9 -2
- package/skills/app-dev/airflow/SKILL.md +1 -1
- package/skills/app-dev/airflow/release-check.mjs +3 -1
- package/skills/app-dev/android-foundation/SKILL.md +92 -34
- package/skills/app-dev/android-foundation/assets/android-ci-job.yml +13 -7
- package/skills/app-dev/android-foundation/references/ci.md +23 -13
- package/skills/app-dev/android-foundation/references/delivery-focus.md +29 -0
- package/skills/app-dev/android-foundation/references/diagnosis.md +136 -0
- package/skills/app-dev/android-foundation/references/gotchas.md +20 -11
- package/skills/app-dev/android-foundation/references/setup.md +15 -6
- package/skills/app-dev/android-foundation/release-check.mjs +3 -1
- package/skills/app-dev/android-foundation/scripts/device-run.sh +148 -42
- package/skills/app-dev/app-debug/SKILL.md +1 -1
- package/skills/app-dev/app-debug/release-check.mjs +3 -1
- package/skills/app-dev/better-auth/SKILL.md +1 -1
- package/skills/app-dev/better-auth/release-check.mjs +3 -1
- package/skills/app-dev/data-catalog/SKILL.md +1 -1
- package/skills/app-dev/data-catalog/release-check.mjs +3 -1
- package/skills/app-dev/data-quality/SKILL.md +1 -1
- package/skills/app-dev/data-quality/release-check.mjs +3 -1
- package/skills/app-dev/ios-foundation/SKILL.md +1 -1
- package/skills/app-dev/ios-foundation/release-check.mjs +3 -1
- package/skills/app-dev/monorepo/SKILL.md +1 -1
- package/skills/app-dev/monorepo/release-check.mjs +3 -1
- package/skills/app-dev/nextjs-fullstack/SKILL.md +1 -1
- package/skills/app-dev/nextjs-fullstack/release-check.mjs +3 -1
- package/skills/app-dev/prisma-setup/SKILL.md +1 -1
- package/skills/app-dev/prisma-setup/release-check.mjs +3 -1
- package/skills/app-dev/pyspark/SKILL.md +1 -1
- package/skills/app-dev/pyspark/release-check.mjs +3 -1
- package/skills/app-dev/python-backend/SKILL.md +1 -1
- package/skills/app-dev/python-backend/release-check.mjs +3 -1
- package/skills/app-dev/shadcn/SKILL.md +1 -1
- package/skills/app-dev/shadcn/release-check.mjs +3 -1
- package/skills/app-dev/zod-v4/SKILL.md +1 -1
- package/skills/app-dev/zod-v4/release-check.mjs +3 -1
- package/skills/cicd/cloud-build/SKILL.md +1 -1
- package/skills/cicd/cloud-build/release-check.mjs +3 -1
- package/skills/cicd/cloud-debug/SKILL.md +1 -1
- package/skills/cicd/cloud-debug/release-check.mjs +3 -1
- package/skills/cicd/cloud-deploy/SKILL.md +1 -1
- package/skills/cicd/cloud-deploy/release-check.mjs +3 -1
- package/skills/cicd/docker/SKILL.md +1 -1
- package/skills/cicd/docker/release-check.mjs +3 -1
- package/skills/cicd/github-actions/SKILL.md +1 -1
- package/skills/cicd/github-actions/release-check.mjs +3 -1
- package/skills/cicd/github-flow/SKILL.md +1 -1
- package/skills/cicd/github-flow/release-check.mjs +3 -1
- package/skills/cicd/google-cloud/SKILL.md +1 -1
- package/skills/cicd/google-cloud/release-check.mjs +3 -1
- package/skills/cicd/mergify/SKILL.md +1 -1
- package/skills/cicd/mergify/release-check.mjs +3 -1
- package/skills/cicd/podman/SKILL.md +1 -1
- package/skills/cicd/podman/release-check.mjs +3 -1
- package/skills/content/article-review/SKILL.md +1 -1
- package/skills/content/article-review/release-check.mjs +3 -1
- package/skills/content/article-to-image/SKILL.md +1 -1
- package/skills/content/article-to-image/release-check.mjs +3 -1
- package/skills/content/flowchart-svg/SKILL.md +1 -1
- package/skills/content/flowchart-svg/release-check.mjs +3 -1
- package/skills/content/image-gen/SKILL.md +1 -1
- package/skills/content/image-gen/release-check.mjs +3 -1
- package/skills/content/mermaid/SKILL.md +1 -1
- package/skills/content/mermaid/release-check.mjs +3 -1
- package/skills/content/wechat-article-writer/SKILL.md +1 -1
- package/skills/content/wechat-article-writer/release-check.mjs +3 -1
- package/skills/content/wechat-publisher/SKILL.md +1 -1
- package/skills/content/wechat-publisher/release-check.mjs +3 -1
- package/skills/content/wechat-search/SKILL.md +1 -1
- package/skills/content/wechat-search/release-check.mjs +3 -1
- package/skills/content/xai-search/SKILL.md +88 -13
- package/skills/content/xai-search/release-check.mjs +3 -1
- package/skills/content/xai-search/scripts/xai_search.sh +125 -149
- package/skills/core/distill-writing/SKILL.md +1 -1
- package/skills/core/distill-writing/release-check.mjs +3 -1
- package/skills/core/doc-to-md/SKILL.md +1 -1
- package/skills/core/doc-to-md/release-check.mjs +3 -1
- package/skills/core/editorial-review/SKILL.md +1 -1
- package/skills/core/editorial-review/release-check.mjs +3 -1
- package/skills/core/house-style/SKILL.md +1 -1
- package/skills/core/house-style/release-check.mjs +3 -1
- package/skills/core/plain-language/SKILL.md +1 -1
- package/skills/core/plain-language/release-check.mjs +3 -1
- package/skills/core/polish-cn/SKILL.md +1 -1
- package/skills/core/polish-cn/release-check.mjs +3 -1
- package/skills/core/reg-parser/SKILL.md +1 -1
- package/skills/core/reg-parser/release-check.mjs +3 -1
- package/skills/core/terminology/SKILL.md +1 -1
- package/skills/core/terminology/release-check.mjs +3 -1
- package/skills/core/write-doc/SKILL.md +1 -1
- package/skills/core/write-doc/release-check.mjs +3 -1
- package/skills/engineering/better-review/SKILL.md +1 -1
- package/skills/engineering/better-review/release-check.mjs +3 -1
- package/skills/engineering/contributing/SKILL.md +1 -1
- package/skills/engineering/contributing/release-check.mjs +3 -1
- package/skills/engineering/e2e-test/SKILL.md +1 -1
- package/skills/engineering/e2e-test/release-check.mjs +3 -1
- package/skills/engineering/engineering-runtime/SKILL.md +1 -1
- package/skills/engineering/engineering-runtime/coherence/workflow.json +13 -13
- package/skills/engineering/engineering-runtime/release-check.mjs +3 -1
- package/skills/engineering/engineering-runtime/scripts/installation-resolver.mjs +191 -0
- package/skills/engineering/engineering-runtime/scripts/workflow-coherence.mjs +51 -10
- package/skills/engineering/ensure-coverage/SKILL.md +1 -1
- package/skills/engineering/ensure-coverage/release-check.mjs +3 -1
- package/skills/engineering/golden-path/SKILL.md +1 -1
- package/skills/engineering/golden-path/release-check.mjs +3 -1
- package/skills/engineering/harness-runtime/SKILL.md +1 -1
- package/skills/engineering/harness-runtime/release-check.mjs +3 -1
- package/skills/engineering/resolve-issues/SKILL.md +11 -20
- package/skills/engineering/resolve-issues/references/delivery-progress.md +63 -0
- package/skills/engineering/resolve-issues/references/expire.md +24 -11
- package/skills/engineering/resolve-issues/references/implementation.md +9 -1
- package/skills/engineering/resolve-issues/references/preflight.md +7 -0
- package/skills/engineering/resolve-issues/references/shared-modules.md +27 -0
- package/skills/engineering/resolve-issues/references/task-plan.md +12 -5
- package/skills/engineering/resolve-issues/release-check.mjs +3 -1
- package/skills/engineering/resolve-issues/scripts/active-installation.mjs +32 -0
- package/skills/engineering/resolve-issues/scripts/install-hooks.mjs +3 -0
- package/skills/engineering/resolve-issues/scripts/rehydrate.mjs +17 -1
- package/skills/engineering/resolve-release/SKILL.md +1 -1
- package/skills/engineering/resolve-release/release-check.mjs +3 -1
- package/skills/engineering/rush-issues/SKILL.md +5 -2
- package/skills/engineering/rush-issues/release-check.mjs +3 -1
- package/skills/engineering/rush-release/SKILL.md +1 -1
- package/skills/engineering/rush-release/release-check.mjs +3 -1
- package/skills/engineering/test-quality/SKILL.md +1 -1
- package/skills/engineering/test-quality/release-check.mjs +3 -1
- package/skills/risk-compliance/compliance-audit/SKILL.md +1 -1
- package/skills/risk-compliance/compliance-audit/release-check.mjs +3 -1
- package/skills/risk-compliance/contract-compare/SKILL.md +1 -1
- package/skills/risk-compliance/contract-compare/release-check.mjs +3 -1
- package/skills/risk-compliance/contract-review/SKILL.md +1 -1
- package/skills/risk-compliance/contract-review/release-check.mjs +3 -1
- package/skills/risk-compliance/doc-authenticity/SKILL.md +1 -1
- package/skills/risk-compliance/doc-authenticity/release-check.mjs +3 -1
- package/skills/risk-compliance/fraud-analysis/SKILL.md +1 -1
- package/skills/risk-compliance/fraud-analysis/release-check.mjs +3 -1
- package/skills/risk-compliance/payment-analysis/SKILL.md +1 -1
- package/skills/risk-compliance/payment-analysis/release-check.mjs +3 -1
- package/skills/risk-compliance/similar-domain/SKILL.md +1 -1
- package/skills/risk-compliance/similar-domain/release-check.mjs +3 -1
- package/skills/risk-compliance/tld-detection/SKILL.md +1 -1
- package/skills/risk-compliance/tld-detection/release-check.mjs +3 -1
- package/skills/app-dev/android-foundation/scripts/device-run.test.mjs +0 -172
- package/skills/app-dev/data-catalog/scripts/data-catalog.test.mjs +0 -36
- package/skills/app-dev/data-quality/scripts/data-quality.test.mjs +0 -12
- package/skills/cicd/github-actions/scripts/ci-run-audit.test.mjs +0 -637
- package/skills/cicd/github-flow/scripts/flow.test.mjs +0 -114
- package/skills/cicd/github-flow/scripts/persist-conventions.test.mjs +0 -108
- package/skills/cicd/mergify/scripts/audit.test.mjs +0 -201
- package/skills/cicd/mergify/scripts/entrypoints.test.mjs +0 -106
- package/skills/cicd/mergify/scripts/pr-620-mergify-comments.fixture.json +0 -30
- package/skills/cicd/mergify/scripts/stack-push.test.mjs +0 -233
- package/skills/cicd/mergify/scripts/watch-pr-delivery.test.mjs +0 -1826
- package/skills/content/image-gen/scripts/credentials.test.mjs +0 -212
- package/skills/content/image-gen/scripts/options.test.mjs +0 -245
- package/skills/content/xai-search/tests/smoke_test.sh +0 -36
- package/skills/core/polish-cn/scripts/polish-cn.test.mjs +0 -244
- package/skills/core/reg-parser/scripts/reg-parser.test.mjs +0 -165
- package/skills/engineering/better-review/scripts/pr-context.test.mjs +0 -168
- package/skills/engineering/better-review/scripts/rereview-scope.test.mjs +0 -587
- package/skills/engineering/better-review/scripts/scan-diff.test.mjs +0 -414
- package/skills/engineering/better-review/scripts/vendor-sync.test.mjs +0 -96
- package/skills/engineering/contributing/scripts/persist-conventions.test.mjs +0 -118
- package/skills/engineering/e2e-test/scripts/presentation-checks.test.mjs +0 -106
- package/skills/engineering/e2e-test/scripts/presentation-perceivability.test.mjs +0 -117
- package/skills/engineering/e2e-test/scripts/presentation-reachability.test.mjs +0 -69
- package/skills/engineering/e2e-test/scripts/presentation-render-health.test.mjs +0 -98
- package/skills/engineering/e2e-test/scripts/presentation-sweep.test.mjs +0 -71
- package/skills/engineering/e2e-test/scripts/presentation-temporal.test.mjs +0 -59
- package/skills/engineering/e2e-test/scripts/project-route-manifest.test.mjs +0 -76
- package/skills/engineering/engineering-runtime/engineering-runtime.test.mjs +0 -68
- package/skills/engineering/engineering-runtime/scripts/invocation-policy.test.mjs +0 -95
- package/skills/engineering/engineering-runtime/scripts/main-module.test.mjs +0 -288
- package/skills/engineering/engineering-runtime/scripts/required-check-plan.test.mjs +0 -96
- package/skills/engineering/ensure-coverage/scripts/adapters/nextjs-inventory.test.mjs +0 -96
- package/skills/engineering/ensure-coverage/scripts/check-quarantine-expiry.test.mjs +0 -47
- package/skills/engineering/ensure-coverage/scripts/ci-audit.test.mjs +0 -86
- package/skills/engineering/ensure-coverage/scripts/coverage-ledger.test.mjs +0 -447
- package/skills/engineering/ensure-coverage/scripts/design-parity.test.mjs +0 -552
- package/skills/engineering/ensure-coverage/scripts/lint-tests.test.mjs +0 -289
- package/skills/engineering/ensure-coverage/scripts/mock-policy-config.test.mjs +0 -119
- package/skills/engineering/golden-path/scripts/golden-path.test.mjs +0 -1457
- package/skills/engineering/harness-runtime/discover-models.test.mjs +0 -363
- package/skills/engineering/harness-runtime/harness-runtime.test.mjs +0 -967
- package/skills/engineering/harness-runtime/model-catalog-seed.test.mjs +0 -829
- package/skills/engineering/harness-runtime/model-catalog.test.mjs +0 -366
- package/skills/engineering/resolve-issues/scripts/cleanup-runs.test.mjs +0 -280
- package/skills/engineering/resolve-issues/scripts/dropbox.test.mjs +0 -346
- package/skills/engineering/resolve-issues/scripts/findings-reuse.test.mjs +0 -88
- package/skills/engineering/resolve-issues/scripts/github-reviews.test.mjs +0 -264
- package/skills/engineering/resolve-issues/scripts/install-hooks.test.mjs +0 -79
- package/skills/engineering/resolve-issues/scripts/issue-tree.test.mjs +0 -107
- package/skills/engineering/resolve-issues/scripts/manual-invocation.test.mjs +0 -14
- package/skills/engineering/resolve-issues/scripts/next-actions-capacity.test.mjs +0 -149
- package/skills/engineering/resolve-issues/scripts/next-actions.test.mjs +0 -915
- package/skills/engineering/resolve-issues/scripts/plan-sync.test.mjs +0 -156
- package/skills/engineering/resolve-issues/scripts/preflight-models.test.mjs +0 -448
- package/skills/engineering/resolve-issues/scripts/ready-check.test.mjs +0 -217
- package/skills/engineering/resolve-issues/scripts/rehydrate.test.mjs +0 -91
- package/skills/engineering/resolve-issues/scripts/review-verdict.test.mjs +0 -1060
- package/skills/engineering/resolve-issues/scripts/size-check.test.mjs +0 -458
- package/skills/engineering/resolve-release/scripts/apply.test.mjs +0 -99
- package/skills/engineering/resolve-release/scripts/dark-flags.test.mjs +0 -100
- package/skills/engineering/resolve-release/scripts/flow.test.mjs +0 -340
- package/skills/engineering/resolve-release/scripts/green-head.test.mjs +0 -101
- package/skills/engineering/resolve-release/scripts/npm-version-absence.test.mjs +0 -426
- package/skills/engineering/resolve-release/scripts/plan-npm.test.mjs +0 -659
- package/skills/engineering/resolve-release/scripts/plan-toml-boundary.test.mjs +0 -317
- package/skills/engineering/resolve-release/scripts/plan-uv.test.mjs +0 -291
- package/skills/engineering/resolve-release/scripts/plan.test.mjs +0 -428
- package/skills/engineering/test-quality/scripts/lint-tests.test.mjs +0 -591
- package/skills/engineering/test-quality/scripts/mock-policy-config.test.mjs +0 -119
- package/skills/engineering/test-quality/scripts/persist-conventions.test.mjs +0 -104
- package/skills/risk-compliance/compliance-audit/scripts/compliance-audit.test.mjs +0 -14
- package/skills/risk-compliance/doc-authenticity/manual-invocation.test.mjs +0 -12
- package/skills/risk-compliance/doc-authenticity/scripts/validate_verdict.test.mjs +0 -212
- package/skills/risk-compliance/tld-detection/scripts/detect_ladders.test.mjs +0 -14
- package/skills/risk-compliance/tld-detection/scripts/detect_streams.test.mjs +0 -14
- package/skills/risk-compliance/tld-detection/tests/test_detect_ladders.py +0 -134
- package/skills/risk-compliance/tld-detection/tests/test_detect_streams.py +0 -520
package/README.md
CHANGED
|
@@ -23,6 +23,28 @@ using the copies. Run `/reload` after the first start.
|
|
|
23
23
|
|
|
24
24
|
Each package also publishes on its own; install either this bundle or the packages, not both.
|
|
25
25
|
|
|
26
|
+
## Native Codex plugin
|
|
27
|
+
|
|
28
|
+
This bundle also carries a generated recursive compatibility manifest. The shared Codex
|
|
29
|
+
catalog remains inactive until publication and native certification pass. Codex loads skills
|
|
30
|
+
only; it does not run the Pi extension or selection command and installs no global hooks.
|
|
31
|
+
|
|
32
|
+
Select the invoked bundle explicitly. Its package.json nativeCodex field records the resource
|
|
33
|
+
metadata path, SHA-256 and release identity. Save those pins and the absolute root in the run;
|
|
34
|
+
resolve canonical dependencies with engineering-runtime/scripts/installation-resolver.mjs,
|
|
35
|
+
and pass verified absolute paths to workers. Keep observed Codex namespaced identities separate
|
|
36
|
+
from canonical names. Never search other caches, fall back to a shared namesake, or install
|
|
37
|
+
missing dependencies implicitly. Shared Pi and Claude copies are preserved.
|
|
38
|
+
|
|
39
|
+
Engineering capture: node <active-resolve-issues>/scripts/active-installation.mjs capture.
|
|
40
|
+
Save its descriptor as run-level installation in task-plan.json. After resume run the selected
|
|
41
|
+
resolve-issues/scripts/rehydrate.mjs --cwd <project> and read its verified instruction paths.
|
|
42
|
+
Standalone source and flat installations keep their existing behavior.
|
|
43
|
+
|
|
44
|
+
Codex CLI 0.164.0 local packed discovery is tested. Model-driven worker spawning and native
|
|
45
|
+
compaction/resume still need an isolated run with run-owned credentials before launch.
|
|
46
|
+
See https://github.com/1aboveio/ai/blob/main/docs/native-codex.md for prerequisites and limits.
|
|
47
|
+
|
|
26
48
|
## Packages
|
|
27
49
|
|
|
28
50
|
| Package | Also published as | Skills |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@1aboveio/skills",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.9",
|
|
4
4
|
"description": "Every 1aboveio skill package in one: install once, then choose which packages Pi loads with npx @1aboveio/skills select.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -22,8 +22,15 @@
|
|
|
22
22
|
"skills",
|
|
23
23
|
"bin",
|
|
24
24
|
"extensions",
|
|
25
|
+
".codex-plugin",
|
|
25
26
|
"README.md"
|
|
26
27
|
],
|
|
28
|
+
"nativeCodex": {
|
|
29
|
+
"schemaVersion": 1,
|
|
30
|
+
"metadataPath": ".codex-plugin/resources.json",
|
|
31
|
+
"metadataDigest": "a136e6a3363e03951e15d3a9e47dbac22e8c01f98efb18cadb317ffb270901b8",
|
|
32
|
+
"releaseIdentity": "9954a993488d48d15d61488ba06329a6dbc771bcf14c552a3463d68dc31fab26"
|
|
33
|
+
},
|
|
27
34
|
"pi": {
|
|
28
35
|
"skills": [
|
|
29
36
|
"./skills"
|
|
@@ -251,7 +258,7 @@
|
|
|
251
258
|
]
|
|
252
259
|
}
|
|
253
260
|
],
|
|
254
|
-
"digest": "
|
|
261
|
+
"digest": "1fb2babf7dc0e9afde23727b28f8609f67c96758ae2835747e81a8d7139afae1"
|
|
255
262
|
},
|
|
256
263
|
"publishConfig": {
|
|
257
264
|
"registry": "https://registry.npmjs.org/",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: airflow
|
|
3
3
|
description: Airflow DAG architecture and conventions. Use when designing, writing, reviewing, testing, or debugging Airflow DAGs and tasks, including TaskGroups, data intervals, timezone-aware date parameters, CLI validation, environment-based scheduling, and pytest integrity tests.
|
|
4
4
|
user-invocable: true
|
|
5
|
-
release-version: 0.
|
|
5
|
+
release-version: 0.44.0
|
|
6
6
|
---
|
|
7
7
|
**Updates:** Once/session run `node <skill-base-dir>/release-check.mjs`.
|
|
8
8
|
# Airflow DAG Development Patterns
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { spawnSync } from 'node:child_process';
|
|
3
3
|
import { mkdirSync, readFileSync, writeFileSync } from 'node:fs';
|
|
4
4
|
import { homedir } from 'node:os';
|
|
5
|
-
import { dirname, join } from 'node:path';
|
|
5
|
+
import { dirname, join, resolve } from 'node:path';
|
|
6
6
|
import { fileURLToPath } from 'node:url';
|
|
7
7
|
|
|
8
8
|
const DAY_MS = 24 * 60 * 60 * 1000;
|
|
@@ -46,6 +46,8 @@ function writeCache(path, value) {
|
|
|
46
46
|
|
|
47
47
|
function main(now = Date.now()) {
|
|
48
48
|
if (process.env.ONEABOVEIO_NO_UPDATE_CHECK) return;
|
|
49
|
+
const bundle = readJson(join(resolve(here, '../../..'), 'package.json'));
|
|
50
|
+
if (bundle.name === '@1aboveio/skills' && bundle.nativeCodex?.schemaVersion === 1) return;
|
|
49
51
|
const skill = readFileSync(join(here, 'SKILL.md'), 'utf8');
|
|
50
52
|
const name = frontmatterValue(skill, 'name');
|
|
51
53
|
const localVersion = stableVersion(frontmatterValue(skill, 'release-version'));
|
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: android-foundation
|
|
3
|
-
description: "Prove
|
|
4
|
-
release-version: 0.
|
|
3
|
+
description: "Prove and debug Expo / React Native apps on an owned Android emulator. Use for stuck Android debugging, post-deploy startup or rendering failures, Metro answering while the app does not render, UiAutomator failures, missing controls, ADB drops, harness-test failures, APK builds, fresh SDK/NDK/JDK workspaces, and native journey validation. Before fixing and rerunning or redispatching a failed Android CI job, reproduce its failing checkpoint off CI: a rerun is not a debugger. Diagnose existing setups without rebuilding the whole environment. NOT for workflow YAML, CI speed or runner design (github-actions), browser tests (e2e-test), iOS (ios-foundation), plain Jest component tests, or signing and store release."
|
|
4
|
+
release-version: 0.44.0
|
|
5
5
|
---
|
|
6
6
|
**Updates:** Once/session run `node <skill-base-dir>/release-check.mjs`.
|
|
7
7
|
# Android foundation
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
from the template; do not write a separate release runbook.
|
|
9
|
+
Prove or debug a native Expo / React Native device journey using the repo's existing
|
|
10
|
+
build scripts, native project, harness and wrapper. Use `github-actions` for CI YAML
|
|
11
|
+
and runner integration. The CI template is a starting point; preserve existing workflows.
|
|
13
12
|
|
|
14
13
|
Pick the mode first:
|
|
15
14
|
|
|
16
|
-
- **
|
|
17
|
-
|
|
15
|
+
- **Diagnosis:** an existing workspace or CI run fails or stalls. Follow
|
|
16
|
+
[Diagnosis](#diagnosis) first; a harness change does not automatically require a cold
|
|
17
|
+
setup. Re-run only the setup stages whose assumptions changed.
|
|
18
|
+
- **Setup proof:** a new workspace or CI job, or a toolchain, dependency or native
|
|
19
|
+
change that invalidates setup. Run every stage and write the
|
|
18
20
|
[evidence record](#evidence-record).
|
|
19
21
|
- **Feature work:** proving a product change on the emulator in a workspace already set
|
|
20
22
|
up. Follow [Feature work](#feature-work) and report only the journey result.
|
|
@@ -27,18 +29,24 @@ Pick the mode first:
|
|
|
27
29
|
| Stages 6–8 in one command | [scripts/device-run.sh](scripts/device-run.sh) |
|
|
28
30
|
| Adding the Android job to CI | [references/ci.md](references/ci.md), template [assets/android-ci-job.yml](assets/android-ci-job.yml) |
|
|
29
31
|
| Proving a product change on the emulator | [Feature work](#feature-work) |
|
|
30
|
-
| A stage failed | [
|
|
32
|
+
| A stage failed or a worker appears stuck | [Diagnosis](#diagnosis), then [references/diagnosis.md](references/diagnosis.md) and [Triage](#triage) |
|
|
31
33
|
| Writing up setup proof | [Evidence record](#evidence-record) |
|
|
32
34
|
|
|
33
35
|
## Rules
|
|
34
36
|
|
|
35
|
-
-
|
|
36
|
-
|
|
37
|
+
- Use an isolated checkout. For new work, branch from `origin/main`; for diagnosis,
|
|
38
|
+
pin the failed source SHA or the reviewed correction. Confirm the checkout actually
|
|
39
|
+
contains the failing code: the repo root may lag active workspaces. Never mutate a
|
|
40
|
+
peer's checkout or symlink its writable `node_modules`.
|
|
37
41
|
- Tool shells keep no variables, functions or traps between calls. Write the environment
|
|
38
|
-
to `.cache/android-env.sh` once and source it at the start of every command.
|
|
39
|
-
|
|
40
|
-
-
|
|
41
|
-
|
|
42
|
+
to `.cache/android-env.sh` once and source it at the start of every command. Use the
|
|
43
|
+
repo's existing owned-resource launcher. For a new local setup without one, use
|
|
44
|
+
`scripts/device-run.sh` for stages 6–8 in one command. Do not wrap an existing owner
|
|
45
|
+
with a second emulator/database lifecycle.
|
|
46
|
+
- Keep local writable caches private under `.cache/`: Gradle home, Android user/AVD
|
|
47
|
+
homes, temporary files, npm, node-gyp and pnpm. In CI, an already isolated runner slot
|
|
48
|
+
may provide those paths; verify its ownership contract rather than layering another
|
|
49
|
+
cache system on top. Never share writable state across concurrent owners.
|
|
42
50
|
- Read toolchain versions from the repo: the root `packageManager` and `engines`, the
|
|
43
51
|
native Gradle config, and the CI preflight. The repo is the source of truth, not this skill.
|
|
44
52
|
- Check that every required SDK component (platform, build-tools, NDK, CMake,
|
|
@@ -51,8 +59,10 @@ Pick the mode first:
|
|
|
51
59
|
- Build every configured ABI for setup proof and release acceptance. An x86_64-only CI
|
|
52
60
|
APK only proves the emulator ABI. For feature work, the emulator ABI is enough unless the
|
|
53
61
|
change touches native code or ABI configuration.
|
|
54
|
-
-
|
|
55
|
-
a
|
|
62
|
+
- Determine how the selected build loads code and assets. A typical debug build needs
|
|
63
|
+
Metro; a release build normally embeds its bundle. Do not introduce Metro or debug
|
|
64
|
+
preferences into a release failure without evidence that the build uses them.
|
|
65
|
+
A successful build does not prove execution on a device.
|
|
56
66
|
|
|
57
67
|
## Stages
|
|
58
68
|
|
|
@@ -106,21 +116,64 @@ Run them in this order. Stop at the first failure and triage it.
|
|
|
106
116
|
CID file, and the named database. Signal the PID with `TERM`, wait up to 10 seconds, then
|
|
107
117
|
`KILL`. Then `wait` for it and confirm nothing is left. Count wait status 0 or 143 (ended
|
|
108
118
|
by your `TERM`) as a clean stop; count a needed `KILL` or any other status as a failure.
|
|
109
|
-
- Never use `
|
|
110
|
-
|
|
111
|
-
|
|
119
|
+
- Never use broad `pkill`, `docker system prune` or a shared `adb kill-server` for cleanup.
|
|
120
|
+
Use the live child's process owner, not an ADB serial that may be reused. A numeric
|
|
121
|
+
PID can also be reused after exit; it is not durable ownership evidence.
|
|
112
122
|
- Give every startup, readiness and cleanup command a 30-second limit that kills the
|
|
113
123
|
command's whole process group. Treat exit 124 (timeout) as a terminal failure, not as
|
|
114
124
|
"not ready yet".
|
|
115
125
|
- Preserve the stage's original non-zero exit status even when cleanup succeeds. Print
|
|
116
126
|
`original_stage_exit=<n> cleanup_exit=<n>`.
|
|
117
|
-
- After
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
127
|
+
- After SIGKILL or a host crash, verify recorded resources before recovery: process
|
|
128
|
+
start identity, command/run scope and boot identity where available, or container ID
|
|
129
|
+
and ownership labels. Never signal a numeric PID solely because an old record names
|
|
130
|
+
it. If ownership cannot be verified, leave it alone and report the gap. Keep logs.
|
|
131
|
+
- For the local setup flow, point the database URL only at its disposable loopback
|
|
132
|
+
container. An existing isolated remote test flow must use its own disposable data and
|
|
133
|
+
ownership checks. Never use development, production or another worker's database for
|
|
134
|
+
fixture writes or cleanup. A public render-only smoke needs no database.
|
|
121
135
|
- Expo may rewrite `android/tsconfig.json` or delete `android/expo-env.d.ts` while it runs.
|
|
122
136
|
Inspect those changes and restore them before you commit.
|
|
123
137
|
|
|
138
|
+
## Delivery focus
|
|
139
|
+
|
|
140
|
+
Read [references/delivery-focus.md](references/delivery-focus.md) before starting or
|
|
141
|
+
continuing work. Keep an existing acceptance checkpoint, reuse available evidence,
|
|
142
|
+
justify new infrastructure and carry failure history across workers. Required CI and
|
|
143
|
+
the full acceptance criteria still apply; report delivered behavior before activity.
|
|
144
|
+
|
|
145
|
+
## Diagnosis
|
|
146
|
+
|
|
147
|
+
Follow the procedure below and [references/diagnosis.md](references/diagnosis.md).
|
|
148
|
+
`diagnosing-bugs`, when available, can help with deeper hypothesis testing; it is not
|
|
149
|
+
required to use this skill.
|
|
150
|
+
|
|
151
|
+
1. Record the failed SHA, actual checkout, build variant, device type and retained
|
|
152
|
+
evidence. Locate the earliest failing stage: build/install → launch → load code/assets
|
|
153
|
+
→ initialize → render → interact. Distinguish host/CI, harness, transport and product
|
|
154
|
+
failures; an absent screen alone does not identify which one failed.
|
|
155
|
+
2. Choose the smallest test that can expose the suspected defect: a host test for logic,
|
|
156
|
+
real producer/consumer composition for a contract, or a device test for native/runtime
|
|
157
|
+
behavior. Collect evidence appropriate to that stage. A service probe proves only the
|
|
158
|
+
probe, not that the application used the same path.
|
|
159
|
+
3. State competing explanations and a distinguishing observation. Change one variable.
|
|
160
|
+
For reversible defects, a failure → correction → failure comparison can strengthen
|
|
161
|
+
the finding; it is optional, not a gate. For intermittent failures, use a bounded,
|
|
162
|
+
repeatable trigger and compare failure rates. Do not replay Authentication or financial
|
|
163
|
+
actions merely to obtain a comparison.
|
|
164
|
+
4. Keep the first exception and its evidence separate from cleanup errors. Bound the
|
|
165
|
+
full command and each subprocess wait, allowing the resource owner time to clean up.
|
|
166
|
+
A live worker or an outstanding tool call is not evidence of progress.
|
|
167
|
+
5. Verify the fix at the failing checkpoint, then run the applicable acceptance once.
|
|
168
|
+
Report local reproduction, source CI and post-deploy acceptance separately. A local
|
|
169
|
+
result on another API/ABI or a copied APK is not proof of the original CI artifact.
|
|
170
|
+
|
|
171
|
+
Continue when the next attempt tests a new prediction, collects a missing observation,
|
|
172
|
+
reduces the reproduction, or adds a justified sample for an intermittent failure. Name
|
|
173
|
+
that purpose and bound its cost. Changing workers or repeating an unchanged run without
|
|
174
|
+
such a purpose is not progress. When no available experiment distinguishes the remaining
|
|
175
|
+
explanations, report the missing evidence or access instead of restarting the campaign.
|
|
176
|
+
|
|
124
177
|
## Triage
|
|
125
178
|
|
|
126
179
|
Name the earliest stage that failed. In CI, that is the first failed step. If the same
|
|
@@ -135,6 +188,7 @@ the product.
|
|
|
135
188
|
| Gradle network | Maven download or TLS-handshake errors on a cold build: fix routing, not code |
|
|
136
189
|
| Emulator boot / ADB | `sys.boot_completed` never reaches 1, device offline, exit 124 |
|
|
137
190
|
| Device to Metro | red box, "unable to load script", missing `adb reverse` mapping |
|
|
191
|
+
| Bridge passes, debug app fails to load | possible app/probe endpoint mismatch; inspect the actual request before choosing a cause ([React Native example](references/diagnosis.md#example-react-native-debug-app-uses-another-metro)) |
|
|
138
192
|
| Device to Metro, mid-journey | a screen's first Metro asset fails (`Unable to download asset from url: http://127.0.0.1:8081/assets/…`) while API calls still succeed |
|
|
139
193
|
| Backend / Login | backend log errors, verification code not found in the database |
|
|
140
194
|
| Backend tool, CI only | a Backend-backed step gets a 5xx in CI only; the log names a missing program (`Browser was not found at the configured executablePath`) |
|
|
@@ -156,16 +210,20 @@ build is reliable.
|
|
|
156
210
|
|
|
157
211
|
- Reuse the workspace's caches, venv and AVD configuration. Rerun a setup stage only when
|
|
158
212
|
the change touches what it proves (toolchain, dependencies, native code, harness).
|
|
159
|
-
- Build the emulator ABI and run
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
213
|
+
- Build the emulator ABI when its inputs changed and run the repo's owned journey
|
|
214
|
+
command once per candidate HEAD. A reused APK needs the source/configuration checks
|
|
215
|
+
the repo requires; record its hash and any provenance gap during diagnosis.
|
|
216
|
+
- After a failed journey, local or a CI dispatch, enter Diagnosis mode and reproduce the
|
|
217
|
+
failing checkpoint off CI before running it again. A fake UI can reproduce a harness
|
|
218
|
+
navigation/scrolling bug; it cannot prove that the app loaded a bundle or rendered.
|
|
219
|
+
Show the fix passes at the appropriate seam, then run the journey once to confirm.
|
|
220
|
+
Never send a guessed fix to CI to see whether it passes. Use the Diagnosis continuation
|
|
221
|
+
rule for unreproduced or intermittent failures; report uncertainty until evidence
|
|
222
|
+
supports the cause.
|
|
223
|
+
- For a passing feature run, report the source SHA, journey command, `PASS` markers and
|
|
224
|
+
cleanup exit. For a failure, also name the earliest failing checkpoint, link retained
|
|
225
|
+
evidence and state what remains unproved; use the diagnosis report instead of hiding
|
|
226
|
+
the failed attempts.
|
|
169
227
|
- Integrated device acceptance (all ABIs, tablet, TalkBack, physical devices, a release
|
|
170
228
|
device campaign) runs at the release or campaign gate the spec or repo assigns it. Do
|
|
171
229
|
not recreate it per feature. Record it once, as pending, in its owning issue, never as
|
|
@@ -107,6 +107,12 @@ jobs:
|
|
|
107
107
|
' "$props" "$mirror"
|
|
108
108
|
grep '^distributionUrl=' "$props"
|
|
109
109
|
|
|
110
|
+
# Prerequisite: runner slots own their writable caches and Android homes.
|
|
111
|
+
# Otherwise export job-private paths to GITHUB_ENV before install so every
|
|
112
|
+
# subsequent step (including the emulator action) inherits the same paths.
|
|
113
|
+
- name: Verify writable runner isolation
|
|
114
|
+
run: <runner-cache-and-home-isolation-preflight-command>
|
|
115
|
+
|
|
110
116
|
- name: Install dependencies
|
|
111
117
|
timeout-minutes: 12
|
|
112
118
|
run: pnpm install --frozen-lockfile
|
|
@@ -116,6 +122,7 @@ jobs:
|
|
|
116
122
|
pnpm --filter <android-workspace-package> test
|
|
117
123
|
pnpm --filter <android-workspace-package> typecheck
|
|
118
124
|
|
|
125
|
+
# Optional: only after measurement, and never for persistence/recovery tests.
|
|
119
126
|
- name: Relax durability on the disposable Postgres
|
|
120
127
|
env:
|
|
121
128
|
PG_CONTAINER: ${{ job.services.postgres.id }}
|
|
@@ -138,9 +145,7 @@ jobs:
|
|
|
138
145
|
timeout-minutes: 30
|
|
139
146
|
env:
|
|
140
147
|
EXPO_PUBLIC_API_URL: https://app.invalid
|
|
141
|
-
ANDROID_USER_HOME: ${{ github.workspace }}/.cache/android-user
|
|
142
148
|
run: |
|
|
143
|
-
mkdir -p "$ANDROID_USER_HOME"
|
|
144
149
|
cpus="$(nproc)"
|
|
145
150
|
if [ -r /sys/fs/cgroup/cpu.max ]; then
|
|
146
151
|
read -r quota period < /sys/fs/cgroup/cpu.max
|
|
@@ -148,7 +153,7 @@ jobs:
|
|
|
148
153
|
fi
|
|
149
154
|
echo "gradle max-workers=$cpus (nproc=$(nproc))"
|
|
150
155
|
<android-project>/gradlew --project-dir <android-project> :app:assembleDebug --no-daemon \
|
|
151
|
-
-PreactNativeArchitectures=x86_64 --max-workers="$cpus"
|
|
156
|
+
-PreactNativeArchitectures=x86_64 -Pandroid.builder.sdkDownload=false --max-workers="$cpus"
|
|
152
157
|
|
|
153
158
|
- uses: actions/setup-python@v5
|
|
154
159
|
with:
|
|
@@ -172,8 +177,9 @@ jobs:
|
|
|
172
177
|
- name: Device journey
|
|
173
178
|
uses: reactivecircus/android-emulator-runner@a421e43855164a8197daf9d8d40fe71c6996bb0d # v2.38.0
|
|
174
179
|
env:
|
|
175
|
-
|
|
176
|
-
|
|
180
|
+
# Replace these keys too; the harness owns their names and database prefix.
|
|
181
|
+
<harness-admin-url-variable>: postgresql://postgres:postgres@127.0.0.1:${{ job.services.postgres.ports['5432'] }}/postgres
|
|
182
|
+
<harness-db-name-variable>: <ci-db-name>
|
|
177
183
|
with:
|
|
178
184
|
api-level: <emulator-api>
|
|
179
185
|
arch: x86_64
|
|
@@ -182,8 +188,8 @@ jobs:
|
|
|
182
188
|
enable-hw-keyboard: true
|
|
183
189
|
emulator-port: ${{ env.ANDROID_EMULATOR_PORT }}
|
|
184
190
|
cores: 4
|
|
185
|
-
#
|
|
186
|
-
#
|
|
191
|
+
# Default for this sample. The documented guest-memory ADB failure occurred
|
|
192
|
+
# on specific images; a transport drop alone does not establish that cause.
|
|
187
193
|
ram-size: 4096M
|
|
188
194
|
disable-linux-hw-accel: false
|
|
189
195
|
script: bash <path/to/foundation-journey-wrapper.sh>
|
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
# Android CI
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
fill every
|
|
6
|
-
`
|
|
7
|
-
|
|
3
|
+
Integrate the Android build and journey into the repo's existing CI. For a new
|
|
4
|
+
`changes` → area jobs → `gate` design, adapt
|
|
5
|
+
[assets/android-ci-job.yml](../assets/android-ci-job.yml) and fill every placeholder.
|
|
6
|
+
Use `github-actions` for workflow structure, required checks, runner labels, pinning and
|
|
7
|
+
hardening. Do not replace existing required checks or workflows just to match this example.
|
|
8
8
|
|
|
9
9
|
## Wire it in
|
|
10
10
|
|
|
11
|
+
The following is an example for a new gate-based workflow; retain an established repo's
|
|
12
|
+
trigger and required-check contract unless changing it is part of the task.
|
|
13
|
+
|
|
11
14
|
1. Add an `android` filter to the `changes` job: the app workspace, the native project,
|
|
12
15
|
the backend code the journey drives, the device harness and journey scripts, the
|
|
13
16
|
lockfile, and `ci.yml`. Leave docs out.
|
|
@@ -34,13 +37,18 @@ specific.
|
|
|
34
37
|
`$GITHUB_ENV` and start the ADB server on its own port.
|
|
35
38
|
- Size Gradle from the cgroup CPU quota (`/sys/fs/cgroup/cpu.max`), not `nproc`. `nproc`
|
|
36
39
|
reports every host core and thrashes the native build.
|
|
40
|
+
- Verify each runner slot owns its writable Gradle, Android user/AVD, temporary, npm,
|
|
41
|
+
node-gyp and pnpm state. If the runner image already isolates these, keep that contract.
|
|
42
|
+
Otherwise configure private job paths before install and export them to every later
|
|
43
|
+
step, including the emulator. A step-local Android home is insufficient.
|
|
37
44
|
- Route the Gradle wrapper distribution and Maven repositories through the runner's
|
|
38
45
|
dependency proxy when it has one. Fail when the proxy variable is missing; never fall
|
|
39
46
|
back to direct downloads.
|
|
40
47
|
|
|
41
48
|
## Build
|
|
42
49
|
|
|
43
|
-
- Build `x86_64` only (`-PreactNativeArchitectures=x86_64`), with `--no-daemon
|
|
50
|
+
- Build `x86_64` only (`-PreactNativeArchitectures=x86_64`), with `--no-daemon` and
|
|
51
|
+
`-Pandroid.builder.sdkDownload=false`. Report
|
|
44
52
|
this APK as emulator evidence only. The all-ABI build stays a local or release step.
|
|
45
53
|
- Bundle the JavaScript with `expo export --platform android` before the native build so
|
|
46
54
|
bundling errors fail fast.
|
|
@@ -49,8 +57,10 @@ specific.
|
|
|
49
57
|
|
|
50
58
|
## Database and journey
|
|
51
59
|
|
|
52
|
-
- Run PostgreSQL
|
|
53
|
-
|
|
60
|
+
- Run PostgreSQL only when the journey needs it, as an isolated service with a random
|
|
61
|
+
host port and health check. Disable durability only when measured and when the tests
|
|
62
|
+
do not exercise recovery/persistence semantics. Discover the harness's database variable
|
|
63
|
+
names and required database prefix; map the service explicitly without shared fallbacks.
|
|
54
64
|
- Run the native auth/integration tests against that service before the device journey.
|
|
55
65
|
- Unit-test the device orchestration scripts (journey wrapper, slot allocator, code
|
|
56
66
|
lookup) before booting the emulator.
|
|
@@ -75,11 +85,11 @@ specific.
|
|
|
75
85
|
and whether it scrolls, and the runner's free disk at preflight. A repo that uploads no
|
|
76
86
|
capture needs these in the log.
|
|
77
87
|
- Upload the APK with `if-no-files-found: error`.
|
|
78
|
-
- Treat one green run as one run.
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
with
|
|
82
|
-
|
|
88
|
+
- Treat one green run as one run. Investigate intermittent device failures rather than
|
|
89
|
+
retrying without a purpose. An ADB drop may match the documented guest-memory issue;
|
|
90
|
+
confirm its transport/kernel evidence before choosing that fix. `RemoteDisconnected`
|
|
91
|
+
with transport still up may match a server restart; verify server/process evidence.
|
|
92
|
+
These are hypotheses, not universal diagnoses; see [gotchas](gotchas.md).
|
|
83
93
|
|
|
84
94
|
## Traps
|
|
85
95
|
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# Delivery focus
|
|
2
|
+
|
|
3
|
+
Name one immediate checkpoint from the task's existing acceptance criteria: for example,
|
|
4
|
+
open the app and render the expected screen. Keep that target visible while diagnosing;
|
|
5
|
+
passing setup or adding helper code is not a substitute. Each independent work unit has
|
|
6
|
+
its own checkpoint, so this does not serialize unrelated work.
|
|
7
|
+
|
|
8
|
+
- Preserve a known-working source/artifact and relevant environment as a comparison when
|
|
9
|
+
one already exists. Do not start a baseline campaign or count that old artifact as proof
|
|
10
|
+
of the candidate. Reuse caches and valid results under the repo's ownership rules.
|
|
11
|
+
- Run the smallest test that reaches the failing behavior. After it supports the fix,
|
|
12
|
+
run affected acceptance and required CI; do not repeatedly rebuild the full campaign
|
|
13
|
+
to discover the next local defect.
|
|
14
|
+
- Before adding a service, transport or test abstraction, state which existing criterion
|
|
15
|
+
needs it, why the current path cannot answer the question and the smallest alternative.
|
|
16
|
+
Make routine choices within authorization; preserve shared-resource and acceptance
|
|
17
|
+
approval boundaries. Do not expand infrastructure merely because a screen failed.
|
|
18
|
+
- Every continuation states the current checkpoint, new evidence or concrete blocker,
|
|
19
|
+
and the next distinguishing test. Carry prior failures across worker changes. If
|
|
20
|
+
successive attempts leave the same checkpoint unproved, reassess and reduce the case
|
|
21
|
+
or change the approach before assigning another similar attempt. Diagnostics can guide
|
|
22
|
+
that decision but do not count as delivered functionality or reset coordinator limits.
|
|
23
|
+
- Report behavior delivered and criteria still unproved first. Reuse existing results for
|
|
24
|
+
time to reproduce, time to verified fix and full CI runs when available; never invent
|
|
25
|
+
those measurements or create a reporting project to obtain them.
|
|
26
|
+
|
|
27
|
+
When a coordinator owns the run, keep this context in its existing plan note and worker
|
|
28
|
+
result. Follow its retry/replan rules; add no separate ledger, check or acceptance gate.
|
|
29
|
+
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
# Diagnose an existing Android failure
|
|
2
|
+
|
|
3
|
+
Use the smallest investigation that can distinguish the remaining explanations. Reuse
|
|
4
|
+
established resources and caches; do not build a second test platform to explain one
|
|
5
|
+
failure. This procedure works without another diagnosis skill.
|
|
6
|
+
|
|
7
|
+
## Locate the failing stage
|
|
8
|
+
|
|
9
|
+
First identify the failed source, actual checkout, build variant, artifact provenance,
|
|
10
|
+
device/API/ABI and last successful checkpoint. Do not diagnose an old repo checkout
|
|
11
|
+
as though it were the running candidate. Determine whether code/assets are embedded,
|
|
12
|
+
served by a development server, or delivered through another mechanism.
|
|
13
|
+
|
|
14
|
+
| Stage | Useful evidence and smallest starting point |
|
|
15
|
+
| --- | --- |
|
|
16
|
+
| Build/install | First failing compiler, linker, dependency or package-manager operation; reproduce the affected task before booting a device |
|
|
17
|
+
| Launch | Package and Activity, process start/exit, exception or crash record; use the affected device/runtime when necessary |
|
|
18
|
+
| Load code/assets | Actual resource source and load result; for embedded assets inspect packaging/runtime errors, for remote assets inspect the app's actual request and response |
|
|
19
|
+
| Initialize | Startup exception, configuration, service calls or producer/consumer contract; use a focused host/integration test where it reaches the defect |
|
|
20
|
+
| Render | Foreground Activity, screenshot or hierarchy, runtime errors; distinguish missing rendering from a wrong selector |
|
|
21
|
+
| Interact | State transitions and event ordering around the action; use a deterministic trigger or a bounded repeated lifecycle sequence |
|
|
22
|
+
|
|
23
|
+
Select evidence by stage. A failed compiler does not need a screenshot. A release APK
|
|
24
|
+
with embedded JavaScript does not need Metro. A physical device does not inherit the
|
|
25
|
+
stock emulator's host alias. Preserve the actual failure environment when those
|
|
26
|
+
properties may affect the cause.
|
|
27
|
+
|
|
28
|
+
## Choose a test that can expose the defect
|
|
29
|
+
|
|
30
|
+
- Use a host test when it executes the real defective logic or process lifecycle.
|
|
31
|
+
- Compose the actual producer and consumer for serialization/protocol defects. Separate
|
|
32
|
+
tests with handwritten fixtures can pass while the integrated path fails.
|
|
33
|
+
- Use the real app/device for native networking, rendering, Activity lifecycle, keyboard
|
|
34
|
+
or runtime behavior that a host double cannot exercise.
|
|
35
|
+
|
|
36
|
+
A fake hierarchy containing the expected screen can prove selector handling, ordering
|
|
37
|
+
or error classification; it cannot prove that the app loaded code and rendered that
|
|
38
|
+
screen. Likewise, a service readiness probe does not establish that the app used the
|
|
39
|
+
same endpoint. Observe the relevant application operation, not just its prerequisite.
|
|
40
|
+
|
|
41
|
+
State competing explanations and what each predicts. Change one relevant variable
|
|
42
|
+
while keeping the others fixed. A failing regression test followed by a passing
|
|
43
|
+
correction may be sufficient. For a safe reversible defect, an optional A/B/A comparison
|
|
44
|
+
can strengthen causal evidence: reproduce, apply one correction, restore that setting
|
|
45
|
+
and see whether the failure returns. Do not make A/B/A a gate for every bug, and do not
|
|
46
|
+
replay authentication, financial or other non-idempotent actions merely to obtain it.
|
|
47
|
+
|
|
48
|
+
For intermittent failures, preserve the trigger conditions, record failures/attempts and
|
|
49
|
+
use a bounded repeated sequence. Fix randomness or timing inputs where appropriate;
|
|
50
|
+
compare baseline and corrected behavior under equivalent conditions. One passing run
|
|
51
|
+
cannot establish reliability, and another sample is justified only when it answers a
|
|
52
|
+
stated question. Do not claim certainty from a small sample.
|
|
53
|
+
|
|
54
|
+
## Preserve evidence and resource ownership
|
|
55
|
+
|
|
56
|
+
Capture the evidence needed for the failing stage before cleanup deletes it. Preserve
|
|
57
|
+
the earliest exception separately from cleanup status; a cleanup timeout must not
|
|
58
|
+
replace the original error. Keep raw logs private under the repo's retention rules and
|
|
59
|
+
outside a checkout the next job deletes. Publish only sanitized findings. If original
|
|
60
|
+
logs are gone, state that limitation rather than treating a new reproduction as the
|
|
61
|
+
historical recording.
|
|
62
|
+
|
|
63
|
+
Use the repository's established launcher and resource owner. Keep peers' devices,
|
|
64
|
+
ports, databases and writable caches untouched. A borrowed physical device is not a
|
|
65
|
+
disposable AVD: do not reset it or clear its data without task authorization. Reuse a
|
|
66
|
+
shared preparation helper when callers have the same contract, while preserving
|
|
67
|
+
caller-specific behavior that is actually required.
|
|
68
|
+
|
|
69
|
+
A report needs the failed/tested sources, relevant artifact and environment differences,
|
|
70
|
+
reproduction command, controlled change, observations, evidence locations, primary and
|
|
71
|
+
cleanup outcomes, and remaining uncertainty. Do not require an APK hash for a compiler
|
|
72
|
+
failure that produced no APK.
|
|
73
|
+
|
|
74
|
+
## Bound work and distinguish progress from waiting
|
|
75
|
+
|
|
76
|
+
Give commands and child waits explicit deadlines appropriate to their purpose. Reserve
|
|
77
|
+
cleanup time and terminate only owned process groups. A force-exit option, heartbeat or
|
|
78
|
+
worker's "running" status does not impose a timeout or demonstrate progress. The generic
|
|
79
|
+
`device-run.sh` bounds startup/cleanup probes and supports `JOURNEY_SECONDS` for the
|
|
80
|
+
whole journey. Set a positive value for unattended runs; its backward-compatible
|
|
81
|
+
zero default disables that deadline. Allow time for the owner to finish cleanup.
|
|
82
|
+
|
|
83
|
+
For a hung test, identify the actual outstanding command and last completed assertion.
|
|
84
|
+
If the test waits for a child to exit, check whether its input actually requires exit.
|
|
85
|
+
Reduce that question to a bounded host test before launching another emulator.
|
|
86
|
+
|
|
87
|
+
Continue when an attempt tests a new prediction, collects a missing observation, shrinks
|
|
88
|
+
the reproduction or adds a justified sample for an intermittent failure. State the
|
|
89
|
+
purpose and cost bound first. When no available experiment distinguishes the remaining
|
|
90
|
+
explanations, report the missing evidence/access. Do not restart an unchanged campaign
|
|
91
|
+
or impose an arbitrary fixed number of retries on every kind of failure.
|
|
92
|
+
|
|
93
|
+
Choose the environment the assertion requires: local test resources for ordinary
|
|
94
|
+
functional diagnosis, isolated deployed HTTPS when that behavior requires it, or an
|
|
95
|
+
existing shared deployment for explicitly non-destructive smoke checks. Create only the
|
|
96
|
+
services needed by the test. Do not use shared dev data for destructive fixtures or
|
|
97
|
+
cleanup. A request that never reaches its gateway calls for a transport investigation,
|
|
98
|
+
not an assumed product fix.
|
|
99
|
+
|
|
100
|
+
## Example: React Native debug app uses another Metro
|
|
101
|
+
|
|
102
|
+
This example applies to a debug build that uses Metro. It is not a prescription for
|
|
103
|
+
release builds, other runtimes or physical-device addressing.
|
|
104
|
+
|
|
105
|
+
Record the host port, device port, reverse mapping, package and effective app settings.
|
|
106
|
+
Select the private ADB endpoint before importing clients that cache it. Prove readiness,
|
|
107
|
+
then observe an actual bundle request, response and screen.
|
|
108
|
+
|
|
109
|
+
For RN 0.81.5, `debug_http_host` takes precedence; otherwise `metro.host` or emulator
|
|
110
|
+
detection chooses the host and a compiled resource supplies the port. A stock emulator
|
|
111
|
+
normally selects `10.0.2.2`. Check the pinned library and build before applying that
|
|
112
|
+
explanation elsewhere. With device `tcp:8081` mapped to host `tcp:8158`, the agreed app
|
|
113
|
+
endpoint might be `127.0.0.1:8081`; copying the host port into the app is not equivalent.
|
|
114
|
+
Do not kill another worker's server if the app accidentally connects to it.
|
|
115
|
+
|
|
116
|
+
- No owned bundle request: inspect selected address, mapping and Activity launch.
|
|
117
|
+
- Request fails: inspect its response or bundling error.
|
|
118
|
+
- Bundle succeeds, expected screen absent: inspect runtime exceptions, actual screen
|
|
119
|
+
and selector.
|
|
120
|
+
|
|
121
|
+
In fmm-express #2001, a local API36 ARM64 comparison failed without the preference,
|
|
122
|
+
rendered Login after setting it, and failed again after removing it. The original API35
|
|
123
|
+
x86_64 CI response was not retained; the local HTTP 500 was not claimed as that response.
|
|
124
|
+
The corrected post-deploy CI subsequently passed on its deployed SHA. Ports, package,
|
|
125
|
+
cloud infrastructure and issue identifiers are case-study details, not requirements.
|
|
126
|
+
|
|
127
|
+
Another repo-specific example was a Node first-login fixture with an empty Organization
|
|
128
|
+
list consumed by Python. Passing the actual producer output through the real reader
|
|
129
|
+
and journey seed selection exposed the mismatch before another cloud/device run. The
|
|
130
|
+
general lesson is to test the composed contract, regardless of language or domain.
|
|
131
|
+
|
|
132
|
+
- [Case study: issue #2001](https://github.com/1aboveio/fmm-express/issues/2001)
|
|
133
|
+
- [Correction PR #2010](https://github.com/1aboveio/fmm-express/pull/2010)
|
|
134
|
+
- [Passing post-deploy run](https://github.com/1aboveio/fmm-express/actions/runs/40329312705)
|
|
135
|
+
- [RN 0.81.5 preference handling](https://raw.githubusercontent.com/facebook/react-native/v0.81.5/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/packagerconnection/PackagerConnectionSettings.kt)
|
|
136
|
+
- [RN 0.81.5 host selection](https://raw.githubusercontent.com/facebook/react-native/v0.81.5/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/AndroidInfoHelpers.kt)
|