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

Cannot find name 'Zone' #448

Closed
oliverschenk opened this issue Mar 21, 2016 · 5 comments
Closed

Cannot find name 'Zone' #448

oliverschenk opened this issue Mar 21, 2016 · 5 comments

Comments

@oliverschenk
Copy link

I'm using Atom text editor with the TypeScript plugin installed. It will generally complain if it can't resolve an object due to missing typings or otherwise.

I'm using Atom as a text editor and the polyfills.ts file is giving me various errors:

Cannot find name 'Zone', at line 54
Cannot find name 'TaskData', at line 75
Cannot find name 'Task', at line 89 and 96

It also doesn't like:

isPeriodic: nameSuffix == 'Interval',

var task: Task = args[0];

The website works fine and no errors in the console.

This is after cloning this project and making no modifications other than "npm install".

@oliverschenk
Copy link
Author

I just noticed the "tslink: disable" and "enable" ... I'm not assuming that these are not actually errors but rather just my editor being confused.

@akaztp
Copy link

akaztp commented Mar 21, 2016

I'm having these errors when I run the e2e tests.

@felix307253927
Copy link

Error: TSError: ⨯ Unable to compile TypeScript
node_modules/zone.js/lib/browser/property-descriptor.ts (73,19): Cannot find name 'Zone'. (2304)
node_modules/zone.js/lib/browser/register-element.ts (24,32): Cannot find name 'Zone'. (2304)
node_modules/zone.js/lib/browser/register-element.ts (27,40): Cannot find name 'Zone'. (2304)
node_modules/zone.js/lib/browser/register-element.ts (30,38): Cannot find name 'Zone'. (2304)
...
...

@chatman-media
Copy link

Same thing after update

webpack: bundle is now VALID.
[default] Checking started in a separate process...
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/property-descriptor.ts (73,24):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/register-element.ts (24,37):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/register-element.ts (27,45):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/register-element.ts (30,43):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/utils.ts (15,22):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/utils.ts (192,25):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/utils.ts (201,8):
    Property 'scheduleEventTask' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/utils.ts (214,20):
    Property 'cancelTask' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/browser/utils.ts (262,54):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (122,11):
    Duplicate identifier 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (484,5):
    Duplicate identifier 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (485,9):
    Class 'Zone' incorrectly implements interface 'Zone'.
  Property 'bind' is missing in type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (489,48):
    Type 'Zone' is not assignable to type 'Zone'.
  Property 'bind' is missing in type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (492,47):
    Type 'Zone' is not assignable to type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (568,11):
    Operator '!=' cannot be applied to types 'Zone' and 'this'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (570,23):
    Property 'name' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (596,11):
    Argument of type 'ZoneTask' is not assignable to parameter of type 'Task'.
  Types of property 'zone' are incompatible.
    Type 'Zone' is not assignable to type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (603,11):
    Argument of type 'ZoneTask' is not assignable to parameter of type 'Task'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (610,11):
    Argument of type 'ZoneTask' is not assignable to parameter of type 'Task'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (620,9):
    Class 'ZoneDelegate' incorrectly implements interface 'ZoneDelegate'.
  Types of property 'zone' are incompatible.
    Type 'Zone' is not assignable to type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (683,33):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
  Types of property 'zone' are incompatible.
    Type 'Zone' is not assignable to type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (689,43):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (697,37):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (703,47):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (710,54):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (729,47):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (741,50):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (755,59):
    Argument of type 'ZoneDelegate' is not assignable to parameter of type 'ZoneDelegate'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (785,9):
    Class 'ZoneTask' incorrectly implements interface 'Task'.
  Types of property 'zone' are incompatible.
    Type 'Zone' is not assignable to type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (808,31):
    Argument of type 'this' is not assignable to parameter of type 'Task'.
  Type 'ZoneTask' is not assignable to type 'Task'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (873,23):
    Property 'runTask' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (885,39):
    Property 'runGuarded' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/node_modules/zone.js/lib/zone.ts (976,10):
    Property 'scheduleMicroTask' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/src/polyfills.ts (54,19):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/src/polyfills.ts (105,23):
    Property 'current' does not exist on type 'typeof Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/src/polyfills.ts (122,17):
    Property 'cancelTask' does not exist on type 'Zone'.
[default] /Users/alder/Projects/_apps/my_finances/angular-frontend/typings/browser/ambient/zone.js/zone.js.d.ts (9,15):
    Duplicate identifier 'Zone'.

@PatrickJS
Copy link
Owner

the latest changes should fix this. if you still have the issue please reopen. thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants