akameco / s2s

Coding time Compile. A tool to write code fastest.

Home Page:https://qiita.com/akameco/items/e1489c6bbf3439ec6ca4

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ファイルが存在しないときのエラー表示を簡潔にする

akameco opened this issue · comments

  • module name:
  • module version:
  • node version:
  • yarn version:

What happened: エラーがうるさい

babel src/containers/App/actionTypes.js → src/types/action.js
Error: ENOENT: no such file or directory, open 'src/containers/App/reducer.js'
    at Object.fs.openSync (fs.js:646:18)
    at Object.fs.readFileSync (fs.js:551:33)
    at handlePlugin (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/handlers/index.js:52:32)
    at handlePlugins (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/handlers/index.js:124:9)
    at FSWatcher.watcher.on.input (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/index.js:77:32)
    at emitOne (events.js:116:13)
    at FSWatcher.emit (events.js:211:7)
    at FSWatcher.<anonymous> (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:196:15)
    at FSWatcher._emit (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:238:5)
    at FSWatcher._remove (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:555:50)
Error: ENOENT: no such file or directory, open '/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/src/containers/App/reducer.test.js'
    at Object.fs.openSync (fs.js:646:18)
    at Object.fs.readFileSync (fs.js:551:33)
    at handlePlugin (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/handlers/index.js:52:32)
    at handlePlugins (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/handlers/index.js:124:9)
    at FSWatcher.watcher.on.input (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/s2s/lib/index.js:77:32)
    at emitOne (events.js:116:13)
    at FSWatcher.emit (events.js:211:7)
    at FSWatcher.<anonymous> (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:196:15)
    at FSWatcher._emit (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:238:5)
    at FSWatcher._remove (/Users/akameco/src/github.com/akameco/s2s/examples/shopping-cart/node_modules/chokidar/index.js:555:50)

Reproduction repository:

Problem description:

ファイルが存在しない場合のみエラーメッセージを抑制する

Suggested solution:

ENOENTの場合、 メッセージを表示しない