Skip to content

Concurrent Modification Exception on Android 10 #117

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

Closed
duocnguyen6799 opened this issue Dec 31, 2020 · 4 comments
Closed

Concurrent Modification Exception on Android 10 #117

duocnguyen6799 opened this issue Dec 31, 2020 · 4 comments

Comments

@duocnguyen6799
Copy link

duocnguyen6799 commented Dec 31, 2020

I used ParseLiveQuery SDK on version 1.1.0 and 1.2.2 . My app has been crashed like below.
image
Please help me! Thanks.

@duocnguyen6799 duocnguyen6799 changed the title Concurrent Modification Concurrent Modification Exception on Android 10 Dec 31, 2020
@mmimeault
Copy link
Contributor

Hello, could you please provide more information?

Stacktrace?
SDK version?
How to reproduce?

On my side, we are using the latest version intensively or many devices and we don't have that error.

Thanks

@duocnguyen6799
Copy link
Author

I have just updated the information on this issue.

@mmimeault
Copy link
Contributor

@duocnguyen6799 Issue is fixed now?

@mmimeault
Copy link
Contributor

Does make sense. The mCallbacks list is not thread safe.
Just realized I don't have this stack trace because I don't use registerListener nor unregisterListener.

Easy fix could be

  • to add synchronized,
  • or use a thread-safe version of the Array list (Collections.synchronizedList or CopyOnWriteArrayList)
  • or any other better suggestion.

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

2 participants