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

ini_file: add allow_no_value param #24442

Merged
merged 2 commits into from
Mar 5, 2018
Merged

ini_file: add allow_no_value param #24442

merged 2 commits into from
Mar 5, 2018

Conversation

fridim
Copy link
Contributor

@fridim fridim commented May 10, 2017

SUMMARY

Fixes #24294

ini_file: add allow_no_value param

  • add the 'allow_no_value' param to allow option with no value in ini file.
  • add tests related to this param :
    • test add option with no value
    • test add options with no values in loop
    • test change option with no value to option with value
    • test change option with value to option with no value
    • test remove option with no value
related PR

Closes #24434 EDIT: other PR already merged

This pull request contains work done on #24434
#24434 can be merged separately. I will then rebase this PR against devel.
EDIT: other PR already merged

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

lib/ansible/modules/files/ini_file.py

ANSIBLE VERSION
ansible 2.4.0 (issue-24294 aedca5b413) last updated 2017/05/10 14:39:19 (GMT +200)                                                                                                            
  config file = /etc/ansible/ansible.cfg                                                                                                                                                      
  configured module search path = ['/home/fridim/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']                                                                             
  ansible python module location = /home/fridim/sync/dev/ansible/lib/ansible                                                                                                                  
  executable location = /home/fridim/sync/dev/ansible/bin/ansible                                                                                                                             
  python version = 3.6.1 (default, Mar 27 2017, 00:27:06) [GCC 6.3.1 20170306]
ADDITIONAL INFORMATION

@ansibot
Copy link
Contributor

ansibot commented May 10, 2017

@ansibot ansibot added affects_2.4 This issue/PR affects Ansible v2.4 community_review In order to be merged, this PR must follow the community review workflow. feature_pull_request module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. labels May 10, 2017
@jpmens
Copy link
Contributor

jpmens commented May 10, 2017

shipit

@ansibot ansibot removed the needs_triage Needs a first human triage before being processed. label May 10, 2017
@ansibot ansibot added stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. support:community This issue/PR relates to code supported by the Ansible community. labels Jun 23, 2017
@fridim
Copy link
Contributor Author

fridim commented Aug 11, 2017

any update ?

@ansibot ansibot removed the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Aug 16, 2017
@fridim
Copy link
Contributor Author

fridim commented Aug 16, 2017

@ansibot ansibot added the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Aug 24, 2017
@ansibot ansibot added the test This PR relates to tests. label Sep 9, 2017
@ansibot ansibot added needs_rebase https://docs.ansible.com/ansible/devel/dev_guide/developing_rebasing.html 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. labels Sep 17, 2017
@ansibot
Copy link
Contributor

ansibot commented Oct 2, 2017

@fridim this PR contains the following merge commits:

Please rebase your branch to remove these commits.

click here for bot help

@ansibot ansibot added merge_commit This PR contains at least one merge commit. Please resolve! and removed stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. labels Oct 2, 2017
@ansibot
Copy link
Contributor

ansibot commented Oct 2, 2017

The test ansible-test sanity --test validate-modules [?] failed with the following error:

lib/ansible/modules/files/ini_file.py:0:0: E309 version_added for new option (allow_no_value) should be 2.5. Currently 2.4

click here for bot help

@ansibot ansibot added the ci_verified Changes made in this PR are causing tests to fail. label Oct 2, 2017
@fridim
Copy link
Contributor Author

fridim commented Oct 2, 2017

rebase and cleanup into one commit done.

@ansibot ansibot removed the ci_verified Changes made in this PR are causing tests to fail. label Oct 2, 2017
@ansibot ansibot removed merge_commit This PR contains at least one merge commit. Please resolve! needs_rebase https://docs.ansible.com/ansible/devel/dev_guide/developing_rebasing.html labels Oct 2, 2017
Fixes ansible#24294

- add the 'allow_no_value' param to allow option with no value in ini file.
- add tests related to this param :
  - test add option with no value
  - test add options with no values in loop
  - test change option with no value to option with value
  - test change option with value to option with no value
  - test remove option with no value
@ansibot ansibot added community_review In order to be merged, this PR must follow the community review workflow. and removed needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Oct 2, 2017
@ansibot ansibot added the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Oct 10, 2017
@fridim
Copy link
Contributor Author

fridim commented Feb 4, 2018

Any update ?

@ansibot ansibot added feature This issue/PR relates to a feature request. and removed feature_pull_request labels Mar 2, 2018
@ansibot
Copy link
Contributor

ansibot commented Mar 5, 2018

The test ansible-test sanity --test validate-modules [explain] failed with 2 errors:

lib/ansible/modules/files/ini_file.py:0:0: E309 version_added for new option (allow_no_value) should be 2.6. Currently 2.5
lib/ansible/modules/files/ini_file.py:0:0: E325 argument_spec for "allow_no_value" defines type="bool" but documentation does not

click here for bot help

@ansibot ansibot added ci_verified Changes made in this PR are causing tests to fail. 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. stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. labels Mar 5, 2018
@resmo resmo self-assigned this Mar 5, 2018
@ansibot ansibot added community_review In order to be merged, this PR must follow the community review workflow. and removed ci_verified Changes made in this PR are causing tests to fail. needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Mar 5, 2018
Copy link
Contributor

@resmo resmo left a comment

Choose a reason for hiding this comment

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

shipit

@resmo resmo merged commit daeec92 into ansible:devel Mar 5, 2018
@resmo
Copy link
Contributor

resmo commented Mar 5, 2018

Thanks!

willthames pushed a commit to willthames/ansible that referenced this pull request Mar 6, 2018
@ansible ansible locked and limited conversation to collaborators Apr 26, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.4 This issue/PR affects Ansible v2.4 community_review In order to be merged, this PR must follow the community review workflow. feature This issue/PR relates to a feature request. module This issue/PR relates to a module. support:community This issue/PR relates to code supported by the Ansible community. test This PR relates to tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow ini_file module to handle keys without values
4 participants