Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: CI

# Enforces Rule R22 (lint + typecheck + tests + build pass before push) on
# every PR and every push to main. The four gates mirror the local commands in
# MANUAL_STEPS.md Step E.
on:
push:
branches: [main]
pull_request:

jobs:
verify:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm

- name: Install dependencies (exact lockfile)
run: npm ci

- name: Lint (errors fail; warnings reported)
run: npm run lint

- name: Type-check (strict mode)
run: npx tsc --noEmit -p tsconfig.app.json

- name: Unit tests
run: npm test

- name: Production build
run: npm run build
4 changes: 4 additions & 0 deletions supabase/functions/verify-anchor-receipt/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// Supabase Edge Function: verify-anchor-receipt (audit F4 residual)

/* eslint-disable @typescript-eslint/no-explicit-any -- Deno edge function: raw JSON-RPC and
PostgREST JSON boundaries are deliberately untyped here; this file is excluded from the
Vite app typecheck and is type-checked by Deno at deploy time. */
// Server-side confirmation of a Sepolia anchoring transaction.
//
// Why: products.blockchain_tx_status is currently manufacturer-asserted —
Expand Down
4 changes: 4 additions & 0 deletions supabase/functions/verify-wallet-link/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// Supabase Edge Function: verify-wallet-link (audit MEDIUM #7)

/* eslint-disable @typescript-eslint/no-explicit-any -- Deno edge function: raw JSON-RPC and
PostgREST JSON boundaries are deliberately untyped here; this file is excluded from the
Vite app typecheck and is type-checked by Deno at deploy time. */
// Server-side ECDSA verification of the wallet-linking signature.
//
// Why: `link_wallet_address` only FORMAT-checks the signature (^0x…130$) — the
Expand Down
Loading