Skip to content

Current cli implementation for removing content doesn't handle duplicate filenames across multiple python content #1216

@DenisBY

Description

@DenisBY

Summary

Current cli implementation for removing content doesn't handle duplicate filenames across multiple python content

Steps to reproduce

  1. Create two pypi repos
  2. Upload the same file to both repos
  3. Try to remove the file from one of the repos

Expected behavior

The file is removed

Stacktrace/Error log

❯ pulp python repository content list --repository example | jq -r '.[].filename'                                
ml_services_utils-0.11.3.tar.gz
ml_services_utils-0.11.3-py3-none-any.whl

❯ pulp python repository content remove --repository example --filename ml_services_utils-0.11.3.tar.gz
Error: Multiple python packages found with {'filename': 'ml_services_utils-0.11.3.tar.gz'}.

Pulp and pulp-cli version info

❯ pulp --version                                                                                                   
Pulp3 Command Line Interface, Version 0.33.0
Plugin Versions:
  common: 0.33.0

Additonal context

https://discourse.pulpproject.org/t/how-to-remove-file-from-local-pypi-repository/2041

Metadata

Metadata

Assignees

Labels

bugSomething isn't working (template-set)

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions