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

[Bug]: InconsistentAnalysisException when generating model #879

Closed
Navil opened this issue Sep 3, 2022 · 5 comments · Fixed by #932
Closed

[Bug]: InconsistentAnalysisException when generating model #879

Navil opened this issue Sep 3, 2022 · 5 comments · Fixed by #932

Comments

@Navil
Copy link

Navil commented Sep 3, 2022

What happened?

When running
flutter pub run realm generate

the command fails and I get "[SEVERE]" logs. This happens on two independend machines. Restarting the computer occassionally helps. The other files/steps run as usual. This error did not happen in the past and did also occur before upgrading Flutter to 3.3.0.

Repro steps

flutter pub run realm generate

Version

Flutter (Channel stable, 3.3.0, on macOS 12.5.1 21G83 darwin-x64, locale en-GB)

What Realm SDK flavor are you using?

MongoDB Atlas (i.e. Sync, auth, functions)

What type of application is this?

Flutter Application

Client OS and version

0.4.0+beta

Code snippets

No response

Stacktrace of the exception/crash you're getting

No response

Relevant log output

[INFO] realm:realm_generator on lib/shared/util/date_helper.dart:[generate (0)] completed, took 3ms
[SEVERE] realm:realm_generator on lib/shared/util/date_helper.dart:

InconsistentAnalysisException: Requested result might be inconsistent with previously returned results

[INFO] 29.3s elapsed, 1/16 actions completed.
[INFO] realm:realm_generator on lib/shared/util/country_select.dart:[generate (0)] completed, took 129ms
[INFO] realm:realm_generator on lib/shared/util/custom_alert.dart:[generate (0)] completed, took 57ms
[INFO] realm:realm_generator on lib/shared/util/custom_route.dart:[generate (0)] completed, took 112μs
[SEVERE] realm:realm_generator on lib/shared/util/custom_route.dart:

InconsistentAnalysisException: Requested result might be inconsistent with previously returned results

[INFO] 31.5s elapsed, 4/20 actions completed.
[INFO] realm:realm_generator on lib/firebase_options.dart:[generate (0)] completed, took 61μs
[SEVERE] realm:realm_generator on lib/firebase_options.dart:

InconsistentAnalysisException: Requested result might be inconsistent with previously returned results

[INFO] 33.3s elapsed, 5/21 actions completed.
@nielsenko
Copy link
Contributor

Hi Thomas

If you check the pubspec.lock on the two machines in question. What analyzer package are they using?

@Navil
Copy link
Author

Navil commented Sep 6, 2022

Hi Thomas

If you check the pubspec.lock on the two machines in question. What analyzer package are they using?

analyzer:
    dependency: transitive
    description:
      name: analyzer
      url: "https://pub.dartlang.org"
    source: hosted
    version: "4.6.0"

@nielsenko
Copy link
Contributor

We see this issue on our CI as well from time to time. Fx:
https://github.com/realm/realm-dart/runs/8274059582?check_suite_focus=true,
but I have yet to re-create it on my own machine.

It seems less frequent after upgrading analyzer to 4.7.0, so you may try upgrading, but it still occurs. We need to investigate more. so If you have any more observations to share, they are much appreciated.

@sync-by-unito sync-by-unito bot added the Waiting-For-Reporter Waiting for more information from the reporter before we can proceed label Sep 12, 2022
@Navil
Copy link
Author

Navil commented Sep 12, 2022

I just updated to 4.7.0 and experienced the same issue on my first try. But I can give an update if a few days if I feel that it got less. Tried with the --clean flag. Same issue. But the files however generate, so I can "ignore" the error for now.

@github-actions github-actions bot added Needs-Attention Reporter has responded. Review comment. and removed Waiting-For-Reporter Waiting for more information from the reporter before we can proceed labels Sep 12, 2022
@sync-by-unito sync-by-unito bot removed the Needs-Attention Reporter has responded. Review comment. label Sep 12, 2022
@nielsenko
Copy link
Contributor

@Navil Fix just released with 0.5.0+beta

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants