본문 바로가기

전체 글68

Your anti-virus program might be impacting your build performance. 라고 뜰 때 https://stackoverflow.com/questions/58297667/your-anti-virus-program-might-be-impacting-your-build-performance-android-studi Your anti-virus program might be impacting your build performance. Android Studio checked the following directories: Your anti-virus program might be impacting your build performance. Android Studio checked the following directories: C:\Users\user.name\.AndroidStudio3.5\sy.. 2021. 7. 11.
java.net.ProtocolException: unexpected end of stream 미리 결론: 서버가 HTTP/1.0으로 응답해 발생했던 문제 1.1로 변경해서 해결됨. Retrofit 사용중에 간헐적으로 오류가 발생했다. 검색해보면 1. Connection: close 헤더를 추가하라거나 2. OkHttpClient.Builder에서 retryOnConnectionFailure를 true로 변경하라거나 3. 에뮬레이터에서만 발생하는 오류라거나 4. 그냥 OkHttp 자체의 버그이거나 5. 혹은 서버의 문제 라는 글들을 볼 수 있는데 1-3까지로는 해결되는게 없다. 4를 확인하기 위해 새 프로젝트를 만들어 UrlConnection을 사용해서 테스트를 했는데 같은 문제가 발생했다. 로그에서 OkHttp를 볼 수 있었어서 OkHttp 문제가 아니라는 것이 확인된 것은 아니지만, 프레임워크.. 2021. 5. 7.
코틀린 isEmpty와 isBlank 차이 자바에서는 isEmpty만 있어서 isBlank는 뭐가 다른가 궁금했는데, isEmpty는 "" 와 같이 완전히 비어있는 문자열인 경우 참이고, isBlank는 "", " ", "\n", "\t"와 같이 비어있거나 화이트 스페이스로만 이뤄진 경우에 참이다. 2021. 5. 2.
BillingClient의 launchBillingFlow에서 NullPointerException 며칠 전 안드로이드의 BillingClient 버전을 2.0.3에서 3.0.3으로 올렸는데 아래와 같은 오류가 발생했다. Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.content.Intent.getStringExtra(java.lang.String)' on a null object reference at com.android.billingclient.api.BillingClientImpl.launchBillingFlow(BillingClientImpl.java:48) at com.myapp.MainActivity$launchPurchaseFlow$1.onS.. 2021. 3. 25.