Skip to content
This repository has been archived by the owner on Apr 5, 2019. It is now read-only.

dev server breaks when anything changes in the source folder #28

Open
asifm opened this issue Jun 7, 2018 · 4 comments
Open

dev server breaks when anything changes in the source folder #28

asifm opened this issue Jun 7, 2018 · 4 comments

Comments

@asifm
Copy link

asifm commented Jun 7, 2018

(I'm using Windows 10, node 10.2.1)

[email protected] and [email protected] do not let the dev server run. yarn run dev results in this webpack error:

PS C:\Users\***\firstdraft.today> yarn run dev
yarn run v1.3.2
$ peco dev
> Building from source
WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
 - configuration.output.path: The provided value "C:/Users/***/firstdraft.today/.peco/dist/client" is not an absolute path!
   -> The output directory as **absolute path** (required).
    at webpack (C:\Users\***\firstdraft.today\node_modules\webpack\lib\webpack.js:24:9)
    at Peco.dev (C:\Users\***\firstdraft.today\node_modules\peco\lib\index.js:289:40)
    at <anonymous>

[email protected] seems fine. The only problem is this: when the dev server is running, any change in the file system -- for example, adding a new file in source folder or changing a current file in source folder -- will break the dev server (see the error below). Everything is fine if the yarn run dev command is executed after making the changes in the source folder.

TypeError: Cannot read property 'isVirtual' of undefined
    at Promise.all.files.map (C:\Users\***\firstdraft2.today\node_modules\peco\plugins\source-file-system\index.js:163:27)    at Array.map (<anonymous>)
    at SourceFileSystem.buildFiles (C:\Users\***\firstdraft2.today\node_modules\peco\plugins\source-file-system\index.js:161:13)
    at SourceFileSystem.onChangeFile (C:\Users\***\firstdraft2.today\node_modules\peco\plugins\source-file-system\index.js:333:16)
    at FSWatcher.filesWatcher.on.on.on (C:\Users\***\firstdraft2.today\node_modules\peco\plugins\source-file-system\index.js:72:24)
    at FSWatcher.emit (events.js:182:13)
    at FSWatcher.<anonymous> (C:\Users\***\firstdraft2.today\node_modules\chokidar\index.js:199:15)
    at FSWatcher._emit (C:\Users\***\firstdraft2.today\node_modules\chokidar\index.js:241:5)
    at FSWatcher.<anonymous> (C:\Users\***\firstdraft2.today\node_modules\chokidar\lib\nodefs-handler.js:264:16)
    at FSReqWrap.oncomplete (fs.js:183:5)
@awulkan
Copy link

awulkan commented Jun 12, 2018

Same for me. Would be nice to have a fix since I'd like to try this project out.

@awulkan
Copy link

awulkan commented Jun 22, 2018

@egoist Do you know why this happens? Any idea of how to fix it? Waiting to try out Peco but I can't even start the dev server right now. :/

@frncsdrk
Copy link
Contributor

@asifm @awulkan Does the issue persist with Node 10.9.x and [email protected]?

@flozero
Copy link

flozero commented Sep 14, 2018

Hello i writted a PR that correct the bug all explain in it

let's look here 🗡 #34

If you add me as contributor i will try to help more 🥇

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants