Skip to content

[ICC-250] SSE 구조 변경#135

Merged
GulSauce merged 19 commits intodevelopfrom
ICC-250-edit-sse
Feb 9, 2026
Merged

[ICC-250] SSE 구조 변경#135
GulSauce merged 19 commits intodevelopfrom
ICC-250-edit-sse

Conversation

@GulSauce
Copy link
Member

@GulSauce GulSauce commented Feb 4, 2026

Summary by CodeRabbit

  • 새로운 기능

    • 하단 푸터 추가(개인정보처리방침·문의 링크 포함)
    • 퀴즈 준비 전용 흐름 추가(파일 업로드·페이지 선택·옵션 UI)
  • 개선 사항

    • 문제 생성이 세션 기반 스트리밍으로 변경되어 대기 메시지 및 재연결 안정성 향상
    • 준비/생성/풀이 상태와 액션이 그룹화되어 UI 사용 흐름이 더 일관됨
    • 퀴즈 옵션·이력·업로드 정보의 로컬 복원성(만료 기반) 개선
  • 버그 수정

    • 파일 변환 타임아웃을 분리하여 사용자에게 명확한 알림 제공
  • 스타일

    • 코드 포맷터(Prettier) 도입으로 문자열 표기 일관화(사용자 영향 없음)

@coderabbitai
Copy link

coderabbitai bot commented Feb 4, 2026

Important

Review skipped

Auto reviews are disabled on this repository. 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.

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

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.
  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

prepare-quiz 모듈과 훅들 추가, 기존 useMakeQuiz 제거 및 MakeQuiz 페이지가 usePrepareQuiz로 전환됨. 퀴즈 생성 스토어를 sessionId 기반 EventSource 스트리밍으로 재설계하고 solve-quiz 훅을 서브훅으로 분해해 state/actions 네임스페이스화함. quizHistoryStorage 삭제·로컬 저장 통합, Footer 컴포넌트 추가, Prettier 도입 및 전역 포맷 정리.

Changes

Cohort / File(s) Summary
포매터·빌드 설정
/.prettierrc, eslint.config.js, package.json, /.github/PULL_REQUEST_TEMPLATE.md
Prettier 설정 추가, eslint-config-prettier 통합, 관련 devDependencies 추가, PR 템플릿 체크리스트 포맷 수정.
전역 포맷/문자열 정리
index.html, vite.config.js, .github/workflows/prod_deploy.yml, src/**/*.{js,jsx,css}, src/shared/i18n/*
쌍따옴표→홑따옴표, CSS/JS 재포맷 및 트레일링 뉴라인 추가 등 스타일 일관화(주로 무의미한 포맷 변경).
새 기능: prepare-quiz 모듈
src/features/prepare-quiz/*, src/features/prepare-quiz/index.js
파일 업로더(FileConversionTimeoutError 포함), usePrepareQuiz 및 서브훅들(usePrepareQuizUpload/Options/Pages/Ui), 상수와 재수출 추가.
MakeQuiz → PrepareQuiz 전환
src/pages/make-quiz/index.jsx, src/pages/make-quiz/index.css, src/features/make-quiz/*
페이지가 usePrepareQuiz 사용으로 전환됨. 기존 useMakeQuiz 제거; 상태/액션이 그룹화된 네임스페이스로 변경. CSS에 .wait-message-note 추가 및 .footer 블록 제거.
퀴즈 생성 스토어 재설계
src/features/quiz-generation/model/useQuizGenerationStore.js
persist(만료) 적용, sessionId 기반 EventSource 스트리밍 도입, 스트림 수명주기·재연결·타이머·UI 플래그 추가, 공개 API(예: generateQuestions, reconnectStream)와 저장 필드 변경.
solve-quiz 분해 및 네임스페이스화
src/features/solve-quiz/model/*, src/pages/solve-quiz/index.jsx
useSolveQuiz를 서브훅(useSolveQuizData/Question/Submit/Timer)으로 분해하고 반환 형태를 { state: { quiz }, actions: { quiz } } 네임스페이스로 변경.
quiz-explanation 훅/페이지 리팩터링
src/features/quiz-explanation/*, src/pages/quiz-explanation/*
PDF 옵션 상수화, 훅 반환 구조를 중첩 그룹(state.quiz/pdf/explanation/ui + actions 그룹)으로 재구성; 소비부도 이에 맞게 수정.
퀴즈 히스토리 저장 이동
src/shared/lib/quizHistoryStorage.js, src/features/quiz-history/model/useQuizHistory.js, src/pages/quiz-history/*
quizHistoryStorage 모듈 삭제, 히스토리 읽기/쓰기 로직을 useQuizHistory 내부(localStorage)로 통합; 훅 시그니처에 currentLanguage 추가.
공용 유틸·위젯 추가/변경
src/widgets/footer/*, src/widgets/header/*, src/widgets/help/*, src/widgets/recent-changes/*
Footer 컴포넌트와 스타일 추가, Header에 closeSidebar 액션 추가, Help/Header 리팩터링 및 스타일·문구 포맷 정리.
앱 진입·루트 일부 삭제/조정
src/App.jsx (삭제), src/app/*
앱 부트스트랩 파일(src/App.jsx) 제거; PageView 트래커 등 관련 포맷·경로 정리.
기타 변경/삭제
src/shared/lib/quizHistoryStorage.js (삭제), src/features/make-quiz/model/constants.js (삭제)
오래된 make-quiz 상수/훅 삭제 및 해당 re-export 제거, 관련 참조가 prepare-quiz로 마이그레이션.

Sequence Diagram(s)

sequenceDiagram
    participant User as 사용자
    participant UI as MakeQuiz UI
    participant Prepare as usePrepareQuiz
    participant Upload as FileUploader
    participant GenStore as useQuizGenerationStore
    participant Server as 서버
    participant SSE as EventSource

    User->>UI: 파일 선택 및 옵션 설정
    UI->>Prepare: 업로드/옵션/페이지 업데이트
    Prepare->>Upload: 업로드 위임 (pre-sign, PUT)
    Upload->>Server: 파일 업로드 요청
    Server-->>Upload: 업로드 완료, 업로드 URL 반환
    Upload->>GenStore: uploadedUrl 및 fileInfo 저장

    User->>UI: generateQuestions 호출
    UI->>Prepare: generateQuestions 전달
    Prepare->>GenStore: 스트리밍 시작 요청 (sessionId 생성)
    GenStore->>Server: 생성 시작 요청 (sessionId 포함)
    Server-->>SSE: SSE 스트리밍 시작
    SSE-->>GenStore: 청크 이벤트 전송
    GenStore->>GenStore: 청크 누적 및 상태 업데이트
    SSE-->>GenStore: 완료 이벤트
    GenStore->>UI: 생성 완료 상태 반영 / 내비게이션 트리거
    UI-->>User: 퀴즈 풀이 화면으로 이동
Loading

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

Possibly related PRs

Poem

🐇 당근 주머니에 코드를 넣고 춤췄어요
훅들이 줄지어 정리되고 파일은 하늘로 날아가요
이벤트가 졸졸, 세션 따라 문제들이 피어나고
Footer 아래 토끼가 깡충, 배포 준비 끝났다고 웃어요
모두 함께 당근 축배를 들어요 🥕✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PR 제목은 SSE 구조 변경이라는 주요 변경사항을 명확히 반영하고 있으며, 전체 변경사항의 핵심을 잘 요약하고 있습니다.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch ICC-250-edit-sse

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.

coderabbitai[bot]

This comment was marked as outdated.

coderabbitai[bot]

This comment was marked as outdated.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as outdated.

coderabbitai[bot]

This comment was marked as off-topic.

coderabbitai[bot]

This comment was marked as off-topic.

@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@q-asker q-asker deleted a comment from coderabbitai bot Feb 9, 2026
@GulSauce GulSauce merged commit 3b703f7 into develop Feb 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant