wenmingvs / logreport Goto Github PK
View Code? Open in Web Editor NEW崩溃日志上传框架
崩溃日志上传框架
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 256017 Thread Name: Thread-256017 2016-07-18 14:42:32:22 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
at android.os.Handler.(Handler.java:200)
at android.os.Handler.(Handler.java:114)
at android.widget.Toast$TN.(Toast.java:503)
at android.widget.Toast.(Toast.java:121)
at android.widget.Toast.makeText(Toast.java:306)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:84)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:106)
at com.wenming.library.upload.BaseUpload2$1.run(BaseUpload2.java:67)
at java.lang.Thread.run(Thread.java:818)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 265214 Thread Name: pool-1-thread-2 Time: 2016-07-20 15:47:51:55 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5197)
at android.view.View$PerformClick.run(View.java:20909)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 255992 Thread Name: Thread-255992 2016-07-18 14:41:52:00 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
at android.os.Handler.(Handler.java:200)
at android.os.Handler.(Handler.java:114)
at android.widget.Toast$TN.(Toast.java:503)
at android.widget.Toast.(Toast.java:121)
at android.widget.Toast.makeText(Toast.java:306)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:84)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:106)
at com.wenming.library.upload.BaseUpload2$1.run(BaseUpload2.java:67)
at java.lang.Thread.run(Thread.java:818)
发送的时候观察一下log,看下是否有报红色的library异常,在国产的中华酷联四个品牌的手机,会被精简掉一些关键的library,导致无法发送邮件的
原始邮件
发件人:刘鹏程[email protected]
收件人:wenmingvs@[email protected]
发送时间:2016年7月27日(周三) 09:58
主题:Re:回复:wenmingvs:您好,LogReport问题的求助
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人:刘鹏程[email protected]
收件人:[email protected]
发送时间:2016年7月27日(周三) 09:35
主题:wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : CrashCacheDemo
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Trd: 1 main 2016-07-16 19:16:58:75 Class: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5197)
at android.view.View$PerformClick.run(View.java:20909)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 1 Thread Name: main 2016-07-18 14:54:28:01 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5197)
at android.view.View$PerformClick.run(View.java:20909)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人:刘鹏程[email protected]
收件人:[email protected]
发送时间:2016年7月27日(周三) 09:35
主题:wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 10345 Thread Name: pool-3-thread-2 2016-07-18 17:15:38:94 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: unknown
BRAND: Xiaomi
DEVICE: gemini
HARDWARE: qcom
Thread ID: 44303 Thread Name: pool-1-thread-1 Time: 2016-07-25 15:19:33:63 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5200)
at android.view.View$PerformClick.run(View.java:21163)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5459)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:738)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:628)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 37697 Thread Name: pool-2-thread-1 Time: 2016-07-21 18:21:16:54 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 23369 Thread Name: pool-2-thread-1 Time: 2016-07-19 16:31:54:25 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: unknown
BRAND: Xiaomi
DEVICE: gemini
HARDWARE: qcom
Thread ID: 44303 Thread Name: pool-1-thread-1 Time: 2016-07-25 15:19:33:63 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5200)
at android.view.View$PerformClick.run(View.java:21163)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5459)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:738)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:628)
APPLICATION INFORMATION
Application : AndroidCrash
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
Board: msm8996
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
CPU_ABI: arm64-v8a
CPU_ABI2:
DEVICE: hero2qltechn
DISPLAY: MMB29M.G9350ZHU2APE3
FINGERPRINT: samsung/hero2qltezh/hero2qltechn:6.0.1/MMB29M/G9350ZHU2APE3:user/release-keys
HARDWARE: qcom
HOST: SWDD6217
ID: MMB29M
MANUFACTURER: samsung
PRODUCT: hero2qltezh
TAGS: release-keys
TYPE: user
USER: dpi
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 21068 Thread Name: pool-3-thread-1 Time: 2016-07-19 14:03:10:53 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 21563 Thread Name: pool-3-thread-2 Time: 2016-07-19 14:08:20:64 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 21916 Thread Name: pool-3-thread-1 Time: 2016-07-19 14:12:15:41 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 22077 Thread Name: pool-3-thread-2 Time: 2016-07-19 14:12:49:63 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 22364 Thread Name: pool-3-thread-1 Time: 2016-07-19 14:20:56:07 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 11336 Thread Name: pool-3-thread-2 2016-07-18 18:14:49:34 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
嗯嗯,明白,那我现在试一下。
在 2016-07-27 10:10:54,"wenmingvs" [email protected] 写道:
运行我的Demo,不要修改上面的帐号密码,看看是否能正常发送邮件,如果我的LogReport上有新的issue,说明你触发的崩溃是正常发送到邮箱,并且被自动提交到了GitHub上了。如果我的Demo是正常的,说明你的手机没有缺失关键的库,再排除后面的问题
原始邮件
发件人: 刘鹏程[email protected]
收件人: wenmingvs@[email protected]
发送时间: 2016年7月27日(周三) 09:58
主题: Re:回复:wenmingvs:您好,LogReport问题的求助
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人: 刘鹏程[email protected]
收件人: [email protected]
发送时间: 2016年7月27日(周三) 09:35
主题: wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 1 Thread Name: main 2016-07-18 15:26:31:46 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Unable to start service com.wenming.library.upload.UploadService@2532f74d with Intent { cmp=com.wenming.crashcachedemo/com.wenming.library.upload.UploadService }: java.lang.NullPointerException: Attempt to get length of null array
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3324)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Caused by: java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
... 9 more
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G6000ZCU2APE2
BRAND: samsung
DEVICE: o7ltechn
HARDWARE: qcom
Thread ID: 23180 Thread Name: pool-2-thread-1 Time: 2016-07-26 19:40:57:49 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5246)
at android.widget.TextView.performClick(TextView.java:10573)
at android.view.View$PerformClick.run(View.java:21256)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6918)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 10062 Thread Name: Thread-10062 2016-07-18 17:00:05:39 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 33395 Thread Name: pool-2-thread-1 Time: 2016-07-21 09:36:07:17 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G6000ZCU2APE2
BRAND: samsung
DEVICE: o7ltechn
HARDWARE: qcom
Thread ID: 23158 Thread Name: pool-2-thread-1 Time: 2016-07-26 18:24:34:48 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5246)
at android.widget.TextView.performClick(TextView.java:10573)
at android.view.View$PerformClick.run(View.java:21256)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6918)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人:刘鹏程[email protected]
收件人:[email protected]
发送时间:2016年7月27日(周三) 09:35
主题:wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
运行我的Demo,不要修改上面的帐号密码,看看是否能正常发送邮件,如果我的LogReport上有新的issue,说明你触发的崩溃是正常发送到邮箱,并且被自动提交到了GitHub上了。如果我的Demo是正常的,说明你的手机没有缺失关键的库,再排除后面的问题
原始邮件
发件人:刘鹏程[email protected]
收件人:wenmingvs@[email protected]
发送时间:2016年7月27日(周三) 09:58
主题:Re:回复:wenmingvs:您好,LogReport问题的求助
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人:刘鹏程[email protected]
收件人:[email protected]
发送时间:2016年7月27日(周三) 09:35
主题:wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G6000ZCU2APE2
BRAND: samsung
DEVICE: o7ltechn
HARDWARE: qcom
Thread ID: 23180 Thread Name: pool-2-thread-1 Time: 2016-07-26 19:40:57:49 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5246)
at android.widget.TextView.performClick(TextView.java:10573)
at android.view.View$PerformClick.run(View.java:21256)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6918)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 256007 Thread Name: Thread-256007 2016-07-18 14:42:12:20 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
at android.os.Handler.(Handler.java:200)
at android.os.Handler.(Handler.java:114)
at android.widget.Toast$TN.(Toast.java:503)
at android.widget.Toast.(Toast.java:121)
at android.widget.Toast.makeText(Toast.java:306)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:84)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:106)
at com.wenming.library.upload.BaseUpload2$1.run(BaseUpload2.java:67)
at java.lang.Thread.run(Thread.java:818)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 265214 Thread Name: pool-1-thread-2 Time: 2016-07-20 15:47:51:55 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5197)
at android.view.View$PerformClick.run(View.java:20909)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: unknown
BRAND: Xiaomi
DEVICE: gemini
HARDWARE: qcom
Thread ID: 44680 Thread Name: pool-1-thread-1 Time: 2016-07-25 15:53:44:58 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.folderSize(FileUtil.java:133)
at com.wenming.library.upload.UploadService.checkCacheSize(UploadService.java:109)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:90)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:101)
at com.wenming.library.upload.BaseUpload.sendFile(BaseUpload.java:53)
at com.wenming.library.upload.UploadService.onHandleIntent(UploadService.java:77)
at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:66)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.os.HandlerThread.run(HandlerThread.java:61)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 11526 Thread Name: pool-3-thread-2 2016-07-18 18:29:16:56 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 37432 Thread Name: pool-2-thread-1 Time: 2016-07-21 18:11:31:79 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 37603 Thread Name: pool-2-thread-2 Time: 2016-07-21 18:15:34:45 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 1 Thread Name: main 2016-07-18 15:26:05:44 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Unable to start service com.wenming.library.upload.UploadService@2532f74d with Intent { cmp=com.wenming.crashcachedemo/com.wenming.library.upload.UploadService }: java.lang.NullPointerException: Attempt to get length of null array
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3324)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Caused by: java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
... 9 more
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 18008 Thread Name: pool-3-thread-2 2016-07-19 10:58:00:22 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 18244 Thread Name: pool-3-thread-1 2016-07-19 10:58:16:65 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 18284 Thread Name: pool-3-thread-1 2016-07-19 11:13:14:45 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 18292 Thread Name: pool-3-thread-1 2016-07-19 11:16:53:63 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 18485 Thread Name: pool-3-thread-1 2016-07-19 11:17:16:00 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 18501 Thread Name: pool-3-thread-1 2016-07-19 11:19:23:95 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 18933 Thread Name: pool-3-thread-1 Time: 2016-07-19 11:53:31:32 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Thread ID: 19208 Thread Name: pool-3-thread-1 Time: 2016-07-19 11:56:06:18 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null object reference
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:105)
at com.wenming.library.upload.BaseUpload$1.run(BaseUpload.java:66)
at java.lang.Thread.run(Thread.java:818)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 1 Thread Name: main 2016-07-18 15:26:19:21 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Unable to start service com.wenming.library.upload.UploadService@2532f74d with Intent { cmp=com.wenming.crashcachedemo/com.wenming.library.upload.UploadService }: java.lang.NullPointerException: Attempt to get length of null array
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3324)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Caused by: java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
... 9 more
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:112)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 1 Thread Name: main 2016-07-18 15:35:10:18 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Unable to start service com.wenming.library.upload.UploadService@2532f74d with Intent { cmp=com.wenming.crashcachedemo/com.wenming.library.upload.UploadService }: java.lang.NullPointerException: Attempt to get length of null array
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3324)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Caused by: java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:111)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
... 9 more
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.findFiles(FileUtil.java:111)
at com.wenming.library.util.FileUtil.getCrashList(FileUtil.java:84)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:52)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3307)
at android.app.ActivityThread.access$2200(ActivityThread.java:177)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:5942)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 37432 Thread Name: pool-2-thread-1 Time: 2016-07-21 18:11:31:79 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 37603 Thread Name: pool-2-thread-2 Time: 2016-07-21 18:15:34:45 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 11498 Thread Name: pool-3-thread-2 2016-07-18 18:16:44:52 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:42)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : CrashCacheDemo
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Trd: 1 main 2016-07-17 23:15:40:39 Class: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:43)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 19412 Thread Name: pool-3-thread-1 Time: 2016-07-19 11:56:45:96 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 37697 Thread Name: pool-2-thread-1 Time: 2016-07-21 18:21:16:54 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: unknown
BRAND: Xiaomi
DEVICE: gemini
HARDWARE: qcom
Thread ID: 44680 Thread Name: pool-1-thread-1 Time: 2016-07-25 15:53:44:58 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.folderSize(FileUtil.java:133)
at com.wenming.library.upload.UploadService.checkCacheSize(UploadService.java:109)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:90)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:101)
at com.wenming.library.upload.BaseUpload.sendFile(BaseUpload.java:53)
at com.wenming.library.upload.UploadService.onHandleIntent(UploadService.java:77)
at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:66)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.os.HandlerThread.run(HandlerThread.java:61)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G6000ZCU2APE2
BRAND: samsung
DEVICE: o7ltechn
HARDWARE: qcom
Thread ID: 23158 Thread Name: pool-2-thread-1 Time: 2016-07-26 18:24:34:48 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:33)
at android.view.View.performClick(View.java:5246)
at android.widget.TextView.performClick(TextView.java:10573)
at android.view.View$PerformClick.run(View.java:21256)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6918)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人: 刘鹏程[email protected]
收件人: [email protected]
发送时间: 2016年7月27日(周三) 09:35
主题: wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 23369 Thread Name: pool-2-thread-1 Time: 2016-07-19 16:31:54:25 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: N9009KEU2GOH5
BRAND: samsung
DEVICE: hlte
HARDWARE: qcom
Thread ID: 255983 Thread Name: Thread-255983 2016-07-18 14:41:32:07 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
at android.os.Handler.(Handler.java:200)
at android.os.Handler.(Handler.java:114)
at android.widget.Toast$TN.(Toast.java:503)
at android.widget.Toast.(Toast.java:121)
at android.widget.Toast.makeText(Toast.java:306)
at com.wenming.library.upload.UploadService$1.onError(UploadService.java:84)
at com.wenming.library.upload.email.EmailReporter.sendReport(EmailReporter.java:106)
at com.wenming.library.upload.BaseUpload2$1.run(BaseUpload2.java:67)
at java.lang.Thread.run(Thread.java:818)
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 22729 Thread Name: pool-3-thread-1 Time: 2016-07-19 14:46:41:13 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.RuntimeException: Unable to start service com.wenming.library.upload.UploadService@afc00fc with Intent { cmp=com.wenming.crashcachedemo/com.wenming.library.upload.UploadService VirtualScreenParam=Params{mDisplayId=-1, null, mFlags=0x00000000)} }: java.lang.NullPointerException: Attempt to get length of null array
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:4079)
at android.app.ActivityThread.access$2400(ActivityThread.java:221)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1897)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Caused by: java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.folderSize(FileUtil.java:133)
at com.wenming.library.upload.UploadService.checkCacheSize(UploadService.java:110)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:55)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:4062)
... 9 more
java.lang.NullPointerException: Attempt to get length of null array
at com.wenming.library.util.FileUtil.folderSize(FileUtil.java:133)
at com.wenming.library.upload.UploadService.checkCacheSize(UploadService.java:110)
at com.wenming.library.upload.UploadService.onStartCommand(UploadService.java:55)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:4062)
at android.app.ActivityThread.access$2400(ActivityThread.java:221)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1897)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Application Information
App Name : LogReport
Version Code: 1
Version Name: 1.0
DEVICE INFORMATION
BOOTLOADER: G9350ZHU2APE3
BRAND: samsung
DEVICE: hero2qltechn
HARDWARE: qcom
Thread ID: 20529 Thread Name: pool-3-thread-2 Time: 2016-07-19 13:48:33:08 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
Thread ID: 20700 Thread Name: pool-3-thread-1 Time: 2016-07-19 13:51:32:73 FromClass: CrashHandler > ↓↓↓↓exception↓↓↓↓
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.length()' on a null object reference
at com.wenming.crashcachedemo.MainActivity$1.onClick(MainActivity.java:35)
at android.view.View.performClick(View.java:5697)
at android.widget.TextView.performClick(TextView.java:10816)
at android.view.View$PerformClick.run(View.java:22526)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:134)
嗯嗯,明白,那我现在试一下。
在 2016-07-27 10:10:54,"wenmingvs" [email protected] 写道:
运行我的Demo,不要修改上面的帐号密码,看看是否能正常发送邮件,如果我的LogReport上有新的issue,说明你触发的崩溃是正常发送到邮箱,并且被自动提交到了GitHub上了。如果我的Demo是正常的,说明你的手机没有缺失关键的库,再排除后面的问题
原始邮件
发件人: 刘鹏程[email protected]
收件人: wenmingvs@[email protected]
发送时间: 2016年7月27日(周三) 09:58
主题: Re:回复:wenmingvs:您好,LogReport问题的求助
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人: 刘鹏程[email protected]
收件人: [email protected]
发送时间: 2016年7月27日(周三) 09:35
主题: wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人: 刘鹏程[email protected]
收件人: [email protected]
发送时间: 2016年7月27日(周三) 09:35
主题: wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
发送的时候观察一下log,看下是否有报红色的library异常,在国产的中华酷联四个品牌的手机,会被精简掉一些关键的library,导致无法发送邮件的
原始邮件
发件人:刘鹏程[email protected]
收件人:wenmingvs@[email protected]
发送时间:2016年7月27日(周三) 09:58
主题:Re:回复:wenmingvs:您好,LogReport问题的求助
你好,这个邮箱是我的私人邮箱,不是我新申请的测试邮箱,所以密码不能发给你,希望你理解啊。
我把邮箱的设置相关的截图发给你好不好?感谢!
这是163邮箱的设置,客户端授权码也是我新设的为:lpc1992
另外:
程序跑在android手机上,网易邮箱大师在iphone上的,163邮箱和126邮箱使用的是同一个邮箱大师。
谢谢您!
在 2016-07-27 09:50:46,"wenmingvs" [email protected] 写道:
你好,我详细看了你的问题。能否告诉你的163的测试帐号的密码,我需要登录网易邮箱查看你的邮箱设置是否正确
原始邮件
发件人:刘鹏程[email protected]
收件人:[email protected]
发送时间:2016年7月27日(周三) 09:35
主题:wenmingvs:您好,LogReport问题的求助
wenmingvs:
你好,最近看到你在github上的LogReport这个项目,我自己按照你在README.md中步骤试了一下。
在本地写日志和记录奔溃都是可以的,在将日志发到邮箱时,没有收到,下面我将上传邮箱的那段代码发给你,麻烦你看一下,是不是配置问题:
下面是code:
private void initEmailReporter() {
EmailReporter email = new EmailReporter(this);
email.setReceiver("[email protected]"); //收件人
email.setSender("[email protected]"); //发送人邮箱
email.setSendPassword("lpc1992"); //邮箱的客户端授权码,注意不是邮箱密码
email.setSMTPHost("smtp.163.com"); //SMTP地址
email.setPort("465"); //SMTP 端口
LogReport.getInstance().setUploadType(email);
}
如果您有时间,看到这份邮件,希望你给予答复,万分感谢!!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.