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

Productize Task/ValueTask/Async.ignore #128

Closed
bartelink opened this issue Dec 13, 2022 · 5 comments
Closed

Productize Task/ValueTask/Async.ignore #128

bartelink opened this issue Dec 13, 2022 · 5 comments

Comments

@bartelink
Copy link
Member

bartelink commented Dec 13, 2022

I've long felt icky about using Async.Ignore. Seeing the Async.ignore that's presently hiding in plain sight here makes me realise the absence of a Task.ignore and ValueTask.ignore from FSharp.Core is something I've also been grinning and bearing (sprinkling :> Task and all sorts of other such mindless hacks). Utils.fs presently has helpers that feel very tempting to use more broadly. However, binding to a set of support helpers on the fringe of this library's core feature set is obviously debatable.

(The other pair from here that I feel deserves a canonical implementation in a library that doesn't include a jungle of other less-related helpers is Async.ofTask/Task.toAsync, but with corrected AggregateException semantics, and honoring of Async.Cancellation when compared to Async.AwaitTask as per FSharp.Core. Will likely calve off a separate issue from this if placeholder FSharp.Core.TaskShims package/repo is deemed to be the best home for a set of ignore helpers)

related:

@abelbraaksma
Copy link
Member

abelbraaksma commented Dec 14, 2022

/cc @dsyme, we should discuss this. Some of this effort may ultimately land back into F# Core, but agreeing on a TaskEx library (name tbd) and adding it to the FsProjects realm may be a good idea.

This is related to #78, specifically #78 (comment).

@TheAngryByrd
Copy link
Collaborator

Yeah I have a lot of the same functions floating around in IcedTasks (example1, example2) and FsToolkit (example1, example2)

I even have a tool that writes out all the functions (like map, bind, apply, zip, etc) and which libraries contain them because it's hard to know who implementing what these days and where the gaps are in functionality.

This was referenced Jan 5, 2023
@bartelink
Copy link
Member Author

Closing in favor of #139 (general high level discussion about shimming and/or libraries/projects) and #140 (ignore helpers only)

@bartelink
Copy link
Member Author

Switching close reason; work is not completed; sorry!

@bartelink bartelink closed this as not planned Won't fix, can't repro, duplicate, stale Jan 5, 2023
@abelbraaksma
Copy link
Member

Thanks for writing out these covering issues! Much appreciated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants