{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/28682","repository_url":"https://api.github.com/repos/ansible/ansible","labels_url":"https://api.github.com/repos/ansible/ansible/issues/28682/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/28682/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/28682/events","html_url":"https://github.com/ansible/ansible/pull/28682","id":253022383,"number":28682,"title":"Udld interface","user":{"login":"saichint","id":15788941,"avatar_url":"https://avatars0.githubusercontent.com/u/15788941?v=4","gravatar_id":"","url":"https://api.github.com/users/saichint","html_url":"https://github.com/saichint","followers_url":"https://api.github.com/users/saichint/followers","following_url":"https://api.github.com/users/saichint/following{/other_user}","gists_url":"https://api.github.com/users/saichint/gists{/gist_id}","starred_url":"https://api.github.com/users/saichint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saichint/subscriptions","organizations_url":"https://api.github.com/users/saichint/orgs","repos_url":"https://api.github.com/users/saichint/repos","events_url":"https://api.github.com/users/saichint/events{/privacy}","received_events_url":"https://api.github.com/users/saichint/received_events","type":"User","site_admin":false},"labels":[{"id":562292166,"url":"https://api.github.com/repos/ansible/ansible/labels/affects_2.4","name":"affects_2.4","color":"ededed","default":false},{"id":48276098,"url":"https://api.github.com/repos/ansible/ansible/labels/bugfix_pull_request","name":"bugfix_pull_request","color":"ded270","default":false},{"id":499635167,"url":"https://api.github.com/repos/ansible/ansible/labels/c:module_utils/","name":"c:module_utils/","color":"b60205","default":false},{"id":534371273,"url":"https://api.github.com/repos/ansible/ansible/labels/merge_commit","name":"merge_commit","color":"e99695","default":false},{"id":496359346,"url":"https://api.github.com/repos/ansible/ansible/labels/module","name":"module","color":"1d76db","default":false},{"id":231201931,"url":"https://api.github.com/repos/ansible/ansible/labels/needs_rebase","name":"needs_rebase","color":"eb6420","default":false},{"id":503572087,"url":"https://api.github.com/repos/ansible/ansible/labels/needs_triage","name":"needs_triage","color":"0e8a16","default":false},{"id":339653091,"url":"https://api.github.com/repos/ansible/ansible/labels/networking","name":"networking","color":"c7def8","default":false},{"id":669761792,"url":"https://api.github.com/repos/ansible/ansible/labels/support:network","name":"support:network","color":"ededed","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-08-25T21:28:12Z","updated_at":"2017-08-28T21:18:35Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ansible/ansible/pulls/28682","html_url":"https://github.com/ansible/ansible/pull/28682","diff_url":"https://github.com/ansible/ansible/pull/28682.diff","patch_url":"https://github.com/ansible/ansible/pull/28682.patch"},"body":"##### SUMMARY\r\nFixes #28299\r\n\r\n##### ISSUE TYPE\r\n - Bugfix Pull Request\r\n\r\n##### COMPONENT NAME\r\nnxos_udld_interface\r\n\r\n##### ANSIBLE VERSION\r\n```\r\nansible 2.4.0 (devel 54cd641df4) last updated 2017/07/19 18:06:44 (GMT -400)\r\n  config file = None\r\n  configured module search path = [u'/root/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']\r\n  ansible python module location = /root/p2/Projects/nxos_ansible/p1_ansible/lib/ansible\r\n  executable location = /root/p2/Projects/nxos_ansible/p1_ansible/bin/ansible\r\n  python version = 2.7.6 (default, Oct 26 2016, 20:30:19) [GCC 4.8.4]\r\n```\r\n\r\n##### ADDITIONAL INFORMATION\r\n- As mentioned in the issue, the copper vs fiber decision is not reliable and it depends on the transceiver when connected. Since we have one set of commands for copper vs another set for fiber, one solution is to run first set of commands and see if it throws any error. If an error is thrown and the error string matches with the known error for copper vs fiber, run the 2nd set of commands. This change is made in the nxos_udld_interface.py file\r\n- When the command is not successful, currently the nxos.py code is just exiting right away. Since we need the error string to check if we need to use one set of commands vs the other set, the errors need to be propagated to the application code at higher level to make decisions. nxos.py changes are basically to propagate the errors back to the top level code. \r\n- Going forward this solution can be used for any other errors which should be handled by higher layers. Please review and comment if this solution is ok. If this is not acceptable, please suggest if there is a better way. I can call up for a phone meeting if necessary \r\n\r\nOutput after the fix (the interface which is being tested is copper on some devices and fiber on others)\r\n```\r\nPLAY RECAP ****************************************************************************************************************************************************\r\ncamden-nx-2.cisco.com      : ok=44   changed=12   unreachable=0    failed=0                                                                                    \r\ndplus-nx-2.cisco.com       : ok=42   changed=12   unreachable=0    failed=0                                                                                    \r\nevergreen-nx-2.cisco.com   : ok=42   changed=12   unreachable=0    failed=0                                                                                    \r\nfreeport-nx-2.cisco.com    : ok=42   changed=12   unreachable=0    failed=0                                                                                    \r\ngreensboro-nx-2.cisco.com  : ok=42   changed=12   unreachable=0    failed=0                                                                                    \r\nn3k-173.cisco.com          : ok=41   changed=12   unreachable=0    failed=0                                                                                    \r\nn3x-161.cisco.com          : ok=41   changed=12   unreachable=0    failed=0                                                                                    \r\nn7k-99.cisco.com           : ok=42   changed=13   unreachable=0    failed=0                                                                                    \r\nn9k-108.cisco.com          : ok=42   changed=12   unreachable=0    failed=0\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/ansible/ansible/issues/comments/325485014","html_url":"https://github.com/ansible/ansible/pull/28682#issuecomment-325485014","issue_url":"https://api.github.com/repos/ansible/ansible/issues/28682","id":325485014,"user":{"login":"ansibot","id":6585283,"avatar_url":"https://avatars0.githubusercontent.com/u/6585283?v=4","gravatar_id":"","url":"https://api.github.com/users/ansibot","html_url":"https://github.com/ansibot","followers_url":"https://api.github.com/users/ansibot/followers","following_url":"https://api.github.com/users/ansibot/following{/other_user}","gists_url":"https://api.github.com/users/ansibot/gists{/gist_id}","starred_url":"https://api.github.com/users/ansibot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ansibot/subscriptions","organizations_url":"https://api.github.com/users/ansibot/orgs","repos_url":"https://api.github.com/users/ansibot/repos","events_url":"https://api.github.com/users/ansibot/events{/privacy}","received_events_url":"https://api.github.com/users/ansibot/received_events","type":"User","site_admin":false},"created_at":"2017-08-28T21:18:35Z","updated_at":"2017-08-28T21:18:35Z","body":"@saichint this PR contains the following merge commits:\n\n* https://github.com/ansible/ansible/commit/182f0300755d3b66154f08c64e252ccfc22fed30\n\nPlease [rebase your branch](http://docs.ansible.com/ansible/dev_guide/developing_rebasing.html) to remove these commits.\n\n[click here for bot help](https://github.com/ansible/ansibullbot/blob/master/ISSUE_HELP.md)\n<!--- boilerplate: merge_commit_notify --->"}}
{"actor":{"display_login":"ansibot"}}