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

dart2js compiler crashes when compiling deferred libraries #17110

Closed
pavelgj opened this issue Feb 25, 2014 · 13 comments
Closed

dart2js compiler crashes when compiling deferred libraries #17110

pavelgj opened this issue Feb 25, 2014 · 13 comments
Assignees
Labels
P1 A high priority bug; for example, a single project is unusable or has many test failures web-dart2js

Comments

@pavelgj
Copy link

pavelgj commented Feb 25, 2014

web/web_sandbox.dart:1:1: Error: The compiler crashed when compiling this element.
//@Injectables(const[Profiler, RootScope, AstParser])

The compiler is broken.

When compiling the above element, the compiler crashed. It is not
possible to tell if this is caused by a problem in your program or
not. Regardless, the compiler should not crash.

The Dart team would greatly appreciate if you would take a moment to
report this problem at http://dartbug.com/new.

Please include the following information:

* the name and version of your operating system,

* the Dart SDK build number (1.2.0-dev.5.15), and

* the entire message you see here (including the full stack trace
  below as well as the source location above).

The compiler crashed: The null object does not have a getter 'implementation'.

NoSuchMethodError : method not found: 'implementation'
Receiver: null
Arguments: []

­0 Object.noSuchMethod (dart:core-patch/object_patch.dart:45)

­1 DeferredLoadTask.outputUnitForElement (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/deferred_load.dart:145)

­2 CodeEmitterTask.computeNeededClasses (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart:1168)

­3 CodeEmitterTask.assembleProgram.<anonymous closure> (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart:1267)

­4 CompilerTask.measure (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/compiler.dart:1623)

­5 CodeEmitterTask.assembleProgram (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart:1262)

­6 JavaScriptBackend.assembleProgram (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/js_backend/backend.dart:1197)

­7 Compiler.compileLoadedLibraries (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/compiler.dart:1128)

­8 Compiler.runCompiler.<anonymous closure> (file:///Volumes/data/b/build/slave/dart-editor-mac-dev/build/dart/sdk/lib/_internal/compiler/implementation/compiler.dart:1008)

­9 _rootRunUnary (dart:async/zone.dart:717)

­10 _RootZone.runUnary (dart:async/zone.dart:854)

­11 _Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:439)

­12 _Future._propagateToListeners (dart:async/future_impl.dart:522)

­13 _Future._complete (dart:async/future_impl.dart:303)

­14 Future.forEach.nextElement (dart:async/future.dart:286)

­15 _rootRunUnary (dart:async/zone.dart:717)

­16 _RootZone.runUnary (dart:async/zone.dart:854)

­17 _Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:439)

­18 _Future._propagateToListeners (dart:async/future_impl.dart:522)

­19 _Future._complete (dart:async/future_impl.dart:303)

­20 _Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:354)

­21 _asyncRunCallbackLoop (dart:async/schedule_microtask.dart:23)

­22 _asyncRunCallback (dart:async/schedule_microtask.dart:32)

­23 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:119)

@sigmundch
Copy link
Member

cc @floitschG.
cc @sigurdm.
Removed Priority-Unassigned label.
Added Priority-High, Area-Dart2JS, Triaged labels.

@pavelgj
Copy link
Author

pavelgj commented Feb 25, 2014

Steps to reproduce:
git clone https://github.com/pavelgj/angular_deferred_sample.git
cd angular_deferred_sample/
pub get
pub build

dart --version
Dart VM version: 1.2.0-dev.5.15 (Mon Feb 24 02:12:58 2014) on "macos_x64"

@pavelgj
Copy link
Author

pavelgj commented Feb 25, 2014

I was playing around with @­MirrorsUsed and it seems like if I add @­MirrorsUsed to the deferred libraries the error goes away, but it doesn't split the code... it's all one big chunk: pavelgj/angular_deferred_sample@87dce09

How do mirrors affect code splitting?

@pavelgj
Copy link
Author

pavelgj commented Feb 25, 2014

False alarm, the error is still there. I think I just accidentally ran it with stable sdk.

@sigurdm
Copy link
Contributor

sigurdm commented Feb 27, 2014

Thanks for the report.
It is a bug in the way deferred loading handles annotations.
I almost have a fix: https://codereview.chromium.org/180843012/.


Added Started label.

@sigurdm
Copy link
Contributor

sigurdm commented Feb 27, 2014

Set owner to @sigurdm.

@karlklose
Copy link
Contributor

Issue #17887 has been merged into this issue.

@dgrove
Copy link
Contributor

dgrove commented Apr 23, 2014

any updates on this?

@sigurdm
Copy link
Contributor

sigurdm commented Apr 23, 2014

Yes - It should be fixed by https://codereview.chromium.org/180843012/ I forgot to mark it. Can you confirm?


Added Fixed label.

@pavelgj
Copy link
Author

pavelgj commented May 7, 2014

No, still seeing the error... very similar stacktrace but different line numbers (sending via email).

@floitschG
Copy link
Contributor

Added Triaged label.

@sigurdm
Copy link
Contributor

sigurdm commented May 8, 2014

Added Accepted label.

@sigurdm
Copy link
Contributor

sigurdm commented May 23, 2014

Added Fixed label.

@pavelgj pavelgj added Type-Defect P1 A high priority bug; for example, a single project is unusable or has many test failures web-dart2js labels May 23, 2014
This issue was closed.
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 web-dart2js
Projects
None yet
Development

No branches or pull requests

6 participants