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

csvfile: use parse_kv() for args, add tests #70550

Merged

Conversation

relrod
Copy link
Member

@relrod relrod commented Jul 10, 2020

SUMMARY

Change:

  • Use parse_kv() for parsing in the csvfile lookup plugin. This allows
    us to handle multi-word search keys and filenames. Previously, the
    plugin split on space and so none of these things worked as expected.
  • Add integration tests for csvfile, testing a plethora of weird cases.

Test Plan:

  • New integration tests, CI

Tickets:

Signed-off-by: Rick Elrod rick@elrod.me

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

csvfile lookup plugin

@relrod relrod force-pushed the plugins/lookup/csvfile/parse_kv-and-test branch from 27f728f to 36134d5 Compare July 10, 2020 06:32
@ansibot ansibot added affects_2.11 bug This issue/PR relates to a bug. community_review In order to be merged, this PR must follow the community review workflow. needs_triage Needs a first human triage before being processed. support:community This issue/PR relates to code supported by the Ansible community. labels Jul 10, 2020
@relrod relrod force-pushed the plugins/lookup/csvfile/parse_kv-and-test branch from 36134d5 to 75b70f7 Compare July 10, 2020 07:03
@ansibot ansibot added core_review In order to be merged, this PR must follow the core review workflow. support:core This issue/PR relates to code supported by the Ansible Engineering Team. test This PR relates to tests. needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. and removed community_review In order to be merged, this PR must follow the community review workflow. core_review In order to be merged, this PR must follow the core review workflow. needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Jul 10, 2020
Copy link
Contributor

@Shrews Shrews left a comment

Choose a reason for hiding this comment

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

LGTM

@relrod relrod force-pushed the plugins/lookup/csvfile/parse_kv-and-test branch 2 times, most recently from c429a1e to 7ff3f92 Compare July 10, 2020 19:12
Change:
- Use parse_kv() for parsing in the csvfile lookup plugin. This allows
  us to handle multi-word search keys and filenames. Previously, the
  plugin split on space and so none of these things worked as expected.
- Add integration tests for csvfile, testing a plethora of weird cases.

Test Plan:
- New integration tests, CI

Tickets:
- Fixes ansible#70545

Signed-off-by: Rick Elrod <rick@elrod.me>
@relrod relrod force-pushed the plugins/lookup/csvfile/parse_kv-and-test branch from 7ff3f92 to 8e4defd Compare July 10, 2020 20:30
@relrod relrod merged commit 1b4fd23 into ansible:devel Jul 10, 2020
@s-hertel s-hertel removed the needs_triage Needs a first human triage before being processed. label Jul 14, 2020
@ansible ansible locked and limited conversation to collaborators Aug 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.11 bug This issue/PR relates to a bug. core_review In order to be merged, this PR must follow the core review workflow. support:community This issue/PR relates to code supported by the Ansible community. support:core This issue/PR relates to code supported by the Ansible Engineering Team. test This PR relates to tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add integration tests for the csvfile lookup plugin
5 participants