postcss / autoprefixer

Parse CSS and add vendor prefixes to rules by Can I Use
https://twitter.com/autoprefixer
MIT License
21.57k stars 1.25k forks source link

Error: Cannot find module 'caniuse-lite/data/features/css-unicode-bidi' #1475

Closed AlexWayfer closed 1 year ago

AlexWayfer commented 1 year ago
> sass assets/styles/main.scss public/styles/main.css -s compressed && postcss public/styles/main.css -o public/styles/main.css

Error: Cannot find module 'caniuse-lite/data/features/css-unicode-bidi'
Require stack:
- /home/alex/Projects/stream_timer/node_modules/.pnpm/autoprefixer@10.4.8_postcss@8.4.16/node_modules/autoprefixer/data/prefixes.js
- /home/alex/Projects/stream_timer/node_modules/.pnpm/autoprefixer@10.4.8_postcss@8.4.16/node_modules/autoprefixer/lib/autoprefixer.js
- /home/alex/Projects/stream_timer/postcss.config.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:955:15)
    at Module._load (node:internal/modules/cjs/loader:803:27)
    at Module.require (node:internal/modules/cjs/loader:1021:19)
    at require (node:internal/modules/cjs/helpers:103:18)
    at Object.<anonymous> (/home/alex/Projects/stream_timer/node_modules/.pnpm/autoprefixer@10.4.8_postcss@8.4.16/node_modules/autoprefixer/data/prefixes.js:1044:18)
    at Module._compile (node:internal/modules/cjs/loader:1119:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1173:10)
    at Module.load (node:internal/modules/cjs/loader:997:32)
    at Module._load (node:internal/modules/cjs/loader:838:12)
    at Module.require (node:internal/modules/cjs/loader:1021:19) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/home/alex/Projects/stream_timer/node_modules/.pnpm/autoprefixer@10.4.8_postcss@8.4.16/node_modules/autoprefixer/data/prefixes.js',
    '/home/alex/Projects/stream_timer/node_modules/.pnpm/autoprefixer@10.4.8_postcss@8.4.16/node_modules/autoprefixer/lib/autoprefixer.js',
    '/home/alex/Projects/stream_timer/postcss.config.js'
  ]
}
 ELIFECYCLE  Command failed with exit code 1.

autoprefixer 10.4.8

Just occurred today between same runs, checked on different projects.

ai commented 1 year ago

I am working on the fix.

ai commented 1 year ago

Fixed acfe2ad

ai commented 1 year ago

The fix was released in Autoprefixer 10.4.9.

Just 10 minutes from the issue report to the fix release!

If you want to support our work in the night to fix the bug, here is PostCSS & Autoprefixer open collective: https://opencollective.com/postcss

Schweinepriester commented 1 year ago

@ai don't know if you talked behind the scenes and already know, but in any case for the record: the file was returned in https://github.com/Fyrd/caniuse/pull/6446

ai commented 1 year ago

@Schweinepriester yeap, because I spoke with Can I Use maintainer :).

I am now working on a better way. Autoprefixer will use MDN data for this prefix.