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

UnhandledPromiseRejection error when running sergey --watch concurrently with another script #62

@joulev

Description

@joulev

I regularly use sass in my sites, so I usually run this to make sure my compiled CSS is up to date.

$ sass --style=compressed --quiet scss/styles.scss css/styles.css --watch

Now I also want to deploy my Sergey site to localhost, so

$ sergey --watch

However, although just editing HTML files is fine, as soon as I edit my SCSS, sergey throws an error,

$ sergey --watch
Compiled in 290ms
Sergey running on http://localhost:8080
Compiled in 371ms
node:internal/process/promises:246
          triggerUncaughtException(err, true /* fromPromise */);
          ^

[UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "Couldn't create folder: ./public/path/to/a/random/folder/".] {
  code: 'ERR_UNHANDLED_REJECTION'
}

Am I missing something...? since running concurrent commands like this, I think, is quite common, but I haven't seen anyone reporting this problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions