Skip to content

Work Intent: Repair and fully verify arraySubscription event payloads #2058

Description

@jmagar

Overview

Fix the confirmed arraySubscription GraphQL event payload mismatch reported in #2056. The resolver exposes arraySubscription, but the event listener currently publishes { array }, causing non-null subscription failures when an update is emitted.

No implementation work will begin until this Work Intent is approved.

Technical Approach

  • Create a focused branch from current main.
  • Change the array event publisher to emit the GraphQL subscription root field expected by the resolver.
  • Add a regression test that exercises the publisher/resolver contract, not merely resolver construction.
  • Prefer an end-to-end GraphQL subscription test that subscribes, publishes an array update, and asserts a complete non-null payload.
  • Preserve the regular array query and existing array event timing/debouncing behavior.
  • Run pnpm --filter ./api test, API lint, API type-check, and the repository build.
  • Build and deploy a test artifact to a controlled Unraid 7.3.2 target.
  • Subscribe through the real GraphQL WebSocket endpoint, trigger a real array event, and prove the former non-null error is replaced by a valid arraySubscription payload.
  • Re-run representative working subscriptions to guard against shared pub/sub regressions.

A PR will only be submitted if repository tests and the live end-to-end proof all pass. If the live proof cannot be completed safely and conclusively, no fix PR will be opened.

Scope

  • API
  • Plugin
  • Web UI
  • Build/Deploy Process
  • Documentation

Timeline & Impact

  • Estimated time needed: 1-2 focused development sessions after approval
  • Potential impacts: Array subscription clients only. No array mutations or lifecycle behavior will be changed.

Pre-submission Checklist

  • I have searched for similar work/issues
  • I understand this needs approval before starting
  • I am willing to make adjustments based on feedback

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions