-
Notifications
You must be signed in to change notification settings - Fork 65
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
Code generation causes InconsistentAnalysisException with multiple targets #198
Labels
Comments
This PR uses the workaround from dart-lang/build#2634 to eliminate the inconsistency. |
This was referenced Sep 11, 2020
eernstg
added a commit
that referenced
this issue
Sep 28, 2020
This PR changes reflectable to to obtain a fresh resolved library at each invocation of `getResolvedLibraryByElement`, thus eliminating the `InconsistentAnalysisException` which was reported in #198 and dart-lang/build#2634.
Finally closing this one: Resolved by #220! |
eernstg
added a commit
that referenced
this issue
Dec 1, 2020
eernstg
added a commit
that referenced
this issue
Dec 3, 2020
Update analyzer dependency to allow all versions until 0.41.1. Issue #227 reports that 'lib/main.dart' is skipped during code generation; this PR fixes that. Issue #198 about InconsistentAnalysisException re-emerged with analyzer 0.40.5, workaround from google/built_value.dart#941 adopted. This PR also adds // @Dart=2.9 to tests, because they do not get the language version from the pubspec.yaml. Prepare for publishing as 2.2.9.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following commands show that reflectable currently fails to generate code when dependencies have been fully updated (
pub upgrade
):This causes a number of failures like this:
However, it only seems to affect code generation in the case where there are multiple targets, that is, when code generation occurs for multiple separate entry points ("programs").
We do not yet know why this happens, but it may be caused by some changes in the way the build related packages give notifications to the analyzer about changed files, cf. dart-lang/build#2634.
The text was updated successfully, but these errors were encountered: