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

inconsistent null value in dart:js #20305

Closed
sigmundch opened this issue Jul 31, 2014 · 15 comments
Closed

inconsistent null value in dart:js #20305

sigmundch opened this issue Jul 31, 2014 · 15 comments
Assignees
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-js P1 A high priority bug; for example, a single project is unusable or has many test failures
Milestone

Comments

@sigmundch
Copy link
Member

The dart:js library behaves differently in Dartium or dart2js when sending a null value. In Dartium, the value is sent as 'null'. In dart2js it is sent as undefined.

They should be consistent.

Here is a sample test:

    import 'dart:js';
    
    main() {
      context['console'].callMethod('log', [null]);
    }

Whether they should be null or undefined, is a good question. I have a use case where I'd prefer for it to be null, but there might be cases suggesting the opposite.

Alternatively, there should be an option in dart:js to choose one or the other.

@sigmundch
Copy link
Member Author

fix on its way: https://codereview.chromium.org/437733002/


Added Started label.

@sigmundch
Copy link
Member Author

r38814


Added Fixed label.

@sigmundch
Copy link
Member Author

Issue #20280 has been merged into this issue.

2 similar comments
@sigmundch
Copy link
Member Author

Issue #20280 has been merged into this issue.

@sigmundch
Copy link
Member Author

Issue #20280 has been merged into this issue.

@DartBot
Copy link

DartBot commented Aug 4, 2014

This comment was originally written by [email protected]


Eagerly awaiting a fix here. This bug means I simply can't build my app. Even with the workaround mentioned in https://code.google.com/p/dart/issues/detail?id=20280, it remains broke on Safari. And all I did was upgrade to the newly released Polymer.

@sigmundch
Copy link
Member Author

Issue #20336 has been merged into this issue.

@sigmundch
Copy link
Member Author

Issue #20280 has been merged into this issue.

@sigmundch
Copy link
Member Author

Issue #19591 has been merged into this issue.

@DartBot
Copy link

DartBot commented Aug 4, 2014

This comment was originally written by [email protected]


Is the best way to know when a new SDK is released to monitor https://gsdview.appspot.com/dart-archive/channels/dev/raw/latest/sdk/ for a more recent timestamp?

@sigmundch
Copy link
Member Author

probably you want to look at https://gsdview.appspot.com/dart-archive/channels/dev/release/latest/sdk/

('release' instead of 'raw')

There are very similar, except that 'raw' contains any build we make, 'release' are the ones that we send out after validating that all tests pass. The editor auto-upgrades when a new SDK is out on 'release'.

The latest 'raw' already has the fix for this specific bug. I expect it will get promoted as 'released' very soon.

@DartBot
Copy link

DartBot commented Aug 4, 2014

This comment was originally written by [email protected]


Noted. And grrr... w/ the raw or even release of dev, pub build fails with:

Can't read 'package:woven/config/config.dart' (Could not find asset woven|lib/config/config.dart.).
import 'package:woven/config/config.dart';

Did something change with respect to package imports?

@sethladd
Copy link
Contributor

Set owner to @sigmundch.

@sigmundch
Copy link
Member Author

Hey Dave - sorry for not getting back to you earlier on the config.dart issue. It sounds like a bug, but it's not obvious to me what's going on (it could be in our transformers, or in pub itselfs, hard to say).

If you haven't already, please file a separate bug for it.

@DartBot
Copy link

DartBot commented Aug 14, 2014

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-js P1 A high priority bug; for example, a single project is unusable or has many test failures
Projects
None yet
Development

No branches or pull requests

3 participants