Skip to content

Conversation

@LeeCh0129
Copy link

@LeeCh0129 LeeCh0129 commented Jun 20, 2025

📌 변경 사항 개요

React key 중복 경고와 401 인증 오류 해결

✨ 요약

  • React key 중복으로 인한 경고 해결
  • 401 인증 오류 해결

📝 상세 내용

1. React Key 중복 문제 해결

  • 문제: Sidebar와 MyDashboardGrid에서 동일한 dashboard.id를 key로 사용하여 충돌 발생
  • 해결: 각 컴포넌트별 고유 prefix 적용
    • Sidebar: key={sidebar-${dashboard.id}}
    • MyDashboardGrid: key={mydash-${dashboard.id}}

2. 401 인증 오류 해결

  • 문제: fetchColumns, fetchCards에서 testAxios 사용으로 인증 -> 토큰 누락
  • 해결: authHttpClient로 변경하여 자동 토큰 추가
    • fetchColumns.ts: testAxios → authHttpClient
    • fetchCards.ts: testAxios → authHttpClient

🔗 관련 이슈

🖼️ 스크린샷

✅ 체크리스트

  • 브랜치 네이밍 컨벤션을 준수했습니다
  • 커밋 컨벤션을 준수했습니다
  • 코드가 프로젝트의 스타일 가이드라인을 준수합니다

💡 참고 사항

Summary by CodeRabbit

  • Style

    • 대시보드 카드와 사이드바 항목의 React key 값이 각각 "mydash-" 및 "sidebar-"로 id 앞에 접두사가 추가되어 일관된 key 형식으로 변경되었습니다.
  • Chores

    • 내부 API 클라이언트 import가 테스트용 인스턴스에서 표준 인증 인스턴스로 정리되었습니다.

@LeeCh0129 LeeCh0129 added this to the 2차 구현 기간 milestone Jun 20, 2025
@LeeCh0129 LeeCh0129 self-assigned this Jun 20, 2025
@LeeCh0129 LeeCh0129 added the 🐛Fix 버그 수정 label Jun 20, 2025
@coderabbitai
Copy link

coderabbitai bot commented Jun 20, 2025

Walkthrough

API 클라이언트의 import가 테스트용 Axios 인스턴스에서 인증된 표준 Axios 인스턴스로 변경되었습니다. 또한, 대시보드 및 사이드바에서 React key prop이 단순 id에서 접두사가 포함된 문자열로 수정되었습니다. 코드의 논리나 기능에는 다른 변경이 없습니다.

Changes

파일/경로 변경 요약
.../api/fetchCards.ts, .../api/fetchColumns.ts API 클라이언트 import를 testAxios에서 authHttpClient로 변경, 주석 제거
.../MyDashboardGrid/MyDashboardGrid.tsx, .../sidebar/Sidebar.tsx React key prop을 id에서 접두사가 포함된 문자열로 변경

Possibly related PRs

  • CoPlay-FE/coplan#37: fetchCards.ts, fetchColumns.ts의 API 클라이언트 사용과 관련된 PR로, 데이터 fetching 모듈의 도메인이 유사함.
  • CoPlay-FE/coplan#42: Sidebar 및 DashboardItem 컴포넌트 정의와 관련, 본 PR은 이 컴포넌트의 key prop 사용을 수정함.
  • CoPlay-FE/coplan#60: Sidebar.tsx에서 key prop 변경과 관련, 해당 PR에서는 Sidebar의 API 연동 및 상태관리를 도입함.

Suggested reviewers

  • Insung-Jo

Poem

🐇
키에 접두사, axios로 교체,
대시보드와 사이드바도 새 옷을 입네.
숫자 대신 문자열로,
렌더링은 더 깔끔하게!
토끼는 깡충, 코드도 깔끔—
오늘도 변화에 귀를 쫑긋 세우네.
🥕

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

npm error Exit handler never called!
npm error This is an error with npm itself. Please report this error at:
npm error https://github.com/npm/cli/issues
npm error A complete log of this run can be found in: /.npm/_logs/2025-06-20T17_34_53_086Z-debug-0.log


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 955e40b and c377596.

📒 Files selected for processing (2)
  • src/app/features/dashboard_Id/api/fetchCards.ts (1 hunks)
  • src/app/features/dashboard_Id/api/fetchColumns.ts (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • src/app/features/dashboard_Id/api/fetchCards.ts
  • src/app/features/dashboard_Id/api/fetchColumns.ts
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: eslint-check
✨ Finishing Touches
  • 📝 Generate Docstrings

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@Insung-Jo Insung-Jo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다! 빠르게 머지 하시고 다음 작업으로 넘어가시죠 👍

@LeeCh0129 LeeCh0129 merged commit e36f495 into develop Jun 21, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐛Fix 버그 수정

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants