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

Stack overflow w/ angular_ast at 0.4.0-alpha+2 #138

Closed
kevmoo opened this issue Nov 21, 2017 · 13 comments
Closed

Stack overflow w/ angular_ast at 0.4.0-alpha+2 #138

kevmoo opened this issue Nov 21, 2017 · 13 comments
Assignees
Labels
P1 A high priority bug; for example, a single project is unusable or has many test failures status-blocked Blocked from making progress by another (referenced) issue type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)

Comments

@kevmoo
Copy link
Member

kevmoo commented Nov 21, 2017

dart --checked bin/main.dart angular_ast 0.4.0-alpha+2
SEVERE     Error scanning direct librariers
           Stack Overflow
           #0      _HashMap.putIfAbsent (dart:collection-patch/dart:collection/collection_patch.dart:130)
           #1      CacheEntry.getResultData (package:analyzer/src/context/cache.dart:423:23)
           #2      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart:800:27)
           #3      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #4      _HashFieldBase&_HashBase&_OperatorEqualsAndHashCode&SetMixin.forEach (dart:collection/set.dart:145)
           #5      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart:808:31)
           #6      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #7      _HashFieldBase&_HashBase&_OperatorEqualsAndHashCode&SetMixin.forEach (dart:collection/set.dart:145)
           #8      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart:808:31)
           #9      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #10     _HashFieldBase&_HashBase&_OperatorEqualsAndHashCode&SetMixin.forEach (dart:collection/set.dart:145)
           ...
           ...
           #13660  _RootZone.runUnary (dart:async/zone.dart:1379)
           #13661  _FutureListener.handleValue (dart:async/future_impl.dart:129)
           #13662  _Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:635)
           #13663  _Future._propagateToListeners (dart:async/future_impl.dart:664)
           #13664  _Future._completeWithValue (dart:async/future_impl.dart:477)
           #13665  _Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:509)
           #13666  _microtaskLoop (dart:async/schedule_microtask.dart:41)
           #13667  _startMicrotaskLoop (dart:async/schedule_microtask.dart:50)
           #13668  _runPendingImmediateCallback (dart:isolate-patch/dart:isolate/isolate_patch.dart:111)
           #13669  _RawReceivePortImpl._handleMessage (dart:isolate-patch/dart:isolate/isolate_patch.dart:164)
INFO       Scanning transitive dependencies...
SEVERE     Error scanning transitive librariers
           Stack Overflow
           #0      _HashMap.putIfAbsent (dart:collection-patch/dart:collection/collection_patch.dart:130)
           #1      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart:423:23)
           #2      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #3      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           #4      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #5      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           #6      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #7      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           #8      CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #9      CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           #10     CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #11     CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           #12     CacheEntry._setErrorState.<anonymous closure> (package:analyzer/src/context/cache.dart:813:17)
           #13     CacheEntry._setErrorState (package:analyzer/src/context/cache.dart)
           ...
           ...
           #9053   _RootZone.runUnary (dart:async/zone.dart:1379)
           #9054   _FutureListener.handleValue (dart:async/future_impl.dart:129)
           #9055   _Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:635)
           #9056   _Future._propagateToListeners (dart:async/future_impl.dart:664)
           #9057   _Future._completeWithValue (dart:async/future_impl.dart:477)
           #9058   _Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:509)
           #9059   _microtaskLoop (dart:async/schedule_microtask.dart:41)
           #9060   _startMicrotaskLoop (dart:async/schedule_microtask.dart:50)
           #9061   _runPendingImmediateCallback (dart:isolate-patch/dart:isolate/isolate_patch.dart:111)
           #9062   _RawReceivePortImpl._handleMessage (dart:isolate-patch/dart:isolate/isolate_patch.dart:164)
INFO       Analyzing package...
@kevmoo kevmoo added P1 A high priority bug; for example, a single project is unusable or has many test failures type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) labels Nov 21, 2017
@kevmoo
Copy link
Member Author

kevmoo commented Nov 21, 2017

CC @isoos

@kevmoo
Copy link
Member Author

kevmoo commented Nov 21, 2017

Likely a pkg/analyzer issue – keeping this for tracking

@kevmoo
Copy link
Member Author

kevmoo commented Nov 21, 2017

Ran against pkg/analyzer (and front_end and kernel) from dart-lang/sdk@5b95582

No issue.

Wondering if this is something that has been fixed...

@kevmoo
Copy link
Member Author

kevmoo commented Nov 27, 2017

Also w/ pkg/linter @ 0.1.39

@isoos
Copy link
Collaborator

isoos commented Nov 27, 2017

Also w/ pkg/linter

Also gets fixed with the bleeding edge SDK?

@kevmoo
Copy link
Member Author

kevmoo commented Nov 27, 2017

Also gets fixed with the bleeding edge SDK?

Not sure.

@isoos
Copy link
Collaborator

isoos commented Nov 28, 2017

I the linter's case there was something in-between 0.1.34 and 0.1.35 that triggers the error.

@isoos
Copy link
Collaborator

isoos commented Nov 28, 2017

It looks like analyzer goes into a cycle here: https://github.com/dart-lang/sdk/blob/master/pkg/analyzer/lib/src/context/cache.dart#L812

Probably the cache entry's dependent results go into a cycle, which may be valid, but it is not guarded for re-entry there. What is the best way to get a change accepted there?

@kevmoo
Copy link
Member Author

kevmoo commented Nov 28, 2017

@isoos So I checked 3 packages w/ pana @ master and then using the latest alpha analyzer

Fixes 2 out of three.

We'd have to wire up a dependency_override on the production deployment. Thoughts?

+
+dependency_overrides:
+  analyzer: 0.31.0-alpha.2

stack overflow
dart bin/main.dart angular_analyzer_plugin

  • fixed!

AnalysisException: Cannot compute LIBRARY_ELEMENT
dart bin/main.dart dart2ts

  • fixed!

AnalysisException: Element mismatch
dart bin/main.dart jsonx

  • still broken! @ jsonx v2.0.2

@isoos
Copy link
Collaborator

isoos commented Nov 28, 2017

can't we just depend on the 0.31.0-alpha.2 directly?

@kevmoo
Copy link
Member Author

kevmoo commented Nov 28, 2017

It'll blow up w/ a dependency conflict w/ pkg/test

Need to use a dependency override

kevmoo added a commit to dart-lang/pub-dev that referenced this issue Nov 30, 2017
kevmoo added a commit to dart-lang/pub-dev that referenced this issue Nov 30, 2017
* Latest dependencies – include appengine update for improved trace logging

* Use alpha pkg/analyzer to improve analysis robustness

Related to dart-lang/pana#138
@kevmoo kevmoo added the status-blocked Blocked from making progress by another (referenced) issue label Dec 10, 2017
@kevmoo
Copy link
Member Author

kevmoo commented Dec 10, 2017

Can't do anything until we can publish a version that depends on a ^0.31.0 gold release of analyzer.

@isoos
Copy link
Collaborator

isoos commented Feb 16, 2018

Closing this here, as the pubspec.yaml is already updated (although not yet published).

@isoos isoos closed this as completed Feb 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P1 A high priority bug; for example, a single project is unusable or has many test failures status-blocked Blocked from making progress by another (referenced) issue type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)
Projects
None yet
Development

No branches or pull requests

2 participants