豆豆友情提示:这是一个非官方 GitHub 代理镜像,主要用于网络测试或访问加速。请勿在此进行登录、注册或处理任何敏感信息。进行这些操作请务必访问官方网站 github.com。 Raw 内容也通过此代理提供。
Skip to content

FindPackageByIdResource resources needs a default cache context and logger #1357

@emgarten

Description

@emgarten

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;

Metadata

Metadata

Assignees

Labels

Functionality:SDKThe NuGet client packages published to nuget.orgType:DCRDesign Change Request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions