weave icon indicating copy to clipboard operation
weave copied to clipboard

chore(artifacts): DNM update artifacts_fs to optionally query for manifest and files via artifactID

Open ibindlish opened this issue 11 months ago • 1 comments

Use case: We require that when a user links an artifact from their team entity to a collection in their org registry, it be accessible to view and download to all users in the org. This requires the download url to be independent of the source artifact's entity name, since that is hidden from users that don't have access to the underlying artifact's project and entity names.

Solution: Access the artifact via the linked project path: linked-entity/linked-project/linked-collection -> memberships -> artifactVersion

Current: The W1 op, opArtifactVersionFiles(), iterates over the artifact's manifest to return a list of files and their associated download urls (these are not signed urls, these are just urls that hit a gorilla endpoint that ultimately results in the file download).

  • However, unlike the file handler implementation in JS, the python version queries for the manifest via the entity, project and artifact name instead of just using the artifactID
  • Queries for the artifact's entity name to build the download url

This PR changes the above requirements and tries to make the artifact file retrieval process independent of its entity.

Corresponding W0 change: https://github.com/wandb/core/pull/20157

Testing: So far, have only tested using the files tab in the Artifacts panels.

ibindlish avatar Mar 14 '24 22:03 ibindlish

Working on new solution instead: https://github.com/wandb/weave/pull/1601

ibindlish avatar Jun 11 '24 19:06 ibindlish