Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Customize Error Message
Search
magiepooh
June 22, 2017
Technology
0
780
Customize Error Message
Customize Error Message for Android
How to catch Uncaught Exception.
magiepooh
June 22, 2017
Tweet
Share
More Decks by magiepooh
See All by magiepooh
今さら角丸のTransition
magiepooh
0
1.1k
Google I/O Extended Tokyo 2018
magiepooh
2
1.5k
APIのデータのマッピングを 約18倍速くした話
magiepooh
2
930
まだAPI定義管理で消耗してるの?〜Swaggerを用いた大規模アプリ時代のAPI定義管理とコードジェネレート〜
magiepooh
38
18k
RootBeer
magiepooh
0
780
Kotlin入門
magiepooh
2
1.7k
Adjust Full Screen
magiepooh
2
470
How to get size of NavigationBar and StatusBar
magiepooh
1
1.6k
How to detect phone call
magiepooh
0
1.6k
Other Decks in Technology
See All in Technology
Lexical Analysis
shigashiyama
1
150
The Rise of LLMOps
asei
7
1.7k
強いチームと開発生産性
onk
PRO
35
11k
AWS Lambda のトラブルシュートをしていて思うこと
kazzpapa3
2
180
CDCL による厳密解法を採用した MILP ソルバー
imai448
3
140
Terraform Stacks入門 #HashiTalks
msato
0
360
B2B SaaSから見た最近のC#/.NETの進化
sansantech
PRO
0
890
rootlessコンテナのすゝめ - 研究室サーバーでもできる安全なコンテナ管理
kitsuya0828
3
390
ExaDB-D dbaascli で出来ること
oracle4engineer
PRO
0
3.9k
Platform Engineering for Software Developers and Architects
syntasso
1
520
エンジニア人生の拡張性を高める 「探索型キャリア設計」の提案
tenshoku_draft
1
130
リンクアンドモチベーション ソフトウェアエンジニア向け紹介資料 / Introduction to Link and Motivation for Software Engineers
lmi
4
300k
Featured
See All Featured
Why Our Code Smells
bkeepers
PRO
334
57k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.1k
Thoughts on Productivity
jonyablonski
67
4.3k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
506
140k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
Building Your Own Lightsaber
phodgson
103
6.1k
RailsConf 2023
tenderlove
29
900
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
47
2.1k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
126
18k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
420
A Modern Web Designer's Workflow
chriscoyier
693
190k
Transcript
Customize Error Message @magie_pooh shibuya.apk #16
ࣗݾհ ౻ాୖຏ @magie_pooh @magiepooh
Customize Error Message @magie_pooh shibuya.apk #16
Crash Reporting Tool • Crashlytics • Firebase Crash Reporting •
Play Console
Crash Reporting Tool • Crashlytics • Firebase Crash Reporting •
Play Console
None
͜͜ΛΧελϚΠζ͍ͨ͠
None
None
None
ফ͍ͨ͠
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
private static Thread.UncaughtExceptionHandler defaultUEH; private static Thread.UncaughtExceptionHandler caughtExceptionHandler = new
Thread.UncaughtExceptionHandler() { @TargetApi(Build.VERSION_CODES.KITKAT) @Override public void uncaughtException(Thread thread, Throwable throwable) { // do something defaultUEH.uncaughtException(thread, throwable); } }; @Override public void onCreate() { super.onCreate(); Fabric.with(this, new Crashlytics()); defaultUEH = Thread.getDefaultUncaughtExceptionHandler(); Thread.setDefaultUncaughtExceptionHandler(caughtExceptionHandler); } ApplicationΫϥε
Field field = Throwable.class .getDeclaredField("detailMessage"); field.setAccessible(true); field.set(throwable, ""); ExceptionͷϝοηʔδΛͻͨ͢Βফ͢
ফ͑ͨʂʂʂ
CrashlyticsͷΈ • Fabric.with(this, new Crashlytics());
CrashlyticsͷΈ • Fabric.with(this, new Crashlytics()); • CrashlyticsCore#onPreExecute()Ͱ CrashlyticsControllerΛੜ
CrashlyticsͷΈ • Fabric.with(this, new Crashlytics()); • CrashlyticsCore#onPreExecute()Ͱ CrashlyticsControllerΛੜ • CrashlyticsControllerΫϥεͰ
CrashlyticsUncaughtExceptionHandlerΛੜ
·ͱΊ • UncaughtExceptionHandlerΛ͑ΧελϚΠζͰ͖Δ • ଞͷCrash Reporting ToolະௐࠪͳͷͰɺͲͳ͔ͨڭ͑ ͍ͯͩ͘͞ • Firebase
Crash ReportingͰݸਓใʹؔΘΔ෦ ʮREDACTED_PERSONAL_IDENTIFICATION_NUMBER ʯʹͳΔΒ͍͠ɻ୭͔ڭ͍͑ͯͩ͘͞