-
Notifications
You must be signed in to change notification settings - Fork 0
[Hotfix] Release에서 발생하던 문제 해결 및 3.1.8 릴리즈 #418
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Summary of ChangesHello @PeraSite, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! 이 풀 리퀘스트는 최근 릴리즈에서 발생한 두 가지 주요 문제를 해결하는 핫픽스입니다. Proguard 규칙의 불일치와 Gson의 TypeToken 사용 시 제네릭 정보 손실로 인한 런타임 오류를 수정하여 애플리케이션의 안정성을 확보하고, 긴급하게 3.1.8 버전을 배포하기 위해 버전 정보를 업데이트했습니다. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
이 PR은 릴리즈 빌드에서 발생하던 두 가지 중요한 문제를 해결합니다. 첫째, DTO 클래스의 패키지 경로 변경 후 업데이트되지 않았던 Proguard 규칙을 수정하여 R8/Proguard에 의해 클래스가 난독화되는 것을 방지합니다. 둘째, Firebase Remote Config에서 JSON을 파싱할 때 TypeToken 사용으로 인해 발생하던 IllegalStateException을 Array<T>::class.java를 사용하도록 변경하여 해결했습니다. 또한, 핫픽스 릴리즈를 위해 앱 버전을 3.1.8로 업데이트했습니다. 전반적으로 변경 사항들은 설명된 문제를 정확히 해결하는 것으로 보이며, 안정성을 높이는 중요한 수정입니다. 다만, JSON 파싱 시 발생할 수 있는 NPE 가능성에 대한 리뷰 의견을 하나 남겼습니다.
| val gson = Gson() | ||
| val listType = object : TypeToken<List<RestaurantInfo>>() {}.type | ||
| val dtoList: List<RestaurantInfo> = gson.fromJson(json, listType) | ||
| val dtoList = gson.fromJson(json, Array<RestaurantInfo>::class.java) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gson.fromJson은 JSON 문자열이 "null"일 경우 null을 반환할 수 있습니다. 이 경우 dtoList가 null이 되어 다음 줄의 dtoList.map 호출 시 NullPointerException이 발생할 수 있습니다. try-catch 블록이 이 예외를 처리하겠지만, null을 명시적으로 처리하는 것이 더 안전하고 코드의 의도를 명확하게 합니다. Elvis 연산자(?:)를 사용하여 null일 경우 빈 배열을 반환하도록 수정하는 것을 권장합니다.
| val dtoList = gson.fromJson(json, Array<RestaurantInfo>::class.java) | |
| val dtoList = gson.fromJson(json, Array<RestaurantInfo>::class.java) ?: emptyArray() |
| -keep class com.eatssu.android.data.dto.** { | ||
| *; | ||
| } | ||
| -keep class com.eatssu.android.data.enums.** { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이거 enum core 모듈에 있는데 이거는 따로 안해도 문제 없는건가요??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
놓쳤나해서 확인해보니 core 모듈의 enum은 com.eatssu.common.enums 에요!
지운건 core 분리 리팩토링 이전에 있던 com.eatssu.android.data.enums 니까 영향 없을 것 같아용
릴리즈 빌드해서 기능 정상 작동하는 것도 확인했어요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
굿입니다~👍
HI-JIN2
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
굿굿
| -keep class com.eatssu.android.data.dto.** { | ||
| *; | ||
| } | ||
| -keep class com.eatssu.android.data.enums.** { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
굿입니다~👍
|
확인했습니다~! 수고하셨습니다!! |
* fix: DTO 파일 이동에 따른 Proguard Rule 수정 * fix: Generics 관련 정보가 유실되는 TypeToken 대신 Java Class 사용 * release: 3.1.8(46) * refactor: unused import 삭제 * fix: 제미니 대응
* feat: 제휴지도 학과/전체 토글 디폴트값 변경 및 토글 UI 위치 변경 * feat: PartnershipFilterToggle에서 toggleItem 생성방식 변경 및 UI수정, 불필요 코드 삭제 * delete: 사용하지 않는 위치 권한 코드 삭제 * feat: compose 라이브러리 버전 업데이트 * feat: compose router-screen 분리 * feat: 학과 선택을 하지 않은 경우, default 토글이 "전체"로 수정. 학과 토글 선택 시 바텀시트 보여주기 * feat: 제휴지도 학과/전체 토글 디폴트값 변경 및 토글 UI 위치 변경 * feat: PartnershipFilterToggle에서 toggleItem 생성방식 변경 및 UI수정, 불필요 코드 삭제 * delete: 사용하지 않는 위치 권한 코드 삭제 * feat: compose 라이브러리 버전 업데이트 * feat: compose router-screen 분리 * feat: 학과 선택을 하지 않은 경우, default 토글이 "전체"로 수정. 학과 토글 선택 시 바텀시트 보여주기 * feat: compose 버전 업데이트 롤백 * feat: 학과 정보가 업데이트될 때마다 토글 상태 없데이트하도록 key 변경 * feat: init 내부에서 전체 제휴정보 load하는 코드 제거(compose LaunchedEffect로 이동) * feat: BottomSheet 표시는 View의 SheetState로만 관리 (ViewModel은 데이터만 제공), 제휴정보, 학과 입력 바텀시트 상태 변수 분리 * feat: Domain 모델(RestaurantType)을 UI 모델(PlaceType)로 변환 로직을 뷰모델로 이동 * feat: 토글 필터 상태, 이벤트 로거를 ViewModel로 이동. departmentId, collegeId flow 방출로 수정 * [Hotfix] Release에서 발생하던 문제 해결 및 3.1.8 릴리즈 (#418) * fix: DTO 파일 이동에 따른 Proguard Rule 수정 * fix: Generics 관련 정보가 유실되는 TypeToken 대신 Java Class 사용 * release: 3.1.8(46) * refactor: unused import 삭제 * fix: 제미니 대응 * chore: material 의존성 제거 (#423) * feat: 코드 리뷰 반영 (네이밍 변경 및 scope 전달 -> 람다 전달로 수정, 최초 정보 load 시 state copy가 아닌 mapState 객체 생성 및 초기화) * feat: 제휴정보 토글 변경 시 선택했던 식당의 제휴정보 state 초기화 * feat: MapScreen 접근 제어자 private -> internal 변경 --------- Co-authored-by: 정제훈 <pretocki3@gmail.com> Co-authored-by: 유진 <qldls0307@naver.com>
Summary
https://eat-ssu.slack.com/archives/C0517NBULDR/p1764037363649059
에서 문제가 발생했습니다. 정확한 이유는 다음과 같습니다.
Describe your changes
Proguard Rule를 수정하고, Gson 사용 시 TypeToken이 아니라 Java Class를 사용하게 해 해결했습니다.
급히 3.1.8을 배포해야했으므로 3.1.8(48) 버전업 후 배포까지 이 브랜치에서 한번에 진행했습니다.
Issue
To reviewers