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

tag_filter and tag_regex won't ignore whitespace-only values #428

Open
risicle opened this issue Jun 13, 2024 · 0 comments
Open

tag_filter and tag_regex won't ignore whitespace-only values #428

risicle opened this issue Jun 13, 2024 · 0 comments
Labels

Comments

@risicle
Copy link

risicle commented Jun 13, 2024

Describe the bug

A tag_filter or tag_regex value of e.g. a single space will activate the filtering mechanism.

Why does this matter? AWS SSM Parameter Store won't accept zero-length strings as values, so without some trickery it's not possible to add an "optional" tag filter variable to your reusable pipeline if you're using parameter store.

I say "without some trickery" because I think I've found a workaround: setting the parameter store value to a single newline character which does seem to get stripped somewhere along the line and allow the filter to be disabled this way. But I suspect this is fragile and by no means guaranteed behaviour, so it would be nice to ensure this works without trickery.

Reproduction steps

  1. Be using Parameter Store as your credentials backend
  2. Configure a git-resource with e.g. tag_filter: ((pipeline_tag_filter))
  3. Set the appropriate pipeline_tag_filter parameter store value to a single space
  4. Watch the checks ignore untagged commits

Expected behavior

All commits should be picked up.

Additional context

No response

@risicle risicle added the bug label Jun 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant