-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Can something be done about the Microsoft.Tpl.Dataflow package? #23792
Comments
IMO we should pick option 2 and then unlist the Microsoft.Tpl.Dataflow package so it doesn't show in search results. |
I just had someone ask me a question about this and wasn't sure of the answer, so I had to look into it and found this issue. Keeping both listed can cause confusion for those unaware of the difference - especially when Visual Studio's package manager lists the "incorrect" one first, with the proper one being quite far down the list: |
@weshaggard can't we just unlist (not delete) the package? |
I just unlisted all the versions so that should help with the confusion. |
Except I now can't install Microsoft.Azure.WebJobs.Extensions 2.2.2 because it has a direct dependency on Microsoft.Tpl.Dataflow :( |
@HowardvanRooijen how are you installing? By unlisting the package it should still be install-able when there are references to exact versions. |
My project is using Microsoft.AspNet.WebHooks.Custom.Mvc, which has a dependency on Microsoft.AspNet.WebHooks.Custom which, in turn, has a dependency on Microsoft.Tpl.Dataflow (>= 4.5.24) Running this command in the Package Manager Console now generates an error:
Update-Package : Unable to find package 'Microsoft.Tpl.Dataflow'. Existing packages must be restored before performing an install or update.At
The packages directory for the solution does have a local copy Microsoft.Tpl.Dataflow.4.5.24. |
^^ Exactly the same for me both locally and on our VSTS hosted VS2017 build agent. |
@tfritzke @HowardvanRooijen are you doing it from the VS "Package Manager Console". It seems to work for me locally:
cc @rrelyea |
@weshaggard What's your result when running the command "Update-Package -Reinstall"? |
Same.
|
@weshaggard
|
OK I was able to repro it now as it seems as though it only fails if trying to install or update Microsoft.Tpl.Dataflow package without a specified version. To workaround you can call Update-Package -Reinstall Microsoft.AspNet.WebHooks.Custom.Mvc which will work because it is installing/updating to a specific version of Microsoft.Tpl.Dataflow. @rrelyea to repro this you can do:
When someone does a general update like It works if you specify the version like:
@rrelyea is this the expected behavior for unlisted packages? |
We are running into the exact same issues after the unlisting. For a bit of background, our CMS Library, which has Until the Microsoft.Tpl.Dataflow package was delisted we were pretty happy to stick with this solution but this is not really feasible anymore with the issues that the delisting is causing for our users when they are trying to update our package. With this in mind I'm hoping that you would reconsider the delisting, or even better, add a proper .NET Framework target to the System.Threading.Tasks.Dataflow package. |
@rrelyea is there anything we can do in the package manager console to better handle unlisted packages? We need a way to let our customers know they shouldn't be installing this package any more while not breaking existing customer projects that still reference it. |
we are doing work in the deprecated packages area...which will include marking a package for security or other reasons. you will have more power than just "unlisting" |
OK to unblock folks that still reference this package in their projects I've relisted the latest version of Microsoft.Tpl.Dataflow https://www.nuget.org/packages/Microsoft.Tpl.Dataflow/4.5.24. We will keep this issue open until we have another option to help deprecate this package without breaking folks that currently reference it. |
Linking Deprecate packages issue: NuGet/Home#2867 |
In my experience unlisting is a bad practice, since it is not handled well by many tools like, for example, the nuget integration of LinqPad. I think unlisting old packages was the single worst thing the RX-Team ever did. What is so bad about option 2 of the original post? |
That is a possibility. I just did a quick diff of the two assemblies and they do look compatible enough but we would need to do further testing to ensure it doesn't break folks. @danmosemsft do we have someone that can attempt to do option (2)? |
Option 2 is the right way of deprecating packages until the “deprecation” feature becomes a reality |
Unfortunately, MSDN's older TPL Dataflow Library page also needs to be updated:
Fortunately, the newer Dataflow (Task Parallel Libary) page talks about the more current package. |
@azureskydiver if you like you can offer a PR in the docs repo |
@danmosemsft For some reason, the problematic page is still on MSDN (and isn't redirected or archived), so there is no way to contribute to fix that. |
@terrajobst, it looks like NuGet added the necessary feature to properly deprecate packages. Can you help get that taken care of here? @svick, I'm not seeing the bad reference in the docs, so either I'm missing it or it's been fixed in the interim. Is there still an issue there? |
@stephentoub It seems the old MSDN article has been redirected to the updated docs.microsoft.com article since 2018. So I think the docs are okay now. |
Good call. Done. It will take a few hours before NuGet has updated its caches, tho. |
Thanks, Immo. Seems like everything here has been done, so I'll close. |
The
Microsoft.Tpl.Dataflow
package is outdated and generally shouldn't be used anymore. The replacement is theSystem.Threading.Tasks.Dataflow
package.But people keep using the old package (see e.g. https://github.com/dotnet/corefx/issues/202#issuecomment-335470737), not knowing they should switch to the new one. Is there something that can be done to help those people?
Some options I considered:
Microsoft.Tpl.Dataflow
deprecated.Microsoft.Tpl.Dataflow
that will contain no code of its own and will "redirect" toSystem.Threading.Tasks.Dataflow
by having a dependency on it. (And then keep releasing a new version every timeSystem.Threading.Tasks.Dataflow
updates?)cc: @stephentoub
The text was updated successfully, but these errors were encountered: