2 Commits
Author SHA1 Message Date
sneak a186372877 fix: Back from Settings no longer lands on a delete wallet screen left by the gear (closes #480)
check / check (push) Waiting to run
e2e / e2e-chrome (push) Waiting to run
e2e / e2e-firefox (push) Waiting to run
Leaving the delete wallet or lost-password screen drops its wallet
selection, but the settings gear had just pushed the screen onto the Back
stack, so Back from Settings showed a screen whose button could only
answer "No wallet selected for deletion." Each screen's leave handler now
also takes it off the top of the stack, as the private key export and
recovery phrase screens do since
#461. Back from Settings then
stays on Settings once, as it does for the recovery phrase screen.

Jest tests drive the gear and then Back on both screens, and the delete
screen's own Back.

Model: opus-5-5
2026-10-07 01:09:58 +00:00
clawbot e14f6e9eb5 chore: script/bootstrap fails when node cannot find a dependency in package.json (closes #263)
check / check (push) Waiting to run
e2e / e2e-chrome (push) Waiting to run
e2e / e2e-firefox (push) Waiting to run
yarn install exits 0 without touching node_modules whenever
node_modules/.yarn-integrity matches yarn.lock, so a package deleted from
node_modules stayed deleted while bootstrap printed "bootstrap complete".
After the install, bootstrap now asks node for the package.json of every
package listed in dependencies and devDependencies of package.json, and on
the first it cannot find it names the package and the fix:
rm -rf node_modules && make bootstrap. A package whose exports hides its
package.json (ethers, libsodium-wrappers-sumo) makes node throw
ERR_PACKAGE_PATH_NOT_EXPORTED, which it does only after finding the
package, so that error counts as found.

Model: opus-5-5
2026-10-07 02:26:09 +02:00
3 changed files with 47 additions and 1 deletions
+3 -1
View File
@@ -218,7 +218,9 @@ development workflow, and the Makefile targets are thin shims that call them. We
provide:
- `script/bootstrap` — install all dependencies (pinned node via nvm if needed,
yarn via corepack, `yarn install --frozen-lockfile`)
yarn via corepack, `yarn install --frozen-lockfile`), then fail, naming the
package, if node cannot find a package listed in `dependencies` or
`devDependencies` of `package.json`
- `script/setup` — make a fresh clone ready for development: bootstrap plus the
git pre-commit hook
- `script/projectname` — print the project name (used for the Docker image tag)
+9
View File
@@ -54,6 +54,15 @@ but the review is broader than any of them.
does. `tests/deleteWalletLostPassword.test.js` drives the gear and then Back
on both screens.
- 2026-10-06: `script/bootstrap` no longer reports success while node cannot
find a package listed in `dependencies` or `devDependencies` of `package.json`
([#263](https://git.eeqj.de/sneak/AutistMask/issues/263)). After the install
it asks node for each one's `package.json`, and fails naming the missing
package and the fix. yarn skips the install whenever
`node_modules/.yarn-integrity` matches `yarn.lock`, so a package deleted from
`node_modules` stayed deleted while bootstrap said it was complete. The
fresh-clone failure the issue reports did not reproduce.
- 2026-10-06: Back from Settings no longer lands on the private key export or
recovery phrase screen after either was left by the settings gear
([#461](https://git.eeqj.de/sneak/AutistMask/issues/461)). Leaving drops the
+35
View File
@@ -127,6 +127,40 @@ install_js_deps() {
fi
}
# run_node: run node from the repo root, through nvm when node is not on PATH;
# the script comes on stdin
run_node() {
if missing node && [ -s "$HOME/.nvm/nvm.sh" ]; then
nvm_sh "nvm use $NODE_VERSION >/dev/null && cd \"$ROOT\" && node"
else
node
fi
}
# yarn install exits 0 without touching node_modules once
# node_modules/.yarn-integrity matches yarn.lock, so a package deleted from
# node_modules stays deleted. Fail unless node finds every package listed in
# dependencies and devDependencies of package.json, by its package.json. When a
# package's exports does not list that file, node throws
# ERR_PACKAGE_PATH_NOT_EXPORTED, which it can only do once it has found the
# package, so that error counts as found.
check_js_deps() {
run_node <<'EOF'
const { dependencies, devDependencies } = require("./package.json");
for (const name of Object.keys({ ...dependencies, ...devDependencies })) {
try {
require.resolve(name + "/package.json");
} catch (e) {
if (e.code !== "ERR_PACKAGE_PATH_NOT_EXPORTED") {
console.error(`bootstrap: node cannot find ${name} after yarn install`);
console.error(" fix: rm -rf node_modules && make bootstrap");
process.exit(1);
}
}
}
EOF
}
main() {
cd "$ROOT"
@@ -136,6 +170,7 @@ main() {
ensure_node
ensure_yarn
install_js_deps
check_js_deps
echo "bootstrap complete"
}