Skip to content

[Docs] - Update the README.md - #104

Merged
amaify merged 2 commits into
devfrom
tobe/update-readme
Aug 12, 2026
Merged

[Docs] - Update the README.md#104
amaify merged 2 commits into
devfrom
tobe/update-readme

Conversation

@amaify

@amaify amaify commented Aug 12, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • Documentation

    • Updated setup requirements to Node.js 22.18 or later and Playwright 1.62.1.
    • Clarified wallet setup filenames, multi-profile naming, directory examples, and shared wallet contexts.
    • Updated Keplr extension source and defineWalletSetup configuration guidance.
    • Added Node.js 24 CI coverage and refreshed package-manager setup instructions.
  • Release

    • Published version 0.11.1 with updated documentation.

@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The package version changes to 0.11.1. The changelog records the patch release. The README updates runtime requirements, wallet setup guidance, fixture usage, CI configuration, and defineWalletSetup documentation.

Changes

Release and documentation updates

Layer / File(s) Summary
README requirements and wallet setup guidance
README.md
The README updates Node.js and Playwright requirements, wallet setup filenames, profile naming, extension sources, setup paths, fixture guidance, and defineWalletSetup fields.
README CI workflow guidance
README.md
The README documents a Node 24 matrix and the pnpm/setup@v2 configuration.
0.11.1 release metadata
package.json, CHANGELOG.md
The package version changes to 0.11.1. The changelog records the README update.
Estimated code review effort: 2 (Simple) ~10 minutes

Suggested reviewers: tobechukwu-fieldlabs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly identifies the primary change: updating the README documentation.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tobe/update-readme

Comment @coderabbitai help to get the list of available commands.

@amaify amaify self-assigned this Aug 12, 2026
@amaify amaify changed the title Update the README.md [Docs] - Update the README.md Aug 12, 2026
@amaify
amaify merged commit 609fe4a into dev Aug 12, 2026
4 of 5 checks passed
@amaify
amaify deleted the tobe/update-readme branch August 12, 2026 10:36

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (1)
README.md (1)

397-399: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Test the documented minimum Node.js version in CI.

The requirements declare Node.js >=22.18, but the matrix runs only Node 24. Add Node 22.18 to the matrix, or change the documented minimum to match the tested support range.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 397 - 399, Update the node-version matrix in the CI
configuration to include Node.js 22.18 alongside Node 24, so CI tests the
documented minimum supported version.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Around line 469-471: Update the README option description for password to
explicitly state that the wallet password is stored in plaintext in password.txt
within the wallet cache, and instruct users to protect the cache directory.
- Around line 469-471: Update the README `config` documentation to describe
`extensionSource` as a union of either `{ localPath }` or `{ downloadUrl, sha256
}`. State that `sha256` is required when `downloadUrl` is provided, while
`localPath` uses the supported wallet’s built-in checksum.
- Line 80: Update the README setup-file examples to use supported
wallet-prefixed filenames required by getSetupFunction, such as
metamask.setup.ts and metamask-two.setup.ts, including the additional examples
referenced by the comment. Replace the placeholder term “domain” with “suffix”
or “extension” in the setup-file naming guidance.
- Around line 416-417: Update the CI dependency installation step’s pnpm command
from --no-frozen-lockfile to --frozen-lockfile, ensuring builds fail when
pnpm-lock.yaml is inconsistent with package.json.

---

Nitpick comments:
In `@README.md`:
- Around line 397-399: Update the node-version matrix in the CI configuration to
include Node.js 22.18 alongside Node 24, so CI tests the documented minimum
supported version.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 6c7eea03-db59-4b34-a132-0b06ac3ae241

📥 Commits

Reviewing files that changed from the base of the PR and between 1c3b288 and db87aaf.

📒 Files selected for processing (3)
  • CHANGELOG.md
  • README.md
  • package.json

Comment thread README.md
### 1. Create wallet setup files

