Page 2 of 2

Re: Cleaning up old version package

Published: August 24, 2026 - 1:21 PM
by Kevin-LH76
But this doesn't return all versions, only the current one?

The goal would be to retrieve all versions in order to browse through them and delete any that differ from the current one using your last link.

Re: Cleaning up old version package

Published: August 24, 2026 - 5:14 PM
by sfonteneau
This:

https://github.com/comitari/wapt-packag ... tup.py#L71

returns all packages

. And the local_package_list dictionary returns all the latest versions of packages for each host capability.

Basically, anything that doesn't appear in local_package_list but appears above it should be removed.

Re: Cleaning up old version package

Published: August 24, 2026 - 5:59 PM
by Kevin-LH76
`store_localstore = localstore.packages()` simply returns the latest version of the package from the repository, but how to say..
I'm deleting the different versions

Example: microsoft-defender-antivirus-definition-update is version - 1.457.318.0-320

store_localstore = localstore.packages() returns a line with version 1.457.318.0-320, whereas in the database there are 929 lines for this package.

How can I either delete all the different versions or at least the lists to remove them using `delete package`?

Because in your documentation, package delete requires a specific version
Removes a package of a specific version. The request must be a list []. It can take multiple packages separated by commas, .

Example:

wapt-get server-request /api/v3/packages_delete --method=POST --data="['ht-wapt-debian-gui_2.6.0.16977-2_0fce3ca2b61ebdbdc9b4b065cfe87176_PROD.wapt']" -c /opt/wapt/wapt-get.ini --wapt-server-user=user --wapt-server-passwd=password