Skip to content
This repository was archived by the owner on Dec 19, 2017. It is now read-only.

pub build producing broken output for elements including scripts and JavaScript components #257

Closed
DartBot opened this issue Jun 5, 2015 · 2 comments

Comments

@DartBot
Copy link

DartBot commented Jun 5, 2015

Originally opened as dart-lang/sdk#20336

This issue was originally filed by [email protected]


What steps will reproduce the problem?

  1. Create a project with a Polymer dependency with version ">=0.12.0" and paper_elements (I believe any JavaScript Polymer element will do)
  2. Create an element like the attached file
  3. Add it to an index file
  4. Run pub build
  5. Open the file and see that it does not work.

What is the expected output? What do you see instead?
I would expect to see the Polymer element correctly displayed.
Instead, the element is not displayed and I see an exception: Uncaught TypeError: Cannot read property 'element' of undefined on line 446 of isolate_helper.dart.

Please include the following information:

  • Dart SDK version: 1.6.0-dev.6.0
  • polymer package version: 0.12.0
  • Operating system: Manjaro Linux
  • Browser (if any): Chrome 36.0.1985.125 / Dartium 36.0.1985.97

Anything else?
It works with a Polymer dependency of ">=0.11.0 <0.12.0".
If you do not add a script to the element, the element will be displayed.


Attachments:
my-element.html (629 Bytes)
index.html (553 Bytes)
pubspec.yaml (177 Bytes)

@DartBot
Copy link
Author

DartBot commented Jun 5, 2015

<img src="https://avatars.githubusercontent.com/u/984921?v=3" align="left" width="48" height="48"hspace="10"> Comment by jakemac53


I wasn't able to get a repro on this, can you run a 'pub upgrade' and confirm it's still an issue for you in 0.12.0+6?

If you are still having the issue then if you could attach a zip/tar file of a project containing the repro that would be great, thanks!


Set owner to @jakemac53.
Removed Priority-Unassigned label.
Added Priority-High, Accepted labels.

@DartBot
Copy link
Author

DartBot commented Jun 5, 2015

<img src="https://avatars.githubusercontent.com/u/2049220?v=3" align="left" width="48" height="48"hspace="10"> Comment by sigmundch


Thanks for the bug report. We recently submitted a fix for this bug, but the fix is part of the SDK, so it wont be available until we release 1.6.0-dev.7.0 (which I expect will be by tomorrow if all goes well). I think Jake wasn't able to repro because he has a pre-release version of 1.6.0-dev.7.0 locally.

The issue was a bug in how the "dart:js" was being compiled by dart2js (issue dart-lang/sdk#20305). If you need to get past this issue before the new SDK is released, there is a longer discussion and some workarounds described in issue #254.

Cheers!


Added Duplicate label.
Marked as being merged into dart-lang/sdk#20305.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

2 participants