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

FindPackageByIdResource resources needs a default cache context and logger #1357

Closed
emgarten opened this issue Sep 9, 2015 · 0 comments
Closed
Assignees
Labels
Functionality:SDK The NuGet client packages published to nuget.org Type:DCR Design Change Request
Milestone

Comments

@emgarten
Copy link
Member

emgarten commented Sep 9, 2015

FindPackageByIdResource resources have their CacheContext and Logger properties set by the project.json resolver. This is the only scenario where it is used in the product, however when using these resources directly from the protocol packages this property is null and they cannot be used.

These resources should create a default context if one is not given to make it usable in other scenarios.

Steps

  1. Install-package nuget.protocol.core.v3 3.2.0
  2. Use the FindPackageByIdResource
 var findResource = repo.GetResource<FindPackageByIdResource>();
 var findAllVersions = findResource.GetAllVersionsAsync(packageId, CancellationToken.None).Result;
@emgarten emgarten changed the title FindPackageByIdResource resources need a default cache context FindPackageByIdResource resources needs a default cache context Sep 9, 2015
@emgarten emgarten changed the title FindPackageByIdResource resources needs a default cache context FindPackageByIdResource resources needs a default cache context and logger Sep 9, 2015
@yishaigalatzer yishaigalatzer added this to the 3.3.0-Beta milestone Sep 9, 2015
@yishaigalatzer yishaigalatzer added the Functionality:SDK The NuGet client packages published to nuget.org label Sep 9, 2015
@yishaigalatzer yishaigalatzer modified the milestones: Client-VNext, 3.3.0-Beta Oct 27, 2015
@yishaigalatzer yishaigalatzer added Type:Feature Type:DCR Design Change Request and removed Type:Feature labels Oct 27, 2015
@harikmenon harikmenon modified the milestones: Client-VNext, Future Apr 19, 2016
@joelverhagen joelverhagen self-assigned this Aug 29, 2016
joelverhagen added a commit to NuGet/NuGet.Client that referenced this issue Aug 30, 2016
joelverhagen added a commit to NuGet/NuGet.Client that referenced this issue Aug 30, 2016
@joelverhagen joelverhagen modified the milestones: 3.6 Beta1, Future Aug 30, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Functionality:SDK The NuGet client packages published to nuget.org Type:DCR Design Change Request
Projects
None yet
Development

No branches or pull requests

4 participants