Error map
Router.use middleware TypeError: Router.use() requires a middleware function but got a Object
Node.js · layer 4, Application & API
Centre: this error. First ring: errors it is linked with (12). Outer ring: what those are linked with. Colours show the layer of a request each error belongs to. Click any dot to re-centre the map on it; hover to follow its connections. The centre dot opens the error page.
Directly related (12)
MySQL ERROR 1046 (3D000): No database selected
A query referenced tables without a database selected (no USE and no db in the connection).
TypeError: x is not a function
You called something as a function, but its value is not a function (it’s undefined, a string, an object…).
ReferenceError: Cannot access 'x' before initialization
A let/const/class was used before its declaration line ran (temporal dead zone) — often a circular import.
TypeError: Missing parameter name at 1 (path-to-regexp)
An Express 5 (path-to-regexp v8) route uses old wildcard syntax like '*' or '/:id?'.
TypeScript: error TS1484: 'User' is a type and must be imported using a type-only import when 'verbatimModuleSyntax' is enabled.
With `verbatimModuleSyntax` or `isolatedModules`, types must be imported/re-exported with `import type` / `export type`.
Next.js: Module not found: Can't resolve '@/components/Button' / 'lodash' in '/app/src'
Webpack/Turbopack couldn't resolve an import — wrong path/alias, missing dependency or case mismatch.
TypeError: x is not a constructor
new was used with something that isn’t a class/constructor — usually a wrong import.
Express: req.body is undefined / {} (body parser missing)
Express didn’t parse the request body because no body-parsing middleware matched the request’s Content-Type.
Go: declared and not used: x / "fmt" imported and not used
Go refuses to compile code with unused local variables or unused imports.
TypeScript: error TS2614: Module '"./Button"' has no exported member 'Button'. Did you mean to use 'import Button from "./Button"' instead?
You used a named import for something that's a default export (or reverse).
TypeScript: error TS1192: Module '"./utils"' has no default export.
You used `import x from "./mod"` but the module only has named exports.
Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client
An Express/Node handler tried to send a second response (or set headers) after one was already sent.
Two steps away (36)
OAuth Error: redirect_uri_mismatch
The redirect URI in your OAuth request doesn’t exactly match one registered for the client in the provider’s console.
hint: You have divergent branches and need to specify how to reconcile them.
Git 2.27+ asks you to choose merge, rebase or fast-forward-only when local and remote both have new commits.
error: gpg failed to sign the data — fatal: failed to write commit object
Commit signing is enabled but GPG couldn’t sign — no TTY for the passphrase, wrong key, or agent not running.
Error: Cannot find module 'x' (MODULE_NOT_FOUND)
Node can’t resolve the module path — the package isn’t installed, or a relative path/extension is wrong.
TypeError: Cannot read properties of undefined (reading 'x')
You tried to access a property on a value that is `undefined` (or `null`) — usually data that hasn’t loaded yet or a wrong proper…
ReferenceError: x is not defined
Code refers to a variable or function name that doesn’t exist in the current scope.
NameError: name 'x' is not defined
Python doesn’t know the name — it was never assigned/imported in this scope, or it’s misspelled.
SyntaxError: Identifier 'x' has already been declared
The same let/const/class name was declared twice in the same scope.
MySQL ERROR 1153 (08S01): Got a packet bigger than 'max_allowed_packet' bytes
A single statement or row exceeded max_allowed_packet — big BLOBs, huge INSERTs or large dump lines.
HTTP 404 Not Found
The server can’t find anything at the requested URL.
HTTP 405 Method Not Allowed
The URL exists, but it doesn’t accept the HTTP method you used (e.g. POST to a GET-only route).
Whitelabel Error Page — This application has no explicit mapping for /error
Spring Boot’s default error page — the request hit no controller mapping (404) or a controller threw (500).
Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined
JSX referenced a component that is undefined — almost always a default/named import mismatch.
TypeScript: error TS2693: 'User' only refers to a type, but is being used as a value here.
You used an interface/type alias where a runtime value is needed.
TypeScript: error TS1259: Module '"express"' can only be default-imported using the 'esModuleInterop' flag
You default-import a CommonJS module that uses `export =`, but `esModuleInterop` isn't enabled.
Module not found: Can't resolve 'fs' (Next.js / webpack 5)
A Node.js built-in (fs, path, crypto, net) is imported into code that runs in the browser bundle.
Next.js: Page "/blog/[slug]" is missing "generateStaticParams()" so it cannot be used with "output: export" config
A dynamic route can't be statically exported without telling Next.js which paths to generate.
Next.js: Failed to compile. ./src/app/page.tsx 12:7 Error: 'x' is assigned a value but never used. @typescript-eslint/no-unused-vars
`next build` runs ESLint and fails the build on lint errors.
MySQL ERROR 1227 (42000): Access denied; you need (at least one of) the SUPER privilege(s) for this operation
The import or statement needs SUPER/SYSTEM_VARIABLES_ADMIN — typical with dumps containing DEFINER clauses or SET GLOBAL on manag…
MySQL ERROR 1273 (HY000): Unknown collation: 'utf8mb4_0900_ai_ci'
A dump from MySQL 8 uses a collation the target server (MySQL 5.7 / MariaDB) doesn’t support.
ERROR: invalid byte sequence for encoding "UTF8": 0x00
Text contained bytes invalid in UTF-8 — often a NUL byte (0x00) or Latin-1/Windows-1252 data.
SyntaxError: Cannot use import statement outside a module
An `import` statement ran in a context treated as CommonJS (Node without "type": "module", a browser script without type="module"…
DeprecationWarning: Buffer() is deprecated due to security and usability issues (DEP0005)
Code (yours or a dependency) uses the deprecated new Buffer() constructor.
DeprecationWarning: The `punycode` module is deprecated (DEP0040)
A dependency imports Node’s built-in punycode module, deprecated since Node 21.
ImportError: cannot import name 'x' from 'y'
The module was found, but the name you’re importing from it doesn’t exist — usually a version change or a circular import.
error CS0246: The type or namespace name 'X' could not be found (are you missing a using directive or an assembly reference?)
The compiler doesn’t know the type — missing using, missing NuGet package/project reference, or a target framework mismatch.
error CS0103: The name 'x' does not exist in the current context
The identifier isn’t declared in scope — typo, variable declared in another block, missing using static, or a Razor/partial class…
TypeScript: error TS2305: Module '"./utils"' has no exported member 'helper'.
You imported a named export that the module doesn't export.
TypeScript: error TS2451: Cannot redeclare block-scoped variable 'name'.
A `let`/`const`/`class` name was declared twice in the same scope — often because files are global scripts sharing one scope.
TypeScript: error TS2792: Cannot find module 'x'. Did you mean to set the 'moduleResolution' option to 'nodenext', or to add aliases to the 'paths' option?
TypeScript can't resolve a package because `moduleResolution` doesn't match how the package exports (package `exports` map) or pa…
Error [ERR_REQUIRE_ESM]: require() of ES Module not supported
CommonJS code used `require()` on a package that is ES-module-only (node-fetch 3, chalk 5, nanoid 4, got 12…).
TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts"
Node tried to run a TypeScript file as ESM without a TypeScript loader.
TypeError [ERR_IMPORT_ATTRIBUTE_MISSING]: Module needs an import attribute of "type: json"
An ES module imported a .json file without the required import attribute.
Warning: Cannot modify header information - headers already sent
You called `header()`, `setcookie()` or `session_start()` after output had already been sent to the browser.
Error: secret option required for sessions (express-session)
express-session needs a `secret` to sign the session cookie and none was provided.
Error: Cannot send secure cookie over unencrypted connection
express-session was told to set a `Secure` cookie but the request looks like plain HTTP to Express, usually behind a proxy.