Create a setup directory (default: `tests/wallet-setup`) and add `*.setup.ts` files with a wallet name in the filename, for example:
Create a setup directory (default: `tests/wallet-setup`) and add files with a `*.setup.ts` domain in the filename, for example:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Use a supported wallet name in every setup-file example.

getSetupFunction requires setup filenames to include a valid supported wallet name. base.setup.ts, base-two.setup.ts, main.setup.ts, and main-two.setup.ts do not satisfy that contract. Users who copy these examples cannot resolve a wallet setup. Rename them to wallet-prefixed names, such as metamask.setup.ts and metamask-two.setup.ts. Replace domain with suffix or extension.

Also applies to: 148-150

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` at line 80, Update the README setup-file examples to use supported
wallet-prefixed filenames required by getSetupFunction, such as
metamask.setup.ts and metamask-two.setup.ts, including the additional examples
referenced by the comment. Replace the placeholder term “domain” with “suffix”
or “extension” in the setup-file naming guidance.

Comment thread README.md
Comment on lines 416 to +417
- name: Install dependencies
run: pnpm install
run: pnpm install --no-frozen-lockfile

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- repository files relevant to pnpm/CI ---'
git ls-files | grep -E '(^|/)(README\.md|package\.json|pnpm-lock\.yaml|pnpm-workspace\.yaml|.*\.ya?ml)$' | head -200

printf '%s\n' '--- README context ---'
sed -n '390,430p' README.md

printf '%s\n' '--- pnpm references ---'
rg -n -C 3 --glob '!pnpm-lock.yaml' 'pnpm install|frozen-lockfile|no-frozen-lockfile|setup-pnpm|pnpm/action|pnpm@' .

printf '%s\n' '--- package manager declarations ---'
for f in package.json pnpm-workspace.yaml .npmrc; do
  if [ -f "$f" ]; then
    echo "### $f"
    cat "$f"
  fi
done

Repository: amaify/chainwright

Length of output: 5823


🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- lockfile metadata and importer ---'
sed -n '1,90p' pnpm-lock.yaml

printf '%s\n' '--- pnpm availability and install help (read-only) ---'
if command -v pnpm >/dev/null 2>&1; then
  pnpm --version
  pnpm install --help | grep -E -A2 -B2 -- '--frozen-lockfile|--no-frozen-lockfile' || true
else
  echo 'pnpm is not available in the sandbox'
fi

printf '%s\n' '--- package.json and lockfile dependency-spec comparison ---'
python3 - <<'PY'
import json
from pathlib import Path

package = json.loads(Path("package.json").read_text())
lock = Path("pnpm-lock.yaml").read_text().splitlines()

# This verifier checks the root importer block without importing or executing
# repository code. It compares package.json dependency declarations with the
# corresponding lockfile specifier lines.
root_start = next((i for i, line in enumerate(lock)
                   if line.startswith("  ") and line.strip() == "specifiers:"), None)
if root_start is None:
    print("No root importer specifiers block found")
    raise SystemExit(0)

root_end = root_start + 1
while root_end < len(lock) and (lock[root_end].startswith("    ") or not lock[root_end].strip()):
    root_end += 1

specifiers = {}
for line in lock[root_start + 1:root_end]:
    stripped = line.strip()
    if ":" in stripped:
        name, value = stripped.split(":", 1)
        specifiers[name.strip("'\"")] = value.strip().strip("'\"")

declared = {}
for section in ("dependencies", "devDependencies", "peerDependencies", "optionalDependencies"):
    declared.update(package.get(section, {}))

missing = sorted(set(declared) - set(specifiers))
different = sorted((name, declared[name], specifiers[name])
                   for name in declared
                   if name in specifiers and declared[name] != specifiers[name])

print("declared dependencies:", len(declared))
print("lockfile specifiers:", len(specifiers))
print("missing:", missing)
print("different:", different)
PY

Repository: amaify/chainwright

Length of output: 3951


🌐 Web query:

pnpm install --frozen-lockfile --no-frozen-lockfile CI default lockfile out of date official documentation

💡 Result:

In pnpm, the --frozen-lockfile flag controls whether the installation should fail if the lockfile is out of sync with the manifest (package.json) [1][2]. Default Behavior and CI Environments By default, --frozen-lockfile is set to false in local development environments [1][2]. However, in Continuous Integration (CI) environments, this setting is automatically enabled (true) if a lockfile is present [1][3][2]. pnpm detects a CI environment by checking for standard environment variables such as CI, CONTINUOUS_INTEGRATION, or specific build system variables (e.g., BUILD_NUMBER) [1][2]. When --frozen-lockfile is true (or implicitly enabled in CI): - The installation will fail with an error (ERR_PNPM_OUTDATED_LOCKFILE) if the pnpm-lock.yaml file is missing or out of sync with package.json [1][2][4]. - The lockfile will not be modified or updated [1][5]. - This ensures reproducible builds, as the environment will not silently adjust dependency resolutions [5][6]. Overriding Behavior If you need to bypass this behavior in a CI environment, you can explicitly set the flag to false by appending --no-frozen-lockfile to your installation command [7][8]: pnpm install --no-frozen-lockfile This allows the installation to proceed even if the lockfile is technically out of date, as pnpm will not perform the strict consistency check that triggers the error [6][8]. Important Note on Updating It is important to understand that --frozen-lockfile=false does not mean pnpm will update your lockfile [6]. It simply means pnpm will not fail the installation if a mismatch is detected [6]. To update the lockfile, you should use commands such as pnpm update, which resolves dependencies and regenerates the lockfile based on your package.json [6]. For a dedicated CI command, you can also use pnpm ci, which is an alias for pnpm clean-install and is explicitly designed to perform a clean install with --frozen-lockfile enabled [5].

Citations:


🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- lockfile metadata and importer ---'
sed -n '1,90p' pnpm-lock.yaml

printf '%s\n' '--- pnpm availability and install help (read-only) ---'
if command -v pnpm >/dev/null 2>&1; then
  pnpm --version
  pnpm install --help | grep -E -A2 -B2 -- '--frozen-lockfile|--no-frozen-lockfile' || true
else
  echo 'pnpm is not available in the sandbox'
fi

printf '%s\n' '--- package.json and lockfile dependency-spec comparison ---'
python3 - <<'PY'
import json
from pathlib import Path

package = json.loads(Path("package.json").read_text())
lock = Path("pnpm-lock.yaml").read_text().splitlines()

root_start = next((i for i, line in enumerate(lock)
                   if line.startswith("  ") and line.strip() == "specifiers:"), None)
if root_start is None:
    print("No root importer specifiers block found")
    raise SystemExit(0)

root_end = root_start + 1
while root_end < len(lock) and (lock[root_end].startswith("    ") or not lock[root_end].strip()):
    root_end += 1

specifiers = {}
for line in lock[root_start + 1:root_end]:
    stripped = line.strip()
    if ":" in stripped:
        name, value = stripped.split(":", 1)
        specifiers[name.strip("'\"")] = value.strip().strip("'\"")

declared = {}
for section in ("dependencies", "devDependencies", "peerDependencies", "optionalDependencies"):
    declared.update(package.get(section, {}))

missing = sorted(set(declared) - set(specifiers))
different = sorted((name, declared[name], specifiers[name])
                   for name in declared
                   if name in specifiers and declared[name] != specifiers[name])

print("declared dependencies:", len(declared))
print("lockfile specifiers:", len(specifiers))
print("missing:", missing)
print("different:", different)
PY

Repository: amaify/chainwright

Length of output: 3951


Keep CI dependency installation frozen.

Use pnpm install --frozen-lockfile so CI fails when pnpm-lock.yaml is out of sync with package.json.

Proposed fix
-        run: pnpm install --no-frozen-lockfile
+        run: pnpm install --frozen-lockfile
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- name: Install dependencies
run: pnpm install
run: pnpm install --no-frozen-lockfile
- name: Install dependencies
run: pnpm install --frozen-lockfile
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 416 - 417, Update the CI dependency installation
step’s pnpm command from --no-frozen-lockfile to --frozen-lockfile, ensuring
builds fail when pnpm-lock.yaml is inconsistent with package.json.

Comment thread README.md
Comment on lines +469 to +471
- `password: string` - wallet unlock password saved as a `.txt` file in the wallet cache
- `setupFn: ({ context, walletPage }) => Promise<void>` - runs onboarding/setup flow
- `config?: { profileName?: string; slowMo?: number, extensionSource?: {downloadUrl: "...", localPath: "...", sha256: "..."} }` - useful for setting up multiple wallet profiles, running the setup in slow motion `slowMo` and using a custom extension source.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

State that the wallet password is stored in plaintext.

src/core/trigger-cache-creation.ts writes walletPassword directly to password.txt. Document that the cache contains plaintext credentials and instruct users to protect the cache directory.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 469 - 471, Update the README option description for
password to explicitly state that the wallet password is stored in plaintext in
password.txt within the wallet cache, and instruct users to protect the cache
directory.

🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- configuration symbols and extensionSource references ---'
rg -n -S -C 4 'extensionSource|ExtensionSource|config\??:' --glob '!node_modules' --glob '!dist' --glob '!build' .

printf '%s\n' '--- candidate TypeScript file map ---'
fd -t f -e ts -e tsx -e js -e d.ts . | head -200

printf '%s\n' '--- README context ---'
sed -n '430,490p' README.md

Repository: amaify/chainwright

Length of output: 19734


🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- exported type definition ---'
cat -n src/types.ts | sed -n '24,50p'

printf '%s\n' '--- extension-source runtime handling ---'
cat -n src/utils/prepare-wallet-extension.ts | sed -n '21,75p'

printf '%s\n' '--- integrity helper and call sites ---'
cat -n src/utils/verify-file-integrity.ts
rg -n -S -C 3 'verifyFileIntegrity|expectedSha256|sha256' src examples README.md

Repository: amaify/chainwright

Length of output: 19581


🏁 Script executed:

#!/bin/bash
set -eu

python3 - <<'PY'
from pathlib import Path
import re

types = Path("src/types.ts").read_text()
runtime = Path("src/utils/prepare-wallet-extension.ts").read_text()
readme = Path("README.md").read_text()

assert re.search(
    r"export type ExtensionSource\s*=\s*\|\s*\{\s*localPath:\s*string;\s*\}\s*\|\s*\{\s*downloadUrl:\s*string;\s*sha256:\s*string;\s*\};",
    types,
    re.S,
), "ExtensionSource is not the expected union"

assert '"downloadUrl" in extensionSource' in runtime
assert '"localPath" in extensionSource' in runtime
assert "expectedSha256 = isExtensionSource ? extensionSource.sha256 : supportedWallet.sha256" in runtime

documented = re.search(r"extensionSource\?:\s*\{([^}]*)\}", readme)
assert documented, "README extensionSource shape not found"
fields = set(re.findall(r"\b(downloadUrl|localPath|sha256)\b", documented.group(1)))
expected_download = {"downloadUrl", "sha256"}
expected_local = {"localPath"}

print("Exported union branches: localPath; downloadUrl + sha256")
print("README fields in one object:", sorted(fields))
print("README matches union:", fields in (expected_download, expected_local))
print("Runtime localPath branch: uses localPath and falls back to the supported wallet SHA-256")
print("Runtime downloadUrl branch: uses downloadUrl and extensionSource.sha256")
PY

Repository: amaify/chainwright

Length of output: 469


Document extensionSource as a union.

The type accepts either { localPath } or { downloadUrl, sha256 }. State that sha256 is required with downloadUrl; localPath uses the supported wallet's built-in checksum.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 469 - 471, Update the README `config` documentation
to describe `extensionSource` as a union of either `{ localPath }` or `{
downloadUrl, sha256 }`. State that `sha256` is required when `downloadUrl` is
provided, while `localPath` uses the supported wallet’s built-in checksum.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant