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

Handle situation where DOCS.options is None #59783

Merged
merged 1 commit into from
Jul 30, 2019

Conversation

sivel
Copy link
Member

@sivel sivel commented Jul 30, 2019

SUMMARY

Handle situation where DOCS.options is None

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

test/sanity/validate-modules/main.py

ADDITIONAL INFORMATION

Addresses

01:35 >>> Standard Error
01:35 Traceback (most recent call last):
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1231, in _validate_argument_spec
01:35     doc_options_arg = docs.get('options', {}).get(arg, {})
01:35 AttributeError: 'NoneType' object has no attribute 'get'
01:35 
01:35 During handling of the above exception, another exception occurred:
01:35 
01:35 Traceback (most recent call last):
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1768, in <module>
01:35     main()
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1667, in main
01:35     mv.validate()
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1548, in validate
01:35     self._validate_ansible_module_call(docs)
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1145, in _validate_ansible_module_call
01:35     self._validate_argument_spec(docs, spec, kwargs)
01:35   File "/root/ansible/test/sanity/validate-modules/validate-modules", line 1242, in _validate_argument_spec
01:35     "but this is incompatible with parameter type %r" % (arg, doc_options_arg.get('default'), _type))
01:35 UnboundLocalError: local variable 'doc_options_arg' referenced before assignment

@sivel sivel requested a review from mattclay July 30, 2019 14:14
@ansibot
Copy link
Contributor

ansibot commented Jul 30, 2019

@ansibot ansibot added affects_2.9 This issue/PR affects Ansible v2.9 bug This issue/PR relates to a bug. core_review In order to be merged, this PR must follow the core review workflow. needs_triage Needs a first human triage before being processed. support:core This issue/PR relates to code supported by the Ansible Engineering Team. test This PR relates to tests. traceback This issue/PR includes a traceback. labels Jul 30, 2019
@ansibot
Copy link
Contributor

ansibot commented Jul 30, 2019

@bcoca bcoca merged commit c06751f into ansible:devel Jul 30, 2019
@bcoca bcoca removed the needs_triage Needs a first human triage before being processed. label Jul 30, 2019
@ansible ansible locked and limited conversation to collaborators Aug 27, 2019
bcoca added a commit to bcoca/ansible that referenced this pull request Apr 13, 2022
s-hertel pushed a commit that referenced this pull request Apr 14, 2022
samccann pushed a commit to samccann/ansible that referenced this pull request Apr 18, 2022
sivel added a commit that referenced this pull request Apr 21, 2022
* Update reporting_bugs_and_features.rst (#77518)

(cherry picked from commit fa7c5d9)

* docs: Add porting guide for Ansible 6.0.0a1 (#77526)

(cherry picked from commit 0d9a580)

* Steering Committee: add new member (#77529)

(cherry picked from commit 553a226)

* Update pip example with standard lowercase http[s]_proxy env vars (#77515)

(cherry picked from commit 2ba39fc)

* Update docs to recommend the TTY for prompts over stderr (#77533)

(cherry picked from commit 789d29e)

* update python devel docs (#77499)

* update python devel docs

Co-authored-by: Sandra McCann <samccann@redhat.com>
(cherry picked from commit 2fc73a9)

* setup: remove 'any' as seemingly valid option (#77532)

fixes #59783

(cherry picked from commit 762d97f)

* Update developing_collections_shared.rst (#77497)

##### SUMMARY
Use of the meta/runtime.yml file to specify the ansible-core version for collections

##### ISSUE TYPE
- Docs Pull Request

+label: docsite_pr

(cherry picked from commit eef0a1c)

* Update developing_collections_structure.rst (#77496)

(cherry picked from commit 538a19b)

* Fix a broken link and some grammatical errors (#77531)

(cherry picked from commit 0c1cb0e)

* Add contributor path page (#77494)

Co-authored-by: Emmanuel Ugwu <32464178+ugwutotheeshoes@users.noreply.github.com>
(cherry picked from commit 3b0d74c)

Co-authored-by: Iheanacho Amarachi Sharon <58210919+Iheanacho-ai@users.noreply.github.com>
Co-authored-by: David Moreau Simard <moi@dmsimard.com>
Co-authored-by: Andrew Klychkov <aklychko@redhat.com>
Co-authored-by: Junegunn Choi <junegunn.c@gmail.com>
Co-authored-by: Matt Martz <matt@sivel.net>
Co-authored-by: Brian Coca <bcoca@users.noreply.github.com>
Co-authored-by: Emmanuel Ugwu <32464178+ugwutotheeshoes@users.noreply.github.com>
Co-authored-by: Kajsa Gauza <nimrod7@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.9 This issue/PR affects Ansible v2.9 bug This issue/PR relates to a bug. 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. traceback This issue/PR includes a traceback.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants