{"action":"created","issue":{"url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/29","repository_url":"https://api.github.com/repos/napalm-automation/napalm-junos","labels_url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/29/labels{/name}","comments_url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/29/comments","events_url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/29/events","html_url":"https://github.com/napalm-automation/napalm-junos/issues/29","id":163116530,"number":29,"title":"Cannot close and reopen session","user":{"login":"mirceaulinic","id":16694679,"avatar_url":"https://avatars.githubusercontent.com/u/16694679?v=3","gravatar_id":"","url":"https://api.github.com/users/mirceaulinic","html_url":"https://github.com/mirceaulinic","followers_url":"https://api.github.com/users/mirceaulinic/followers","following_url":"https://api.github.com/users/mirceaulinic/following{/other_user}","gists_url":"https://api.github.com/users/mirceaulinic/gists{/gist_id}","starred_url":"https://api.github.com/users/mirceaulinic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirceaulinic/subscriptions","organizations_url":"https://api.github.com/users/mirceaulinic/orgs","repos_url":"https://api.github.com/users/mirceaulinic/repos","events_url":"https://api.github.com/users/mirceaulinic/events{/privacy}","received_events_url":"https://api.github.com/users/mirceaulinic/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-06-30T09:05:04Z","updated_at":"2016-07-06T10:04:34Z","closed_at":"2016-07-06T10:04:34Z","body":"### Description of Issue/Question\r\nCannot close and reopen session with a device because the config object ```cu``` is already binded.\r\n\r\n### napalm-junos version\r\n```\r\nnapalm-junos==0.2.1\r\n```\r\n\r\n### JunOS version\r\n```\r\nany\r\n```\r\n\r\n### Steps to Reproduce the Issue\r\n\r\n- Open connection with the device\r\n- Close the conection\r\n- Open it again\r\n\r\n### Error Traceback\r\n\r\n```\r\n>>> j.open()\r\n>>> j.close()\r\n>>> j.open()\r\nTraceback (most recent call last):\r\n  File \"<stdin>\", line 1, in <module>\r\n  File \"/state/home/mircea/napalm-junos/napalm_junos/junos.py\", line 73, in open\r\n    self.device.bind(cu=Config)\r\n  File \"/state/home/mircea/napalm-test/local/lib/python2.7/site-packages/junos_eznc-1.3.1-py2.7.egg/jnpr/junos/device.py\", line 756, in bind\r\n    name)\r\nValueError: requested attribute name cu already exists\r\n```\r\n\r\n### Solution\r\n\r\nMust remove the binding during ```close```."},"comment":{"url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/comments/230731050","html_url":"https://github.com/napalm-automation/napalm-junos/issues/29#issuecomment-230731050","issue_url":"https://api.github.com/repos/napalm-automation/napalm-junos/issues/29","id":230731050,"user":{"login":"mirceaulinic","id":16694679,"avatar_url":"https://avatars.githubusercontent.com/u/16694679?v=3","gravatar_id":"","url":"https://api.github.com/users/mirceaulinic","html_url":"https://github.com/mirceaulinic","followers_url":"https://api.github.com/users/mirceaulinic/followers","following_url":"https://api.github.com/users/mirceaulinic/following{/other_user}","gists_url":"https://api.github.com/users/mirceaulinic/gists{/gist_id}","starred_url":"https://api.github.com/users/mirceaulinic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirceaulinic/subscriptions","organizations_url":"https://api.github.com/users/mirceaulinic/orgs","repos_url":"https://api.github.com/users/mirceaulinic/repos","events_url":"https://api.github.com/users/mirceaulinic/events{/privacy}","received_events_url":"https://api.github.com/users/mirceaulinic/received_events","type":"User","site_admin":false},"created_at":"2016-07-06T10:04:34Z","updated_at":"2016-07-06T10:04:34Z","body":"Solved via https://github.com/napalm-automation/napalm-junos/pull/30"}}
{"actor":{"display_login":"mirceaulinic"}}