GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix: PR #56 残り — parseFrontmatter型バリデーション + repetition test重複 · Issue #69 · Cor-Incorporated/opencode

fix: PR #56 残り — parseFrontmatter型バリデーション + repetition test重複 #69

New issue
Copy link
New issue
Copy link
Closed
#70
Closed
fix: PR #56 残り — parseFrontmatter型バリデーション + repetition test重複#69
#70
Copy link

Description

@terisuke
terisuke
opened on Apr 5, 2026
Issue body actions

発見元

PR #56 レビューコメント(items d, e)+ Codex CLI セカンドオピニオン確認 + コード検証済み(2026-04-05)

未修正項目

1. parseFrontmatter 型バリデーション未実装

  • packages/opencode/src/memory/file.ts:41
  • 現状: fm.type as Memory.Type でキャストのみ、バリデーションなし
  • ユーザー編集可能ファイルのため invalid type が無検証で伝播
  • 対策: Memory.Type の値を Zod enum / Set.has() でバリデーション、invalid → undefined 返却

2. repetition test がアルゴリズムを重複実装

  • packages/opencode/test/session/repetition.test.ts:8-23
  • 現状: production の detectRepetition を import せず、定数含め全て再実装
  • テストコメントに「namespace-internal function」と明記あり
  • 対策: detectRepetition を shared util に抽出してテストから import

重要度: LOW(品質改善)

関連: PR #56

Activity

  1. terisuke
    added 2 commits that reference this issue on Apr 5, 2026

    refactor(session): extract detectRepetition to shared util

    This issue will close once commit 7439e20 is merged into the 'dev' branch.
    7439e20

    fix(memory): validate frontmatter type against Memory.TYPES

    This issue will close once commit cc485d3 is merged into the 'dev' branch.
    cc485d3
  2. terisuke
    closed this as completedin #70on Apr 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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

      You are visitor 01402792 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.