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

Expose a way to exclude deps #658

Closed
wants to merge 11 commits into from
Closed

Expose a way to exclude deps #658

wants to merge 11 commits into from

Conversation

sivel
Copy link
Member

@sivel sivel commented Mar 14, 2024

Note: This is based off of #645 right now

At the moment, this is only fully wired up for python deps, as it was kind of an experiment.

---
version: 3.1

images:
  base_image:
    name: quay.io/centos/centos:stream9

dependencies:
  python_interpreter:
    package_system: python3.11
    python_path: /usr/bin/python3.11

  ansible_core:
    package_pip: ansible-core

  ansible_runner:
    package_pip: ansible-runner

  galaxy:
    collections:
      - name: community.docker

  exclude:
    python:
      - docker

TODO:

  • python excludes should work
  • excludes should not apply to user deps
  • system excludes should work
  • should there be a means to exclude collections?

NOTES:

  • Only supports exclusion of first level deps, does not offer a way to exclude deps of deps

@github-actions github-actions bot added the needs_triage New item that needs to be triaged label Mar 14, 2024
@@ -203,11 +218,20 @@ def simple_combine(reqs):
continue

base_line = line.split('#')[0].strip()
pkg_name = base_line.split()[0].lower()
if pkg_name in exclude:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if pkg_name in exclude:
if pkg_name in exclude and collection != 'user'::

@sivel
Copy link
Member Author

sivel commented Mar 25, 2024

Closing in favor of #663

@sivel sivel closed this Mar 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs_triage New item that needs to be triaged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant