Skip to content
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

ACRA incompatible with Cronet #1227

Closed
fabrantes opened this issue Jul 27, 2023 · 0 comments
Closed

ACRA incompatible with Cronet #1227

fabrantes opened this issue Jul 27, 2023 · 0 comments

Comments

@fabrantes
Copy link

Android 11
ACRA 7.8.4
cronet 106.5249.126

When using the Cronet HTTP library (which replaces the default URL class stream handler factory factory) ACRA fails sending the HTTP request with the following exception. Given Cronet's popularity this seems worth adding?

                org.acra.sender.ReportSenderException: Policy marked this task as incomplete. ACRA will try to send this report again.
                at org.acra.sender.ReportDistributor.sendCrashReport(Unknown Source:230)
                at org.acra.sender.ReportDistributor.distribute(Unknown Source:29)
                at org.acra.sender.SendingConductor.sendReports(Unknown Source:119)
                at org.acra.sender.JobSenderService.onStartJob$lambda-0(Unknown Source:26)
                at org.acra.sender.JobSenderService.a(Unknown Source:0)
                at org.acra.sender.a.run(Unknown Source:8)
                at java.lang.Thread.run(Thread.java:923)
                Caused by: org.acra.sender.ReportSenderException: Error while sending JSON report via Http POST
                at org.acra.sender.HttpSender.send(Unknown Source:195)
                at org.acra.sender.ReportSender.send(Unknown Source:15)
                at org.acra.sender.ReportDistributor.sendCrashReport(Unknown Source:66)
                ... 6 more
                Caused by: java.lang.IllegalStateException: Use setFixedLengthStreamingMode() or setChunkedStreamingMode() for writing after connect
                at xn.a.l(Unknown Source:95)
                at xn.a.write(SourceFile:5)
                at java.io.BufferedOutputStream.write(BufferedOutputStream.java:122)
                at java.io.FilterOutputStream.write(FilterOutputStream.java:103)
                at org.acra.http.DefaultHttpRequest.write(SourceFile:2)
                at org.acra.http.DefaultHttpRequest.write(SourceFile:1)
                at org.acra.http.BaseHttpRequest.writeContent(Unknown Source:60)
                at org.acra.http.BaseHttpRequest.send(Unknown Source:123)
                at org.acra.sender.HttpSender.sendWithoutAttachments(Unknown Source:56)
                at org.acra.sender.HttpSender.sendHttpRequests(Unknown Source:111)
                at org.acra.sender.HttpSender.send(Unknown Source:154)
                ... 8 more
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants