Skip to content

An unhandled exception occurred while processing the request. #381

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

Closed
mahavirjadhav opened this issue Aug 23, 2017 · 6 comments
Closed

An unhandled exception occurred while processing the request. #381

mahavirjadhav opened this issue Aug 23, 2017 · 6 comments

Comments

@mahavirjadhav
Copy link

Hi, I am facing following issues. After building application from command line it is giving following errors. Also I modified nav component. In that I have added one image but its not working. detailed error is as following.

` ERROR in G:/aspnetcore-angular2-universal-master/node_modules/rxjs/Subject.d.ts (16,22): Class 'Subject' incorrectly extends base class 'Observable'.
Types of property 'lift' are incompatible.
Type '(operator: Operator<T, R>) => Observable' is not assignable to type '(operator: Operator<T, R>) => Observable'.
Type 'Observable' is not assignable to type 'Observable'.
Type 'T' is not assignable to type 'R'.

ERROR in G:/aspnetcore-angular2-universal-master/Client/app/shared/route.resolver.ts (7,14): Class 'ConnectionResolver' incorrectly implements interface 'Resolve<SignalRConnection>'.
  Types of property 'resolve' are incompatible.
    Type '() => Promise<ISignalRConnection>' is not assignable to type '(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) => SignalRConnection | Observable<Sig...'.
      Type 'Promise<ISignalRConnection>' is not assignable to type 'SignalRConnection | Observable<SignalRConnection> | Promise<SignalRConnection>'.
        Type 'Promise<ISignalRConnection>' is not assignable to type 'Promise<SignalRConnection>'.
          Type 'ISignalRConnection' is not assignable to type 'SignalRConnection'.
            Property '_status' is missing in type 'ISignalRConnection'.

ERROR in G:/aspnetcore-angular2-universal-master/Client/app/shared/route.resolver.ts (7,14): Class 'ConnectionResolver' incorrectly implements interface 'Resolve<SignalRConnection>'.
  Types of property 'resolve' are incompatible.
    Type '() => Promise<ISignalRConnection>' is not assignable to type '(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) => SignalRConnection | Observable<Sig...'.
      Type 'Promise<ISignalRConnection>' is not assignable to type 'SignalRConnection | Observable<SignalRConnection> | Promise<SignalRConnection>'.
        Type 'Promise<ISignalRConnection>' is not assignable to type 'Promise<SignalRConnection>'.
          Type 'ISignalRConnection' is not assignable to type 'SignalRConnection'.
            Property '_status' is missing in type 'ISignalRConnection'.

ERROR in ./Client/app/Content/Images/user2.jpg
Module parse failed: G:\aspnetcore-angular2-universal-master\Client\app\Content\Images\user2.jpg Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type.
(Source code omitted for this binary file)
 @ ./Client/app/components/navmenu/navmenu.component.html 1:5263-5304 1:5997-6038 1:9885-9926 1:10240-10281
 @ ./Client/app/components/navmenu/navmenu.component.ts
 @ ./Client/app/app.module.ts
 @ ./Client/app/server-app.module.ts
 @ ./Client/main.server.ts`
@MarkPieszak
Copy link
Member

Can you check out this commit & message here, think a few things might of changed in the 3rd part library. a138974

@mahavirjadhav
Copy link
Author

Thank you MarkPieszak for reply. Please can you comment on following error.

`ERROR in ./Client/app/Content/Images/user2.jpg
Module parse failed: G:\aspnetcore-angular2-universal-master\Client\app\Content\Images\user2.jpg Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type.
(Source code omitted for this binary file)
@ ./Client/app/components/navmenu/navmenu.component.html 1:5263-5304 1:5997-6038 1:9885-9926 1:10240-10281
@ ./Client/app/components/navmenu/navmenu.component.ts
@ ./Client/app/app.module.ts
@ ./Client/app/server-app.module.ts
@ ./Client/main.server.ts``

@MarkPieszak
Copy link
Member

That's because there's no loader to handle images by default (but in the latest PR #376, which I'm trying to merge real soon) it'll become default.

In webpack.common.js add the following rule:

{ test: /\.(png|jpg|jpeg|gif|svg)$/, use: 'url-loader?limit=25000' },

Make sure url-loader is installed as well, npm i --S url-loader

Hope that helps!

@mahavirjadhav
Copy link
Author

Thank you Mark for quick reply. I will try.

@mahavirjadhav
Copy link
Author

Thank you Mark for your help. I have one question in mind. Can I start developing web application using Angular Universal Framework. As there are changes are going in the library. Are there any new versions coming. Or is current framework is sufficient to start development.

@MarkPieszak
Copy link
Member

You could get started, the changes coming are quite big(?) mainly the webpack build, and many file changes. Maybe ideally wait a day or two, subscribe to that PR so you know when it's merged?

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

No branches or pull requests

2 participants