Skip to content

[#558] 프로젝트의 Sendable 경고를 약하게 보도록 수정한다#559

Merged
opficdev merged 5 commits into
developfrom
chore/#558-sendable
Jun 8, 2026
Merged

[#558] 프로젝트의 Sendable 경고를 약하게 보도록 수정한다#559
opficdev merged 5 commits into
developfrom
chore/#558-sendable

Conversation

@opficdev

@opficdev opficdev commented Jun 8, 2026

Copy link
Copy Markdown
Owner

🔗 연관된 이슈

🎯 의도

  • 프로젝트의 Sendable 경고 대응을 강한 strict concurrency 설정이나 전역 Sendable 채택으로 처리하지 않고, 현재 기본 설정과 기존 동작 흐름에 맞추기 위함
  • PR #541에서 추가된 Sendable 대응 구현물을 제거해 wrapper, lock, session 분리로 인한 동작 변경 가능성을 줄이기 위함

📝 작업 내용

📌 요약

  • Tuist 공통 설정에서 SWIFT_STRICT_CONCURRENCY 강제 설정 제거
  • TodoMutationEventBusAsyncStream 기반에서 Combine 기반으로 변경
  • HomeViewCoordinator의 구독 관리를 Set<AnyCancellable> 기반으로 정리
  • PR #541에서 추가된 Sendable, @Sendable, @unchecked Sendable 채택 및 관련 wrapper 제거

🔍 상세

  • Project+Settings.swift에서 SWIFT_STRICT_CONCURRENCY = complete 제거
  • TodoMutationEventBus 프로토콜을 publish / observe 구조로 변경
  • TodoMutationEventBusImplPassthroughSubject 기반 구현으로 변경
  • TodoRepositoryImpl의 mutation event 발행에서 불필요한 await 제거
  • HomeViewCoordinator에서 AsyncStream Task 관리 제거
  • HomeViewCoordinatorcancellablesSet<AnyCancellable>로 통합
  • TodoMutationEventBusImplTests, TodoRepositoryImplTests를 Combine 계약에 맞게 수정
  • LoginFeature의 dependency closure에서 Sendable 요구 제거
  • Core, Domain, Data, Presentation, WidgetCore 타입과 프로토콜에 추가됐던 Sendable 채택 제거
  • AuthServiceImplAuthStatePublisher, NSLock 기반 분리 구조 제거
  • Firebase 서비스에서 FirebaseDependency wrapper 제거 후 Firebase 타입 직접 참조로 복구
  • Apple 로그인 흐름에서 AppleSignInSession 제거 후 delegate, continuation 직접 관리로 복구
  • Persistence, WidgetCore에서 UserDefaultsDependency wrapper 제거 후 UserDefaults 직접 참조로 복구

📸 영상 / 이미지 (Optional)

@opficdev opficdev self-assigned this Jun 8, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

이번 PR은 TodoMutationEventBusAsyncStream 기반에서 Combine의 PassthroughSubject 기반으로 변경하고, publish 메서드를 동기 메서드로 전환하여 레포지토리에서의 await 호출을 제거하였습니다. 이에 대해 리뷰어는 프로젝트의 기술 스택 방향성(Combine 배제 및 AsyncStream 지향)을 유지하면서도 동기식 발행을 안전하게 처리할 수 있도록, NSLock을 활용하여 AsyncStream 구조를 유지하는 대안을 제시하였습니다. 또한, final class로 변경된 구현체에서 멀티스레드 동기화 처리가 누락되어 발생할 수 있는 데이터 레이스 문제를 지적했습니다.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@opficdev

opficdev commented Jun 8, 2026

Copy link
Copy Markdown
Owner Author

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

이번 풀 리퀘스트는 프로젝트의 엄격한 동시성 검사 설정을 완화하고, FirebaseDependencyUserDefaultsDependency와 같은 래퍼 클래스들을 제거하여 네이티브 API를 직접 사용하도록 변경하였습니다. 또한, 이벤트 버스와 코디네이터의 비동기 스트림(AsyncStream, actor) 기반 설계를 Combine(PassthroughSubject, AnyPublisher) 방식으로 전환하였습니다. 리뷰에서는 이러한 변경 과정에서 발생한 동시성 제어 누락 문제를 지적하고 있습니다. 특히 AuthServiceImpl에서 NSLock이 제거되어 발생할 수 있는 데이터 레이스 위험과 WebPageImageStoreImpl에서 @Sendable 제약이 제거되어 발생할 수 있는 런타임 불안정성을 경고하며, 향후 Swift 6 마이그레이션을 위해 TodoMutationEventAuthProvider와 같이 안전한 값 타입들의 Sendable 채택을 유지할 것을 권장하고 있습니다.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread Application/DevLogInfra/Sources/Service/AuthServiceImpl.swift
Comment thread Application/DevLogPersistence/Sources/Persistence/WebPageImageStoreImpl.swift Outdated
Comment thread Application/DevLogDomain/Sources/Entity/TodoMutationEvent.swift
Comment thread Application/DevLogDomain/Sources/Entity/AuthProvider.swift
@opficdev opficdev merged commit 18dbd8b into develop Jun 8, 2026
5 checks passed
@opficdev opficdev deleted the chore/#558-sendable branch June 8, 2026 12:44
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.

프로젝트의 Sendable 경고를 약하게 보도록 수정한다

1 participant