LearnNewsExamplesServices
Frontmatter
id12973
titlePortal discussions parser test reads a sync-mutable content path (broken by the v13 archive re-chunk)
stateClosed
labels
bugaitesting
assigneesneo-gpt
createdAtJun 12, 2026, 10:34 AM
updatedAtJun 12, 2026, 11:09 AM
githubUrlhttps://github.com/neomjs/neo/issues/12973
authorneo-fable
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJun 12, 2026, 11:09 AM

Portal discussions parser test reads a sync-mutable content path (broken by the v13 archive re-chunk)

neo-fable
neo-fable commented on Jun 12, 2026, 10:34 AM

Context

First CI run after the v13 release's post-publish sync: test/playwright/unit/apps/portal/view/news/discussions/Component.spec.mjs:193 fails deterministically (3/3 incl. retries) with ENOENT: resources/content/discussions/chunk-2/discussion-11891.md. Surfaced by the operator from the PR #12971 CI logs.

Release classification: post-release, fix-fast — it reds the unit suite for every PR until fixed (the suite was honest-green 53/0-class before the release sync landed).

The Problem

The test pins the markdown parser's timeline-HTML-escaping behavior by reading a LIVE synced-content file as its fixture (Component.spec.mjs:195). The v13 post-release sync (c6cd0bebf "chore: ticket sync") archived older discussions, which re-balanced the ordinal-100 chunk layout: discussion-11891.md moved chunk-2/chunk-1/ (verified via git ls-tree origin/dev). Any future sync can move it again — the coupling is brittle BY DESIGN of the chunk layout, not by accident.

The Architectural Reality

  • resources/content/** is sync-owned, churn-expected substrate (archive moves at every release; chunk ordinals re-balance). Tests asserting FROZEN behavior (parser semantics) must not read sync-mutable paths.
  • The parser contract under test is content-independent: it needs A representative discussion markdown with timeline HTML, not THE live #11891 file.

The Fix

  1. Copy the needed markdown once into a committed test fixture (e.g. test/playwright/unit/apps/portal/view/news/discussions/fixtures/discussion-timeline.md) and point the spec at it. The fixture freezes the parser-relevant shape; live-content drift becomes irrelevant.
  2. Sweep AC: audit the other specs reading resources/content/** (grep hits include TreeList.spec, PortalContentIndexes.spec, TicketIndex.spec, check-chore-sync.spec etc.) — index/infra tests legitimately read the live tree; any OTHER spec pinning behavior on a SPECIFIC synced file gets the same fixture treatment.

Acceptance Criteria

  • The spec is green against a committed fixture; no unit spec reads a specific sync-mutable content file as a behavior fixture (sweep documented).
  • Unit suite back to honest-green on dev.

Out of Scope

  • The two memory-core flaky tests from the same CI run (sibling ticket).

Related

PR #12971 (the run that surfaced it), c6cd0bebf (the sync commit), #12696 (the release).

Sweep note: live latest-open sweep waived under the active GitHub API rate-limit exhaustion; defects born this hour, session-fresh knowledge confirms no duplicate.

Origin Session ID: e605ce21-3668-445c-bc00-45896aa9a092

Retrieval Hint: "discussions chunk fixture ENOENT sync-mutable path parser test"

tobiu referenced in commit 1f2d56f - "fix(portal): decouple discussion parser fixture from sync chunks (#12973) (#12976)" on Jun 12, 2026, 11:09 AM
tobiu closed this issue on Jun 12, 2026, 11:09 AM