question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[easy] fail more gracefully when no functions folder

See original GitHub issue

- Do you want to request a feature or report a bug?

feature

- What is the current behavior?

when a functions field is specified but the folder doesnt exist, we should create it, or warn and exit. instead, now we show this error:

Error: ENOENT: no such file or directory, scandir 'lambda'
    at createHandler (~/Netlify/netlify-dev-plugin/node_modules/@netlify/zip-it-and-ship-it/src/serve.js:61:6)
    at serveFunctions (~/Netlify/netlify-dev-plugin/node_modules/@netlify/zip-it-and-ship-it/src/serve.js:159:16)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
ehmickycommented, Sep 19, 2019

This is fixed as part of #48. I’ve also added a unit test as part of #47.

1reaction
sw-yxcommented, Sep 19, 2019

yup im suggesting stealing the error msg

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bash: graceful function death on error - Stack Overflow
For my scripts, I am using an exception handling technique where I return errors in a way that is not return codes, and...
Read more >
Fatal errors due to non-existent objects [#941774] | Drupal.org
... (below) and fail more gracefully, I've added a simple check that the object in question does exist. If it does not, the...
Read more >
how to gracefully handle rsync failing, sometimes, to correctly ...
Running Ubuntu 16.04 LTS fully updated on remote webserver Running rsync 3.1.1 on remote webserver. I have a fairly simple setup where I ......
Read more >
Best Practices for Node.js Error-handling - Toptal
It is not hard to see that some people are struggling to handle errors, and some are even totally missing it. Handling errors...
Read more >
Node.js Error Handling Best Practices - Sematext
It's a classic case of programmer error. Here are a few more: called an asynchronous function without a callback; did not resolve a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found