GitHub user remibergsma opened a pull request:
https://github.com/apache/cloudstack/pull/1298
CLOUDSTACK-9204 Do not error when staticroute is already gone
When deleting a static route fails because it isn't there any morei
(KeyError), it should succeed instead.
Error seen:
```
[INFO] Processing JSON file static_routes.json.1451560145
Traceback (most recent call last):
File "/opt/cloud/bin/update_config.py", line 140, in <module>
process_file()
File "/opt/cloud/bin/update_config.py", line 52, in process_file
qf.load(None)
File "/opt/cloud/bin/merge.py", line 258, in load
proc = updateDataBag(self)
File "/opt/cloud/bin/merge.py", line 91, in _init_
self.process()
File "/opt/cloud/bin/merge.py", line 131, in process
dbag = self.process_staticroutes(self.db.getDataBag())
File "/opt/cloud/bin/merge.py", line 179, in process_staticroutes
return cs_staticroutes.merge(dbag, self.qFile.data)
File "/opt/cloud/bin/cs_staticroutes.py", line 26, in merge
del dbag[key]
KeyError: u'192.168.0.3'
```
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/remibergsma/cloudstack staticroute_delete_47
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/cloudstack/pull/1298.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1298
----
commit 779f4b36e03738a9eb1ffa4c474e9b4968cd7b72
Author: Remi Bergsma <[email protected]>
Date: 2015-12-31T13:08:14Z
CLOUDSTACK-9204 Do not error when staticroute is already gone
When deleting fails because it isn't there any morei (KeyError), it should
succeed instead.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---