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

Error on ContactsService.getContacts() #71

Closed
michael-georgiadis opened this issue Jan 21, 2020 · 8 comments
Closed

Error on ContactsService.getContacts() #71

michael-georgiadis opened this issue Jan 21, 2020 · 8 comments

Comments

@michael-georgiadis
Copy link

When i try to get the contacts, while they do arrive when the future ends, the single property of the iterable contains an exception, which includes this message.

"BadState: Too many elements".

The interesting thing is that if i don't use it in a widget it still throws that error. But if disable the uncaught and all exceptions of vscode then it manages to return the Iterable just fine.

image

@ZmanElete
Copy link

I am having this issue aswell. Any Ideas on how to fix it?

@mayank99
Copy link

mayank99 commented Apr 22, 2020

This is definitely still an issue.

@lukasgit Let me know if you need more details but #49209 on flutter has all the details.

@lukasgit
Copy link
Owner

@funnyman420 @ZmanElete @mayank99 the plugin has recently been updated. Please try again using the latest version 0.4.2

@mayank99
Copy link

mayank99 commented Apr 22, 2020

Just tried it on 0.4.2 (I was running 0.4.1 during my original comment). Same uncaught exception when calling ContactsService.getContacts.

ArgumentError (Invalid argument(s) (input): Must not be null)

@michael-georgiadis
Copy link
Author

And if you make another project with the same code, it will work just fine. I don't think that this is some issue with the plugin. It has more likely to do with dart itself. But, unfortunately they closed my issue because they think that the plugin has the bug.

@lukasgit
Copy link
Owner

@mayank99 can you confirm what @funnyman420 said, that if when you make another project with the same code it works?

@lukasgit lukasgit added the in review The issue or pull request is in review label Apr 22, 2020
@mayank99
Copy link

I got the same exception on a different project.

One thing to note is that the exception only shows up when the "All Exceptions" box is checked. And if you uncheck that box, the app works [seemingly] fine. So I also do believe the problem has to do with dart/flutter not this plugin.
image

@lukasgit
Copy link
Owner

@mayank99 @funnyman420 please file a new issue with Dart team here and Flutter team here

@lukasgit lukasgit removed the in review The issue or pull request is in review label Apr 26, 2020
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