Skip to content

가격 히스토리에 출처 라벨 추가: source·editedByMe - #849

Merged
m-a-king merged 2 commits into
devfrom
feat/825-history-source-labels
Jul 31, 2026
Merged

가격 히스토리에 출처 라벨 추가: source·editedByMe#849
m-a-king merged 2 commits into
devfrom
feat/825-history-source-labels

Conversation

@m-a-king

@m-a-king m-a-king commented Jul 31, 2026

Copy link
Copy Markdown
Collaborator

Situation

Task

  • 가격 히스토리의 각 항목에 출처 라벨을 additive 로 실어, 클라이언트가 "기계값만 그리는 가격 그래프"와 "타인이 고친 값" 표시를 만들 수 있게 한다.

Action

  • 각 이력 항목에 두 필드를 추가했다.
필드 의미
source SERVER / SERVER_LLM / MANUAL / null 이 버전을 만든 출처. null 은 출처 기록 도입 전에 쌓인 버전(모름)
editedByMe true / false / null 수기(MANUAL) 버전 한정, 요청자 본인이 입력했는지. false 면 타인이 고친 값. 기계·출처 미상 버전은 null
  • 편집자 식별자는 노출하지 않는다: edited_by(UUID)는 개인 식별자라 응답에 싣지 않고, 요청자와의 비교 결과(Boolean)로만 파생한다.
  • OpenAPI example 을 기계(SERVER)·타인 수기(MANUAL, editedByMe=false)·LLM(SERVER_LLM) 3항목으로 재구성해 라벨의 의미가 docs 에서 바로 읽히게 했다.
  • 검증: 출처 미상(null)·기계·타인 수기·내 수기 네 버전을 시딩해 항목별 source·editedByMe 매핑을 단언하는 통합 테스트를 추가했다. 기계·미상 버전의 editedByMe 가 응답에서 부재(null)인 것까지 고정한다.

Result

  • 클라이언트가 가격 추적 그래프에서 MANUAL 을 기본 제외하고, 이력 화면에서 "타인이 고친 값" 배지를 그릴 수 있는 데이터가 완성됐다.
  • 카드 표시값을 "마지막 기계 추출값"으로 합성하는 변경은 이번에 하지 않았다. 회의에서 수기 고정 여부가 유보된 부분이라, 자율로 계약을 바꾸지 않고 후속 논의로 남긴다.

연관 이슈

Summary by CodeRabbit

  • 새로운 기능

    • 가격 이력에 각 항목의 출처를 표시합니다. 서버 추출, 수기 수정, 과거 자동 추출 이력을 구분할 수 있습니다.
    • 수기 수정 이력에 대해 현재 사용자가 직접 편집한 항목인지 확인할 수 있습니다.
    • 출처나 편집자 정보가 없는 기존 이력은 해당 정보를 비워 호환성을 유지합니다.
  • 개선

    • 가격 이력 설명에 수기 수정 및 출처별 처리 기준을 반영했습니다.

m-a-king added 2 commits July 31, 2026 10:05
- 각 이력 항목에 source(SERVER/SERVER_LLM/MANUAL, 도입 전 행은 null)와 editedByMe(수기 버전 한정, 본인 여부)를 additive 로 싣는다
- 서버는 수기 포함 전체 이력을 내려주고 필터는 클라 기본값이 담당한다는 회의 결정의 서버 측 구현 - 가격 추적 뷰가 MANUAL 을 걸러 그릴 수 있는 데이터가 완성된다
- 편집자 UUID 원값은 개인 식별자라 응답에 싣지 않고 본인 여부(Boolean)로만 파생
- example 을 3항목(기계 SERVER·타인 수기 MANUAL·기계 SERVER_LLM)으로 재구성해 라벨 의미를 docs 로 보여준다
- 출처 미상(도입 전 null)·기계(SERVER)·타인 수기·내 수기 네 버전을 시딩해 source·editedByMe 매핑을 항목별로 단언
- 기계·출처 미상 버전의 editedByMe 는 null(응답에서 부재)임을 doesNotExist 로 고정
@m-a-king m-a-king added the feat 외부 가시적 새 기능 label Jul 31, 2026
@m-a-king m-a-king self-assigned this Jul 31, 2026
@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro Plus

Run ID: 5276eb4b-ff78-4889-b322-67289c82501b

📥 Commits

Reviewing files that changed from the base of the PR and between 0d47706 and 5c0b260.

📒 Files selected for processing (4)
  • src/main/kotlin/com/depromeet/piki/wishlist/controller/WishlistApiExamples.kt
  • src/main/kotlin/com/depromeet/piki/wishlist/controller/WishlistController.kt
  • src/main/kotlin/com/depromeet/piki/wishlist/controller/dto/WishPriceHistoryResponse.kt
  • src/test/kotlin/com/depromeet/piki/wishlist/controller/WishPriceHistoryIntegrationTest.kt

Walkthrough

가격 히스토리 응답에 스냅샷 출처와 수기 수정자의 본인 여부를 추가했습니다. 컨트롤러는 요청자 ID를 전달하고, 통합 테스트와 API 예시가 서버·수기·LLM 출처를 검증하도록 갱신되었습니다.

Changes

가격 히스토리 출처 및 수정자 정보

Layer / File(s) Summary
응답 출처 및 수정자 매핑
src/main/kotlin/com/depromeet/piki/wishlist/controller/WishlistController.kt, src/main/kotlin/com/depromeet/piki/wishlist/controller/dto/WishPriceHistoryResponse.kt
요청자 ID를 가격 이력 응답 생성에 전달하고, 각 항목에 source와 수기 수정자의 editedByMe를 매핑합니다.
응답 검증 및 API 예시 갱신
src/test/kotlin/com/depromeet/piki/wishlist/controller/WishPriceHistoryIntegrationTest.kt, src/main/kotlin/com/depromeet/piki/wishlist/controller/WishlistApiExamples.kt
출처가 없는 항목, 서버 추출 항목, 타인·본인 수기 수정 항목을 검증하고 API 예시에 출처별 필드를 반영합니다.

Estimated code review effort: 3 (Moderate) | ~20 minutes

🚥 Pre-merge checks | ✅ 1 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 40.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/825-history-source-labels

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.

@github-actions

Copy link
Copy Markdown

Discord 스레드 연동용 메타데이터입니다. discord-pr-bot 워크플로가 자동 생성하며, 수정·삭제하면 PR 과 Discord 알림 연동이 끊깁니다.

@m-a-king

Copy link
Copy Markdown
Collaborator Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@m-a-king
m-a-king merged commit 4a47992 into dev Jul 31, 2026
11 checks passed
@m-a-king
m-a-king deleted the feat/825-history-source-labels branch July 31, 2026 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat 외부 가시적 새 기능

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant