Skip to content

fix: address PR #57 review findings — deadlocks, godoc, changelog refs - #58

Merged
danielewood merged 1 commit into
mainfrom
fix/pr57-review-findings
Feb 23, 2026
Merged

fix: address PR #57 review findings — deadlocks, godoc, changelog refs#58
danielewood merged 1 commit into
mainfrom
fix/pr57-review-findings

Conversation

@danielewood

Copy link
Copy Markdown
Collaborator

Summary

  • Fix three panic-deadlock bugs in WASM: addFiles and AIA goroutine used manual storeMu.Unlock() instead of defer, meaning any panic permanently deadlocks the store
  • Fix ERR-6 violation: json.Marshal failure in AIA goroutine fell through to onComplete callback with nil JSON instead of returning early
  • Fix API-1 violation: VerifyChainTrust godoc comment was contiguous with the struct comment, so Go attached it to VerifyChainTrustInput — function had no godoc
  • Fix CL-3/CL-4: three changelog entries referenced non-existent commit b5969b0 — replaced with [#57] PR ref

Addresses all unresolved review comments from #57.

Test plan

  • go build ./... passes
  • go test -race ./... passes
  • GOOS=js GOARCH=wasm go vet ./cmd/wasm/ passes
  • GOOS=js GOARCH=wasm go build ./cmd/wasm/ passes
  • All pre-commit hooks pass (including markdownlint)

🤖 Generated with Claude Code

Fix three panic-deadlock bugs in WASM (non-deferred mutex unlocks in
addFiles and AIA goroutine), an ERR-6 fall-through after json.Marshal
failure, a godoc mis-attachment on VerifyChainTrust, and three changelog
entries referencing a non-existent commit SHA.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings February 23, 2026 03:25

Copilot AI 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.

Pull request overview

This PR addresses four specific issues identified during the review of PR #57, focusing on critical concurrency bugs, error handling, documentation, and changelog maintenance.

Changes:

  • Fix three panic-induced deadlock bugs in WASM by replacing manual storeMu.Unlock() calls with defer statements
  • Fix ERR-6 violation by adding early return when json.Marshal fails in AIA goroutine
  • Fix API-1 violation by repositioning VerifyChainTrustInput struct before VerifyChainTrust function for proper godoc attachment
  • Fix CL-3/CL-4 violations by replacing non-existent commit references with PR references in changelog

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
cmd/wasm/main.go Adds defer storeMu.Unlock() to prevent deadlocks on panic in addFiles main goroutine and AIA goroutine; adds early return after Marshal error
bundle.go Moves VerifyChainTrustInput struct definition before VerifyChainTrust function to ensure godoc attaches correctly
CHANGELOG.md Replaces three references to non-existent commit b5969b0 with [#57] PR reference; adds four new entries documenting the fixes in this PR; updates reference links section

@claude

claude Bot commented Feb 23, 2026

Copy link
Copy Markdown

Code review

No issues found. Checked for bugs and CLAUDE.md compliance.

@danielewood
danielewood merged commit c8c1ce0 into main Feb 23, 2026
19 checks passed
@danielewood
danielewood deleted the fix/pr57-review-findings branch February 23, 2026 03:36
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.

2 participants