Notice
Recent Posts
Recent Comments
Link
«   2025/04   »
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30
Tags
more
Archives
Today
Total
관리 메뉴

Jack 오답노트

4년 전 플젝 버전 오류 정리 본문

android

4년 전 플젝 버전 오류 정리

기릿 2021. 4. 21. 10:44

1. The given artifact contains a string literal with a package reference 'android.support.v4.content' that cannot be safely rewritten. Libraries using reflection such as annotation processors need to be updated manually to add support for androidx.

버터나이프 오류

 

implementation 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'  --> 10.1.0 으로 바꿔준다.

 

 

2. Unknown host 'smm'. You may need to adjust the proxy settings in Gradle.
Enable Gradle 'offline mode' and sync project
Learn about configuring HTTP proxies in Gradle

 

implementation 'com.smm.lib:smmlib:1.4'

그래들 버전 올리고, jcenter 앞에 maven 오게 해보고 프록시 오토 설정해봐도 안된다..

 

알고보니 내부망 접근 라이브러리였돠.. -->jar 파일로 넣었다

 

3. 파이어베이스에서 400 배드 리퀘스트를 토해낸다.

E/FirebaseInstanceId: Token retrieval failed: INVALID_SENDER

E/FirebaseRemoteConfig: Fetch failed! Server responded with an error.

"API key not valid. Please pass a valid API key."

 

--> google-services.json 파일 누락, 클린앤 리빌드 

--> 또 에러남. google 라이브러리 업데이트, firebase 관련 라이브러리 업데이트

--> 업데이트하면서 remote config 메소드 변경으로 빨간줄 폭탄.. 

--> 수정후 run 하니 E/OneSignal: Error Getting FCM Token / 원시그널 에러

--> 릴리즈 버전으로 빌드 했다.

 

4. 웹뷰 err_cleartext_not_permitted

타겟 버전을 30으로 올렸더니 http 때문에 안된다.

android:usesCleartextTraffic="true" 매니페스트 어플리케이션 안에 추가

 

5. Could not get unknown property 'config' for type com.google.gms.googleservices.GoogleServicesPlugin$GoogleServicesPluginConfig

--> 앱 그래들의 classpath 'gradle.plugin.com.onesignal:onesignal-gradle-plugin:0.12.3' 부분 버전 고침

 

6. androidx 적용하다가 오류난 모든 파일 임포트 고치고..

butterknife의 Utils.arrayFilteringNull 이 없어져서 빨간줄 뜬다.

--> array 된 뷰들 다 따로 빼서 바인드 처리했다,,,

 

7. targetSdk 28에서 30으로 올린 후 29인 기기에서 미디어 폴더가 보이지 않는 현상

--> android Q 로 올라가면서 scoped storage 관련 이슈 developer.android.com/about/versions/11/privacy/storage?hl=ko 참고

매니페스트에 android:requestLegacyExternalStorage="true" 추가

 

8. onesignal 베타서버를 릴리즈주소로 바꾸고 파이어베이스도 릴리즈로 연결. 그리고 google-service.json 파일을 넣고 돌림.

E/FirebaseInstanceId: Token retrieval failed: SERVICE_NOT_AVAILABLE

W/FirebaseRemoteConfig: No value of type 'String' exists for parameter key 'validate_version'.

validate_version에서 아무것도 가져오지 않는다.

--> avd에서 cold boot 를 시키고 프로젝트 클린해도 안고쳐짐

 

8-1. E/FirebaseInstanceId: Token retrieval failed: INVALID_SENDER

"code": 400,
        "message": "API key not valid. Please pass a valid API key.",

파이어베이스 서버에서 에러남,,, googleservice도 바꿨는데 이상

 

9. 플레이 스토어에서 리젝을 당했다. HostnameVerifier - Your app(s) are using an unsafe implementation of the HostnameVerifier interface. You can find more information about how resolve the issue in this Google Help Center article.

--> 프로젝트에서 HttpsURLConnection.setHostnameVerifier(new HostnameVerifier()~~ 이 부분 verify를 찾아서 return true로 돼있는 부분을 stackoverflow.com/questions/40928435/google-play-security-alert-your-app-is-using-an-unsafe-implementation-of-the-h/41393328#41393328 이렇게 바꿔준다

나는 아예 setHostnameVerifier 코드를 삭제했더니 기능에 문제도 없고 검토도 통과했다

'android' 카테고리의 다른 글

databinding build 에러  (0) 2021.11.16
Execution failed for task ':app:kaptDebugKotlin'  (0) 2021.10.06
소셜로그인 정리  (0) 2021.07.30
머테리얼 디자인 요약  (0) 2021.04.27
사이드 프로젝트 중 오류  (0) 2021.04.22
Comments