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

Static Files being trimmed #4

Open
jchannon opened this issue Mar 13, 2015 · 6 comments
Open

Static Files being trimmed #4

jchannon opened this issue Mar 13, 2015 · 6 comments

Comments

@jchannon
Copy link

Hi,

I've been testing this today and have found an odd issue with static files being trimmed.

I create a 2mb js file and when requested it only returned 1.6mb

I ran it through express and it returned all of it. I created a separate .Net app using the UseStaticFiles middleware and that returned it all so my assumption is connect-owin is trimming somewhere.

Any ideas?

@bbaia
Copy link
Owner

bbaia commented Mar 16, 2015

I couldn't reproduce your problem.
Can you tell me what version of the following components you are using :

  • nodejs
  • expressjs
  • connect-owin
  • Microsoft.Owin
  • Microsoft.Owin.StaticFiles

@jchannon
Copy link
Author

I'll get those over in about 90mins. I was running node on Linux so not
sure if that's a factor

On Monday, 16 March 2015, Bruno Baia notifications@github.com wrote:

I couldn't reproduce your problem.
Can you tell me what version of the following components you are using :

  • nodejs
  • expressjs
  • connect-owin
  • Microsoft.Owin
  • Microsoft.Owin.StaticFiles

Reply to this email directly or view it on GitHub
#4 (comment).

bbaia added a commit that referenced this issue Mar 16, 2015
@jchannon
Copy link
Author

Here's a reproduction of the issue here https://github.com/jchannon/connectowinrepro

Its using latest .net components

Node = 0.10.25
Express = 4.12.2
Connect-Owin = 0.3.0

@jchannon
Copy link
Author

If you make a request to http://localhost:3000/static/lib.js you'll see the file is trimmed

@bbaia
Copy link
Owner

bbaia commented Mar 19, 2015

In server.js file, if you comment the connect-owin middleware and configure the express static middleware like this :

app.use(express.static(__dirname));

You'll get the same problem.

The F12 panel indicates a 1.6mb file and the content is trimmed in the content panel, but if you download the source, the file is OK...

@jchannon
Copy link
Author

I didn't see that but will try again.

It first came about when an angular client was requesting the js file and it failed to initialise the angular app as it appeared the file was trimmed

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

2 participants