Comments (8)
Insert the following before line 90
of /home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/shared/getFilePath.js
and report back. (It seems to be a Windows issue but I don't have a Windows setup atm.)
+ console.log('filePathAbsoluteFilesystem', filePathAbsoluteFilesystem);
+ console.log('userRootDir', userRootDir);
+ console.log('filePathRelative', filePathRelative);
assert(!filePathRelative.startsWith('.') && !filePathRelative.startsWith('/'));
from vike.
Thanks for this super fast response!
I don´t expect a Windows-issue. WSL is the "Windows subsystem for Linux" and provides a native Linux-VM including original Filesystem similar to what you get inside a docker container. So the developement is done in Ubuntu 22.04.
After inserting the thee new commands I see this log between server start end error exit:
Server listening on http://localhost:3000
filePathAbsoluteFilesystem /home/wulf/projekte/bati/my-app/.history/pages/index/+Page_20240402105314.vue
userRootDir /home/wulf/projekte/bati/my-app
filePathRelative .history/pages/index/+Page_20240402105314.vue
Error: [[email protected]][Bug] You stumbled upon a Vike bug. Go to https://github.com/vikejs/vike/issues/new and copy-paste this error. A maintainer will fix the bug (usually under 24 hours).
at getFilePathAbsoluteUserRootDir (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/shared/getFilePath.js:93:5)
at getFilePathResolved (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/shared/getFilePath.js:18:39)
at reloadConfig (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/plugins/importUserCode/index.js:122:50)
at listener (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/plugins/importUserCode/index.js:77:13)
at FSWatcher.<anonymous> (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/plugins/importUserCode/index.js:66:50)
at FSWatcher.emit (node:events:525:35)
at FSWatcher.emit (node:domain:489:12)
at FSWatcher.emitWithAll (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-C-KAszbv.js:45880:8)
at FSWatcher._emit (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-C-KAszbv.js:45972:8)
at NodeFsHandler._handleFile (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-C-KAszbv.js:44557:14)
at NodeFsHandler._addToNodeFs (file:///home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-C-KAszbv.js:44794:21)
ELIFECYCLE Command failed with exit code 1.
Same behaviour with a fresh install under node v20.9.0.
from vike.
Indeed, it isn't a Windows issue.
What is the .history/
directory and the +Page_20240402105314.vue
file? Is that a Tailwind thing?
from vike.
line
90
of/home/wulf/projekte/bati/my-app/node_modules/.pnpm/[email protected][email protected]/node_modules/vike/dist/esm/node/plugin/shared/getFilePath.js
If you remove the assertion assert(!filePathRelative.startsWith('.') && !filePathRelative.startsWith('/'));
does it work then?
from vike.
Bingo! That´s it. No issues anymore after removing the assertion!
Great work! I did not notice .history
in the error message.
.history is created by VS-Code local history plugin and should not be included.
But expect this to be present on many machines. It can be extremely useful even if git is active.
After removing .history and editing +Page.vue with another editor, HMR was working fine.
I investigated if adding .history
to .gitignore helps. Some tools respect these entries.
But here it did not show any effect. HMR still crashed the dev-server.
So it should be possible to restrict the directories that were parsed during HMR, right?
from vike.
Fix pre-released as [email protected]
.
adding
.history
to .gitignore
That should actually make Vike ignore .history
.
Related: #1593.
Let me know if you still run into issues.
In case that's something your company be up for, we're looking for sponsors — it makes a massive difference.
from vike.
Thank your for your quick help!
I will continue to evaluate vike and see if we can use it for our project.
Currently our company is a bit too far away from break even to think about sponsoring.
But I will keep it in mind!
Btw: Grüße in die alte Heimat!
from vike.
Makes sense and thanks for circling back on this.
Grüße zurück :)
from vike.
Related Issues (20)
- storybook-vike HOT 3
- Vike Bug during SSR generation HOT 10
- Query Regarding Page Navigation in Vike Software
- Client-only guard() hook HOT 5
- crash app in build mode after update vike from 0.4.165 to 0.4.168 HOT 1
- How to set scrollPosition to auto HOT 6
- Bug reported due to HMR overlay HOT 4
- UncaughtException issue HOT 1
- history.state.triggedby and history.state.triggeredby HOT 7
- New hook `onRequestBegin()`
- Styled component's classname did not match the server issue with HMR
- New CLI commands `$ vike routes`, `$vike pages`, and `$ vike config`
- Vike StrictMode
- `urlParsed` removes trailing slash HOT 9
- Offer `href` in `urlParsed` HOT 2
- React native web error: __vite_ssr_import_0__.default is not a function
- Env Leak (Vite, Vike, Vike-Solid, Bun) HOT 9
- Error previewing built Vike app when using Vite Legacy plugin HOT 1
- build error HOT 3
- New setting `crawlWithGit`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vike.