Universal: Updating to Angular 2.1.1 crashes Universal

Created on 21 Oct 2016  路  8Comments  路  Source: angular/universal

  • I'm submitting a ...
  • [x] bug report
  • What modules are related to this Issue?
  • [x] universal
  • What is the current behavior?
    If you update angular packages to 2.1.1 and start universal server, you will get the following error:
npm ERR!     /Users/qdouble/Sites/EXAMPLE_APPS/angular2webpack2-starter/npm-debug.log
/Users/qdouble/Sites/EXAMPLE_APPS/angular2webpack2-starter/node_modules/angular2-platform-node/__private_impor
ts__.js:19
exports.SelectorMatcher = compiler_1.__compiler_private__.SelectorMatcher;
                                                         ^

TypeError: Cannot read property 'SelectorMatcher' of undefined
    at Object.<anonymous> (/Users/qdouble/Sites/EXAMPLE_APPS/angular2webpack2-starter/node_modules/angular2-pl
atform-node/__private_imports__.js:19:58)
    at Module._compile (module.js:556:32)
    at Object.Module._extensions..js (module.js:565:10)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.require (module.js:483:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/qdouble/Sites/EXAMPLE_APPS/angular2webpack2-starter/node_modules/angular2-pl
atform-node/node-platform.js:9:28)
    at Module._compile (module.js:556:32)
  • Please tell us about your environment:
  • Angular version: 2.1.1
  • OS: [Mac OS X ]
  • Platform: [NodeJs]
urgent

Most helpful comment

@esakkikrishnan @Koslun 2.1.1 had some internal things from Core moved around.
If you need to use 2.1.1 now, either use the workaround or wait until we can update the official patch. (https://github.com/angular/universal/pull/607)

All 8 comments

I am also having the same problem after updating to Angular 2.1.1 for doing AOT. @gdi2290 @jeffwhelpley can you guys please look into this.

@esakkikrishnan It appears that @gdi2290 might have found a workaround for now or a WIP at least, published in open PR Angular Universal Starter PR 219.

@esakkikrishnan @Koslun 2.1.1 had some internal things from Core moved around.
If you need to use 2.1.1 now, either use the workaround or wait until we can update the official patch. (https://github.com/angular/universal/pull/607)

I am also getting this exact same error now, not using aot just trying to run my project with universal.
I am using Angular 2.4.0 and angular2-universal 2.1.0-rc.1

Are you using the workarounds Found here (https://github.com/angular/universal-starter/tree/master/src) and importing them near the top of your client & node files? @u12206050

@MarkPieszak Yes I am, I actually start my project straight from the Universal Starter

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

_This action has been performed automatically by a bot._

Was this page helpful?
0 / 5 - 0 ratings