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

Fatal Exception: java.util.ConcurrentModificationException #342

Closed
anbarasuthresnathan opened this issue Sep 22, 2016 · 3 comments
Closed

Comments

@anbarasuthresnathan
Copy link

anbarasuthresnathan commented Sep 22, 2016

I am getting the below mentioned error frequently while I am using in the application and I am using the version io.socket:socket.io-client:0.7.0.

Fatal Exception: java.util.ConcurrentModificationException
at java.util.ArrayList$ArrayListIterator.next(ArrayList.java:573)
at java.util.AbstractCollection.toString(AbstractCollection.java:372)
at org.json.JSONStringer.value(JSONStringer.java:252)
at org.json.JSONObject.writeTo(JSONObject.java:720)
at org.json.JSONStringer.value(JSONStringer.java:237)
at org.json.JSONObject.writeTo(JSONObject.java:720)
at org.json.JSONStringer.value(JSONStringer.java:237)
at org.json.JSONArray.writeTo(JSONArray.java:613)
at org.json.JSONArray.toString(JSONArray.java:585)
at java.lang.StringBuilder.append(StringBuilder.java:202)
at io.socket.parser.Parser$Encoder.encodeAsString(Parser.java:116)
at io.socket.parser.Parser$Encoder.encode(Parser.java:85)
at io.socket.client.Manager.packet(Manager.java:461)
at io.socket.client.Socket.packet(Socket.java:264)
at io.socket.client.Socket.access$1100(Socket.java:19)
at io.socket.client.Socket$5.run(Socket.java:201)
at io.socket.thread.EventThread$2.run(EventThread.java:75)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
at java.lang.Thread.run(Thread.java:818)

@mishasrb
Copy link

Hi @anbarasuthresnathan, were you able to fix this? I'm getting the same error in 1.0.0...

@darrachequesne
Copy link
Member

Closed due to inactivity, please reopen if needed.

@malik082009
Copy link

malik082009 commented May 18, 2022

I faced similar issue
Fatal Exception: java.util.ConcurrentModificationException at java.util.LinkedHashMap$LinkedHashIterator.nextNode(LinkedHashMap.java:757) at java.util.LinkedHashMap$LinkedKeyIterator.next(LinkedHashMap.java:780) at io.socket.hasbinary.HasBinary._hasBinary(HasBinary.java:47) at io.socket.hasbinary.HasBinary._hasBinary(HasBinary.java:39) at io.socket.hasbinary.HasBinary.hasBinary(HasBinary.java:18) at io.socket.parser.IOParser$Encoder.encode(IOParser.java:27) at io.socket.client.Manager.packet(Manager.java:412) at io.socket.client.Socket.packet(Socket.java:230) at io.socket.client.Socket.access$1000(Socket.java:18) at io.socket.client.Socket$6.run(Socket.java:219) at io.socket.thread.EventThread.exec(EventThread.java:55) at io.socket.client.Socket.emit(Socket.java:198) at io.socket.client.Socket$5.run(Socket.java:183) at io.socket.thread.EventThread$2.run(EventThread.java:80) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:923)

   I am using:
   `implementation('io.socket:socket.io-client:2.0.1') {
    exclude group: 'org.json', module: 'json'
}`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants