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

Filter not correctly working or no blacklisting of packages possible #1234

Open
DevGKOne opened this issue Nov 30, 2023 · 2 comments
Open

Filter not correctly working or no blacklisting of packages possible #1234

DevGKOne opened this issue Nov 30, 2023 · 2 comments
Assignees
Labels
please confirm resolved We believe the issue is resolved ! if so, please close the issue, thanks ;-)

Comments

@DevGKOne
Copy link

Detailed Description

aptly mirror create -architectures=amd64 -filter='!(Name (~ .massscan.)),!(Name (~ .pnscan.)),!(Name (~ .price.app.)),!(Name (~ .libclanlib.))' -filter-with-deps jammy-main2 http://archive.ubuntu.com/ubuntu jammy main restricted universe

Downloading http://archive.ubuntu.com/ubuntu/pool/universe/c/clanlib/libclanlib-dev_1.0~svn3827-8_amd64.deb...
Downloading http://archive.ubuntu.com/ubuntu/pool/universe/p/price.app/price.app_1.3.0-5build1_amd64.deb...
Downloading http://archive.ubuntu.com/ubuntu/pool/universe/m/masscan/masscan_1.3.2+ds1-1_amd64.deb...
Downloading http://archive.ubuntu.com/ubuntu/pool/universe/p/pnscan/pnscan_1.14.1-1_amd64.deb...
Error downloading http://archive.ubuntu.com/ubuntu/pool/universe/p/price.app/price.app_1.3.0-5build1_amd64.deb: HTTP code 403 while fetching http://archive.ubuntu.com/ubuntu/pool/universe/p/price.app/price.app_1.3.0-5build1_amd64.deb retrying...
Error downloading http://archive.ubuntu.com/ubuntu/pool/universe/p/pnscan/pnscan_1.14.1-1_amd64.deb: HTTP code 403 while fetching http://archive.ubuntu.com/ubuntu/pool/universe/p/pnscan/pnscan_1.14.1-1_amd64.deb retrying...
Error downloading http://archive.ubuntu.com/ubuntu/pool/universe/m/masscan/masscan_1.3.2+ds1-1_amd64.deb: HTTP code 403 while fetching http://archive.ubuntu.com/ubuntu/pool/universe/m/masscan/masscan_1.3.2+ds1-1_amd64.deb retrying...
Retrying 0 http://archive.ubuntu.com/ubuntu/pool/universe/p/price.app/price.app_1.3.0-5build1_amd64.deb...
Giving up on http://archive.ubuntu.com/ubuntu/pool/universe/p/price.app/price.app_1.3.0-5build1_amd64.deb...
Retrying 0 http://archive.ubuntu.com/ubuntu/pool/universe/p/pnscan/pnscan_1.14.1-1_amd64.deb...
Giving up on http://archive.ubuntu.com/ubuntu/pool/universe/p/pnscan/pnscan_1.14.1-1_amd64.deb...
Retrying 0 http://archive.ubuntu.com/ubuntu/pool/universe/m/masscan/masscan_1.3.2+ds1-1_amd64.deb...
Giving up on http://archive.ubuntu.com/ubuntu/pool/universe/m/masscan/masscan_1.3.2+ds1-1_amd64.deb...

Context

Cannot Create a mirror and cannot blacklist any packages.

infrastructure (Antivirus scan) is blocking some packages and cannot prevent aptly from trying to download this packages.
Or how can I create snapshot of mirrors despite of download errors (force options ??)

Your Environment

Ubuntu Jammy with aptly 1.50, mirroring Ubuntu jammy universe

@neolynx
Copy link
Member

neolynx commented Apr 11, 2024

I think the correct syntax for the regex would be !(Name (~ .*masscan.*))...

could you try with the asterisk (*) ? also note, there is only 2 s in the package name

@neolynx neolynx self-assigned this Aug 12, 2024
@neolynx
Copy link
Member

neolynx commented Aug 13, 2024

I tried to reproduce it, here are the filter expressions that work (I only tried 2 packages, with correct regular expression and boolean logic):

  • -filter='!Name (~ .*masscan.*), !Name (~ .*price.app.*)'
  • -filter='!(Name (~ .*masscan.*) | Name (~ .*price.app.*))'

also, I had to remove the argument -filter-with-deps, as it seems to bring filtered out the packages in again.

@neolynx neolynx added the please confirm resolved We believe the issue is resolved ! if so, please close the issue, thanks ;-) label Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
please confirm resolved We believe the issue is resolved ! if so, please close the issue, thanks ;-)
Projects
None yet
Development

No branches or pull requests

3 participants
@neolynx @DevGKOne and others