Skip to content

Commit 2c19831

Browse files
wesbillmanCarl
andcommitted
Merge main into mobile polish branch
Preserve current channel-list scroll interruption behavior while updating the PR to the latest main before delivery validation. Co-authored-by: Carl <c7ebe626f000404285d3686e1dc74cc07cc60a9754a150041ba132e14bd3e2ec@buzz.block.builderlab.xyz> Signed-off-by: Wes <[email protected]>
2 parents a226403 + 5743562 commit 2c19831

105 files changed

Lines changed: 6801 additions & 1527 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/release.yml‎

Lines changed: 59 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -775,6 +775,63 @@ jobs:
775775
${{ steps.artifacts.outputs.exe }}
776776
${{ steps.artifacts.outputs.sig }}
777777
778+
desktop-release-smoke:
779+
name: Desktop release smoke
780+
if: github.repository == 'block/buzz'
781+
runs-on: ubuntu-latest
782+
needs: setup
783+
timeout-minutes: 20
784+
permissions:
785+
contents: read
786+
env:
787+
PLAYWRIGHT_BROWSERS_PATH: ${{ github.workspace }}/.cache/ms-playwright
788+
steps:
789+
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
790+
with:
791+
ref: ${{ needs.setup.outputs.source_sha }}
792+
persist-credentials: false
793+
- uses: cashapp/activate-hermit@cea9af7913204a965fd488637a8d1811bba2e616 # v1
794+
- name: Install desktop dependencies
795+
run: just desktop-install-ci
796+
- name: Get Playwright version
797+
id: pw-version
798+
run: echo "version=$(cd desktop && node -e \"console.log(require('@playwright/test/package.json').version)\")" >> "$GITHUB_OUTPUT"
799+
- name: Restore Playwright browser cache
800+
id: playwright-cache
801+
uses: actions/cache/restore@caa296126883cff596d87d8935842f9db880ef25 # v5
802+
with:
803+
path: ${{ env.PLAYWRIGHT_BROWSERS_PATH }}
804+
key: playwright-${{ runner.os }}-${{ steps.pw-version.outputs.version }}
805+
- name: Install Playwright Chromium
806+
if: steps.playwright-cache.outputs.cache-hit != 'true'
807+
run: cd desktop && pnpm exec playwright install chromium
808+
- name: Install Playwright system dependencies
809+
run: cd desktop && pnpm exec playwright install-deps chromium
810+
- name: Save Playwright browser cache
811+
if: steps.playwright-cache.outputs.cache-hit != 'true'
812+
uses: actions/cache/save@caa296126883cff596d87d8935842f9db880ef25 # v5
813+
with:
814+
path: ${{ env.PLAYWRIGHT_BROWSERS_PATH }}
815+
key: playwright-${{ runner.os }}-${{ steps.pw-version.outputs.version }}
816+
- name: Build test relay
817+
run: cargo build --profile ci -p buzz-relay
818+
- name: Run deterministic correctness smoke
819+
env:
820+
BUZZ_E2E_RELAY_BIN: ${{ github.workspace }}/target/ci/buzz-relay
821+
BUZZ_RELEASE_SMOKE_ARTIFACT_DIR: ${{ github.workspace }}/release-smoke-artifacts
822+
run: just desktop-release-smoke
823+
- name: Upload release-smoke diagnostics
824+
if: always()
825+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
826+
with:
827+
name: desktop-release-smoke
828+
path: |
829+
release-smoke-artifacts
830+
desktop/test-results
831+
desktop/playwright-release-smoke-report
832+
if-no-files-found: warn
833+
retention-days: 14
834+
778835
assemble-manifest:
779836
name: Assemble multi-platform latest.json
780837
# Only the tag-bound setup path can reach this job.
@@ -785,9 +842,10 @@ jobs:
785842
needs.release-macos-x64.result == 'success' &&
786843
needs.release-linux.result == 'success' &&
787844
needs.release-windows.result == 'success' &&
845+
needs.desktop-release-smoke.result == 'success' &&
788846
github.ref == format('refs/tags/desktop-v{0}', needs.setup.outputs.version)
789847
runs-on: ubuntu-latest
790-
needs: [setup, release, release-macos-x64, release-linux, release-windows]
848+
needs: [setup, release, release-macos-x64, release-linux, release-windows, desktop-release-smoke]
791849
timeout-minutes: 10
792850
permissions:
793851
contents: write

‎Cargo.lock‎

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎Justfile‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,10 @@ desktop-e2e-smoke:
276276
desktop-e2e-integration: _ensure-migrations
277277
cd {{desktop_dir}} && pnpm test:e2e:integration
278278

279+
# Run the deterministic desktop correctness smoke against an isolated local relay
280+
desktop-release-smoke:
281+
./scripts/run-desktop-release-smoke.sh
282+
279283
# Run only the e2e specs changed vs origin/main (both projects) before pushing
280284
desktop-e2e-pre-push: _ensure-migrations
281285
git fetch origin main

‎TESTING.md‎

Lines changed: 42 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,49 @@ buzz messages thread --channel "$CHANNEL" --event "$EVENT_ID" | jq .
155155
156156
A successful run prints `{"event_id":"…","accepted":true,"message":""}` for
157157
the send, and the message body in the `get` output. `thread` returns `[]`
158-
for a leaf message — populated only after a reply comes in (see §5).
158+
for a leaf message — populated only after a reply comes in (see §6).
159159

160-
### 5. Going deeper
160+
### 5. Verify a roster beyond 1,000 members
161+
162+
Use the focused live-relay script when changing channel membership, discovery,
163+
or reconciliation. It proves the three boundaries that DB-only tests cannot:
164+
the relay-served kind 39002 includes a member at roster position 1,501, that
165+
identity can publish a channel message, and targeted reconciliation preserves
166+
its discoverability.
167+
168+
Run this only against an isolated local database. The script inserts fixture
169+
members directly, then drives discovery and messaging through the release CLI
170+
and relay. Keep the release relay from step 3 running and use its configured
171+
relay key for authoritative replacement:
172+
173+
```bash
174+
export PATH="$PWD/target/release:$PATH"
175+
export DATABASE_URL="postgres://buzz:buzz_dev@localhost:5432/buzz_roster_e2e"
176+
export BUZZ_RELAY_URL="http://localhost:3030" # match the relay from step 3
177+
export RELAY_URL="ws://localhost:3030"
178+
export BUZZ_RELAY_PRIVATE_KEY="<same key used by buzz-relay>"
179+
180+
scripts/e2e-large-channel-roster.sh
181+
```
182+
183+
Success is directly observable as four `PASS` lines. The first and fourth
184+
include a member count greater than 1,000 and the same late-member pubkey; the
185+
second includes the accepted kind 9 event ID, and the third proves targeted
186+
repair left kind 39000/39001 IDs and tags unchanged:
187+
188+
```text
189+
PASS discovery-before-republish channel=<uuid> members=1502 late_pubkey=<hex>
190+
PASS late-member-action event_id=<hex>
191+
PASS targeted-repair-preserves-metadata-and-admin-events channel=<uuid>
192+
PASS discovery-after-republish channel=<uuid> members=1502 late_pubkey=<hex>
193+
```
194+
195+
The script refuses debug binaries and refuses a `buzz` or `buzz-admin` resolved
196+
outside this checkout's `target/release`. It also requires the targeted admin
197+
operation to use `BUZZ_RELAY_PRIVATE_KEY`; never substitute an ephemeral signer
198+
for an authoritative replacement.
199+
200+
### 6. Going deeper
161201

162202
For full coverage of every CLI command (54 subcommands across 12 groups),
163203
follow [`crates/buzz-cli/TESTING.md`](crates/buzz-cli/TESTING.md).

0 commit comments

Comments
 (0)