-
Notifications
You must be signed in to change notification settings - Fork 37
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
Type error using useTask with ember-concurrency 1.x and ember-concurrency-async #297
Comments
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
Issue: #297 Resolves this issue: ``` Argument of type 'TaskForAsyncTaskFunction<() => Promise<Food>>' is not assignable to parameter of type 'TaskIsh<Food, Data[]>'. The types returned by 'perform(...).cancel(...)' are incompatible between these types. Type 'void' is not assignable to type 'Promise<void>'. ```
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
Issue: #297 Resolves this issue: ``` Argument of type 'TaskForAsyncTaskFunction<() => Promise<Food>>' is not assignable to parameter of type 'TaskIsh<Food, Data[]>'. The types returned by 'perform(...).cancel(...)' are incompatible between these types. Type 'void' is not assignable to type 'Promise<void>'. ```
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
Issue: #297 Resolves this issue: ``` Argument of type 'TaskForAsyncTaskFunction<() => Promise<Food>>' is not assignable to parameter of type 'TaskIsh<Food, Data[]>'. The types returned by 'perform(...).cancel(...)' are incompatible between these types. Type 'void' is not assignable to type 'Promise<void>'. ```
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
NullVoxPopuli
added a commit
that referenced
this issue
Dec 5, 2021
Issue: #297 Resolves this issue: ``` Argument of type 'TaskForAsyncTaskFunction<() => Promise<Food>>' is not assignable to parameter of type 'TaskIsh<Food, Data[]>'. The types returned by 'perform(...).cancel(...)' are incompatible between these types. Type 'void' is not assignable to type 'Promise<void>'. ```
Is this still an issue? Looks like there were some commits related to this? |
Gonna close this for now -- feel free to re-open of there are still issues! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Running into a type error when using some combination of [email protected], ember-concurrency-async, ember-concurrency-decorators, and ember-resources'
useTask
. I not sure exactly what in there is causing the issue though.When doing something like this:
I get the following type error:
Seems like this could be fixed by updating the type for
cancel
here to allowvoid
ember-resources/ember-resources/src/-private/resources/ember-concurrency-task.ts
Line 37 in 5595549
The text was updated successfully, but these errors were encountered: