Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Windows css resolution #1344

Closed
2 tasks done
Nvos opened this issue Mar 4, 2024 · 2 comments · Fixed by #1346
Closed
2 tasks done

Windows css resolution #1344

Nvos opened this issue Mar 4, 2024 · 2 comments · Fixed by #1346
Labels
vite Issue related to vite windows Bug affects Windows exclusively

Comments

@Nvos
Copy link

Nvos commented Mar 4, 2024

Describe the bug

It seems that vite plugin function getAbsoluteId always receives unix path (even on windows) and uses path.sep due to which comparison fails on windows resulting in failing to find matching css in cssCache

Issue seems to be there:

filePath.split(path.sep)[1] === config.root.split(path.sep)[1])

Reproduction

https://github.com/Nvos/vanilla-extract-vinxi-repro

System Info

System:
    OS: Windows 10 10.0.19045
    CPU: (12) x64 Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz
    Memory: 21.50 GB / 31.80 GB
  Binaries:
    Node: 18.15.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.19 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
    npm: 9.5.0 - C:\Program Files\nodejs\npm.CMD
    pnpm: 8.6.7 - ~\AppData\Roaming\npm\pnpm.CMD
  Browsers:
    Edge: Chromium (122.0.2365.66)
    @vanilla-extract/css: ^1.14.1 => 1.14.1
    @vanilla-extract/vite-plugin: ^4.0.4 => 4.0.4

Used Package Manager

pnpm

Logs

No response

Validations

@askoufis askoufis added windows Bug affects Windows exclusively vite Issue related to vite and removed pending triage labels Mar 4, 2024
@askoufis
Copy link
Contributor

askoufis commented Mar 4, 2024

This could potentially be the same issue as #1339. Thanks for investigating.

@himself65
Copy link
Contributor

Same error here dai-shi/waku#559

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
vite Issue related to vite windows Bug affects Windows exclusively
Projects
None yet
3 participants