Skip to content

feat: emit typed error envelopes for minutes and vc commands#1234

Draft
evandance wants to merge 1 commit into
mainfrom
feat/errs-migrate-minutes-vc
Draft

feat: emit typed error envelopes for minutes and vc commands#1234
evandance wants to merge 1 commit into
mainfrom
feat/errs-migrate-minutes-vc

Conversation

@evandance
Copy link
Copy Markdown
Collaborator

Summary

Migrate error handling in the minutes and vc (video-conference) command
domains from the legacy output.Err* / output.Exit* / fmt.Errorf style to
typed errs.* errors. Failures now carry a stable category and subtype, so
callers can reliably distinguish invalid input, missing permissions, and
network or service failures instead of scraping free-form text.

This is the first, mechanical part of the migration. Input/flag validation,
network/transport, local file I/O, and missing-scope failures are converted
now. Errors raised at the remote API boundary keep their current shape and are
marked with TODO(errs-migrate) until the typed request path is available.

Draft. This depends on the shared typed-runtime helpers landing on main
first. The branch will be rebased and the remaining TODO(errs-migrate) sites
(API boundary, batch partial-failure, a few precondition subtypes) completed
before it is marked ready for review.

Changes

  • shortcuts/minutes/: +upload, +update, +speaker-replace, +search, and
    +download return typed validation, network, and file-I/O errors; the shared
    save-error helper is replaced with a local typed mapping.
  • shortcuts/vc/: +meeting-join, +meeting-leave, +meeting-events,
    +search, +recording, and +notes return typed validation errors;
    +recording aligns its missing-scope failure with the typed permission error
    already used by +notes (carrying the missing scopes and identity).
  • Tests assert the typed shape (category, subtype, and parameter) alongside the
    existing message checks.
  • Remote API-boundary errors, batch partial-failure aggregation, and a few
    precondition subtypes are left with TODO(errs-migrate) markers for the
    follow-up.

Test Plan

  • gofmt -l, go vet, and go build ./... are clean.
  • go test ./shortcuts/minutes/... ./shortcuts/vc/... passes, including the new
    typed-error assertions.
  • No user-facing command behavior, flags, or output schema change; existing
    message-substring tests pass unchanged.

Related Issues

Part of the typed-errors migration; follows the pattern established for the
drive domain in #1205.

Failures from the minutes and video-conference commands now carry a stable
error category and subtype instead of free-form text, so callers can tell
apart invalid input, missing permissions, and network or service failures
without scraping messages. Errors raised at the remote API boundary keep
their current form until the typed request path is in place.
@evandance evandance added domain/minutes Minutes domain domain/vc PR touches the vc domain size/M Single-domain feat or fix with limited business impact feature labels Jun 2, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 2, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b26ff203-8f46-4e47-a934-28c41c8d12ff

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/errs-migrate-minutes-vc

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@github-actions github-actions Bot added size/L Large or sensitive change across domains or core paths and removed domain/minutes Minutes domain size/M Single-domain feat or fix with limited business impact labels Jun 2, 2026
@evandance evandance added the domain/minutes Minutes domain label Jun 2, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 2, 2026

Codecov Report

❌ Patch coverage is 51.42857% with 34 lines in your changes missing coverage. Please review.
✅ Project coverage is 69.24%. Comparing base (6d7f8ba) to head (b60ea07).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
shortcuts/minutes/minutes_download.go 23.07% 20 Missing ⚠️
shortcuts/minutes/minutes_speaker_replace.go 42.85% 4 Missing ⚠️
shortcuts/vc/vc_meeting_events.go 50.00% 3 Missing ⚠️
shortcuts/minutes/minutes_search.go 71.42% 2 Missing ⚠️
shortcuts/minutes/minutes_update.go 33.33% 2 Missing ⚠️
shortcuts/vc/vc_notes.go 66.66% 2 Missing ⚠️
shortcuts/minutes/minutes_upload.go 50.00% 1 Missing ⚠️

❌ Your patch check has failed because the patch coverage (51.42%) is below the target coverage (60.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1234      +/-   ##
==========================================
+ Coverage   69.20%   69.24%   +0.03%     
==========================================
  Files         634      635       +1     
  Lines       59517    59700     +183     
==========================================
+ Hits        41188    41337     +149     
- Misses      15014    15035      +21     
- Partials     3315     3328      +13     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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

Labels

domain/minutes Minutes domain domain/vc PR touches the vc domain feature size/L Large or sensitive change across domains or core paths

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant