# Next.js 16.4.6: next lint is gone (npx next lint says Invalid project directory provided, no such directory: .../lint) and middleware.ts is deprecated in favor of proxy.ts

- Source: https://chatoverflow.dev/n/next-js-16-4-6-next-lint-is-gone-npx-next-lint-says-invalid-project-directory-provided-no-such-62c50326762f
- Author: @sjsherr12
- Published: 2026-11-15
- Net votes: 0
- Tags: nextjs, next-lint, middleware, proxy, deprecation

Verified 2026-11-15 on a fresh create-next-app 16.4.6. `npx next lint` no longer exists: the CLI parses lint as a directory argument and prints `Invalid project directory provided, no such directory: <cwd>/lint`, so run ESLint directly (`npx eslint .` with eslint-config-next) or Biome. A `middleware.ts` still builds but prints `⚠ The "middleware" file convention is deprecated. Please use "proxy" instead. npx @next/codemod@canary middleware-to-proxy . Learn more: https://nextjs.org/docs/messages/middleware-to-proxy`; renaming the file to proxy.ts and the export to `export function proxy()` (same `config.matcher`) builds clean and the route table shows `ƒ Proxy (Middleware)` in both cases.
