Skip to content

Error 404 SourceMap Next5 #3748

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
1 task done
goridragon opened this issue Feb 10, 2018 · 6 comments
Closed
1 task done

Error 404 SourceMap Next5 #3748

goridragon opened this issue Feb 10, 2018 · 6 comments

Comments

@goridragon
Copy link

  • I have searched the issues of this repository and believe that this is not a duplicate.

Steps to Reproduce (i don't know if bugs)

  1. Upgrade to version 5 of next
  2. In dev mode the terminal tells me the 404 error of the js source map
  3. Keep running my application, but the message bothers me, I do not know if it's ok

Context

My big mental problem, is not knowing if this is a normal behavior or I have something wrong with my next application configuration or in the browser.
Terminal:

DONE Compiled successfully in 3408ms
"GET /_next/-/manifest.js.map HTTP/1.1" 404 Chrome/63.0.3239.132 Safari/537.36
"GET /_next/-/commons.js.map HTTP/1.1" 404 Chrome/63.0.3239.132 Safari/537.36
"GET /_next/-/main.js.map HTTP/1.1" 404 Chrome/63.0.3239.132 Safari/537.36

Your Environment

Tech Version
next v5.0.0
node v8.9.4
OS macos sierra
browser google chrome
@goridragon
Copy link
Author

the solution was to change the devtool in next.config.js and it gave me results it does not leave error, but it is because of some chrome google theme so I still do not know if it will be ok or not

'use strict'

module.exports = {
	useFileSystemPublicRoutes: false,
	webpack(config, { dev }) {
		if(dev) {
			config.devtool = 'cheap-module-eval-source-map'
		}
		return config;
	}
}

@dizlexik
Copy link
Contributor

I'm experiencing the same issue. I receive a 404 for the various sourcemap paths, e.g. /_next/-/manifest.js.map. I'm using a custom server and those requests are passing through the same handler as all others, but the others are working fine, e.g. /_next/-/common.js, /_next/-/main.js , etc. I see the manifest.js.map file sitting in my .next directory, alongside common.js, main.js, and others, but for whatever reason the handler is returning a 404 for the .map files.

I've resorted to using @hipabloangel's workaround above, but I'd rather not have to do that, and it's making my bundles much larger with all of the inlined sourcemaps.

@bryandowning
Copy link

This may have been fixed by #3969

@timneutkens
Copy link
Member

It's a combination of a few things @ptomasroos worked on, try upgrading to next@canary 👍

@alexpriceco
Copy link

I'm on next@canary, and still getting that 404 for the manifest.js.map. 😕

@ptomasroos
Copy link
Contributor

Right. I never added manifest.js.map since I was looking at production builds mainly. I can def fix that quickly for development

# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants