question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot find stdin on track modified using Snowpack

See original GitHub issue

Trying out the new compiler with snowpack. Very minimal setup, with @snowpack/plugin-postcss added to the snowpack config and my postcss config looking like

module.exports = {
  plugins: {
    '@tailwindcss/jit': {},
    autoprefixer: {},
  }
};

Jusing the normal tailwindcss PostCSS plugin works just fine, but with JIT I am getting the following error on running yarn snowpack build:

[snowpack] ! building dependencies...
(node:1378370) UnhandledPromiseRejectionWarning: Error: Command failed with exit code 1: postcss
Error: ENOENT: no such file or directory, stat '/home/cschmatzler/development/papertrail/lynx/assets/stdin'
    at Object.statSync (fs.js:1086:3)
    at trackModified (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/@tailwindcss/jit/src/lib/setupContext.js:188:26)
    at /home/cschmatzler/development/papertrail/lynx/assets/node_modules/@tailwindcss/jit/src/lib/setupContext.js:653:38
    at /home/cschmatzler/development/papertrail/lynx/assets/node_modules/@tailwindcss/jit/src/index.js:34:49
    at LazyResult.runOnRoot (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/postcss/lib/lazy-result.js:303:16)
    at LazyResult.runAsync (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/postcss/lib/lazy-result.js:355:26)
    at LazyResult.async (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/postcss/lib/lazy-result.js:205:30)
    at LazyResult.then (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/postcss/lib/lazy-result.js:190:17)
    at /home/cschmatzler/development/papertrail/lynx/assets/node_modules/postcss-cli/index.js:233:10
    at async Promise.all (index 0) {
  errno: -2,
  syscall: 'stat',
  code: 'ENOENT',
  path: '/home/cschmatzler/development/papertrail/lynx/assets/stdin'
}
    at makeError (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/execa/lib/error.js:59:11)
    at handlePromise (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/execa/index.js:114:26)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at async Object.transform (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/@snowpack/plugin-postcss/plugin.js:13:24)
    at async runPipelineTransformStep (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/snowpack/lib/index.js:75331:32)
    at async Object.buildFile (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/snowpack/lib/index.js:75416:29)
    at async FileBuilder.buildFile (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/snowpack/lib/index.js:111929:15)
    at async run (/home/cschmatzler/development/papertrail/lynx/assets/node_modules/snowpack/lib/index.js:50375:29)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:8
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
bradlccommented, May 24, 2021

Hey all. @snowpack/plugin-postcss was updated last week and here’s how we recommend using Tailwind JIT with Snowpack:

  1. Ensure that you are using the latest tailwindcss canary release (>= 2.2.0-canary.9): npm install -D tailwindcss@canary
  2. Ensure that you are using the latest version of @snowpack/plugin-postcss (>= 1.4.0)
  3. Set the TAILWIND_DISABLE_TOUCH environment variable to true. This enables an alternative watch method which is now compatible with @snowpack/plugin-postcss
  4. Ensure that you are not using the devOptions.tailwindConfig Snowpack option

Here is a bare-bones example project: https://github.com/bradlc/jit-snowpack

If you are still having problems after following these instructions please open a new issue with a reproduction, thanks!

0reactions
rohflecommented, Mar 21, 2021

See related open issue at https://github.com/snowpackjs/snowpack/issues/2916

Theres a quickfix at https://github.com/snowpackjs/snowpack/commit/8ac85f6dff57ac49a9668dd5687d635ce054081d, where the full path is used instead of stdin, but there are still some problems in dev mode that are being worked on

Read more comments on GitHub >

github_iconTop Results From Across the Web

Common Error Details - Snowpack
This warning appears when Snowpack believes something to be in node_modules , but can't find it. This typically happens because you've tried to...
Read more >
After upgrading to Snowpack 3 cannot find files - Stack Overflow
I'm using Snowpack + Svelte. After upgrading to Snowpack 3 is not working anymore and I can't configure mount in snowpack.config.js properly ...
Read more >
A proof-of-concept integration of Vite.js (modern JS/assets ...
I ran into infinite build problem with snowpack + phoenix live reload, and I can't fix it within an hour, so I decided...
Read more >
Package List — Spack 0.20.0.dev0 documentation
This is a list of things you can install using Spack. It is automatically generated based on the packages in this Spack version....
Read more >
202 questions with answers in WRF | Scientific method
I already have a high resolution topographic Database of 30m. Using WRF model for advection movements and CMAQ for CO2 emissions, how can...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found