Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable no-floating-promises for eslint #1809

Open
feywind opened this issue Jun 5, 2023 · 0 comments
Open

Enable no-floating-promises for eslint #1809

feywind opened this issue Jun 5, 2023 · 0 comments
Assignees
Labels
type: process A process-related concern. May include testing, release, or the like.

Comments

@feywind
Copy link
Contributor

feywind commented Jun 5, 2023

The purpose of this proposal is to prevent accidentally "dangling" promises from called functions.

https://typescript-eslint.io/rules/no-floating-promises

In Node, it's possible to call an async function, or one that just returns a promise, and ignore the result. This leaves a promise that has no catch handler, which, in modern runtimes, can result in crashing the process.

The proposal here is two-fold:

  • Turn this on and see if anything breaks in a few places
  • Turn it on for all libraries, and do a fix pass

We might also consider this related rule:

https://typescript-eslint.io/rules/no-misused-promises

@chingor13 chingor13 added the type: process A process-related concern. May include testing, release, or the like. label Jul 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: process A process-related concern. May include testing, release, or the like.
Projects
None yet
Development

No branches or pull requests

3 participants