)]}'
{"monasca_notification/plugins/hipchat_notifier.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"11161f1470bacb37f734a145d43222e2b6cb8295","unresolved":false,"context_lines":[{"line_number":13,"context_line":"# See the License for the specific language governing permissions and"},{"line_number":14,"context_line":"# limitations under the License."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"import json"},{"line_number":17,"context_line":"from jinja2 import Template"},{"line_number":18,"context_line":"import requests"},{"line_number":19,"context_line":"import urlparse"}],"source_content_type":"text/x-python","patch_set":3,"id":"bacf61ea_4c38a13d","line":16,"updated":"2016-08-01 05:31:47.000000000","message":"Do you think it\u0027d be possible to use monasca-common json capabilities or use ujson as alternative to json.","commit_id":"024f25b2ad878653a27490fbd82ba6d78737e0aa"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"c275ebe82143f95b5701706f7a168f1d5c69c047","unresolved":false,"context_lines":[{"line_number":13,"context_line":"# See the License for the specific language governing permissions and"},{"line_number":14,"context_line":"# limitations under the License."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"import json"},{"line_number":17,"context_line":"from jinja2 import Template"},{"line_number":18,"context_line":"import requests"},{"line_number":19,"context_line":"import urlparse"}],"source_content_type":"text/x-python","patch_set":3,"id":"bacf61ea_b57500cc","line":16,"in_reply_to":"bacf61ea_4c38a13d","updated":"2016-08-01 15:51:30.000000000","message":"Sure. I will change it","commit_id":"024f25b2ad878653a27490fbd82ba6d78737e0aa"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"11161f1470bacb37f734a145d43222e2b6cb8295","unresolved":false,"context_lines":[{"line_number":69,"context_line":"        hipchat_request_format \u003d hipchat_request_format[\"hipchat_format\"]"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # Templatize the message object"},{"line_number":72,"context_line":"        if hipchat_request_format.get(\"message\"):"},{"line_number":73,"context_line":"            template \u003d Template(hipchat_request_format[\"message\"])"},{"line_number":74,"context_line":"            hipchat_request_format[\"message\"] \u003d template.render(notification\u003dnotification).replace(\"\\n\",\"\")"},{"line_number":75,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"bacf61ea_4c01c169","line":72,"updated":"2016-08-01 05:31:47.000000000","message":"If this is meant to check if message is in the hipchat_request_format you should either do\n\n  if \u0027message\u0027 in hipchat_requet_format and hipchat_request_format.get(\u0027message\u0027, None)\n\nor simple save the value into variable\n\n  hipchat_request_format_msg \u003d hipchat_request_format.get(\u0027message\u0027, None)\n  if hipchat_request_format_msg:\n    # code here","commit_id":"024f25b2ad878653a27490fbd82ba6d78737e0aa"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"c275ebe82143f95b5701706f7a168f1d5c69c047","unresolved":false,"context_lines":[{"line_number":69,"context_line":"        hipchat_request_format \u003d hipchat_request_format[\"hipchat_format\"]"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # Templatize the message object"},{"line_number":72,"context_line":"        if hipchat_request_format.get(\"message\"):"},{"line_number":73,"context_line":"            template \u003d Template(hipchat_request_format[\"message\"])"},{"line_number":74,"context_line":"            hipchat_request_format[\"message\"] \u003d template.render(notification\u003dnotification).replace(\"\\n\",\"\")"},{"line_number":75,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"bacf61ea_d816eb4a","line":72,"in_reply_to":"bacf61ea_4c01c169","updated":"2016-08-01 15:51:30.000000000","message":"I can do it. Once I got a comment saying   object.get(\"Something\") will return None if it is not there, so no need to add explicit \"None\". I prefer explicit as you have commented out","commit_id":"024f25b2ad878653a27490fbd82ba6d78737e0aa"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"11161f1470bacb37f734a145d43222e2b6cb8295","unresolved":false,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"        # If you have both card and message, precedence will be based on hipchat api implementation:w"},{"line_number":77,"context_line":"        # Templatize the card object if it has one"},{"line_number":78,"context_line":"        if hipchat_request_format.get(\"card\"):"},{"line_number":79,"context_line":"            template \u003d Template(hipchat_request_format[\"card\"])"},{"line_number":80,"context_line":"            card_message \u003d template.render(notification\u003dnotification).replace(\"\\n\",\"\")"},{"line_number":81,"context_line":"            hipchat_request_format[\"card\"] \u003d json.loads(card_message)"}],"source_content_type":"text/x-python","patch_set":3,"id":"bacf61ea_8cf7398a","line":78,"updated":"2016-08-01 05:31:47.000000000","message":"Same comment as above.","commit_id":"024f25b2ad878653a27490fbd82ba6d78737e0aa"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"053b4c35159ef776ea617efc95a7c769cbf7a269","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def _build_custom_hipchat_message(self, notification):"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"        with open(self._config.get(\"custom_formatter\")) as f:"},{"line_number":66,"context_line":"            hipchat_request_format \u003d yaml.load(f)"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        # Remove the top element"},{"line_number":69,"context_line":"        hipchat_request_format \u003d hipchat_request_format[\"hipchat_format\"]"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_3d54abfd","line":66,"range":{"start_line":65,"start_character":0,"end_line":66,"end_character":49},"updated":"2016-09-15 17:36:11.000000000","message":"Need to handle the case of this file not being there.","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"286c6ab57a9418ad82def8bf4c5e9ece9e284341","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def _build_custom_hipchat_message(self, notification):"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"        with open(self._config.get(\"custom_formatter\")) as f:"},{"line_number":66,"context_line":"            hipchat_request_format \u003d yaml.load(f)"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        # Remove the top element"},{"line_number":69,"context_line":"        hipchat_request_format \u003d hipchat_request_format[\"hipchat_format\"]"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_4e13aa5c","line":66,"range":{"start_line":65,"start_character":0,"end_line":66,"end_character":49},"in_reply_to":"7a8ec9b2_3d54abfd","updated":"2016-09-20 17:28:39.000000000","message":"Done","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"053b4c35159ef776ea617efc95a7c769cbf7a269","unresolved":false,"context_lines":[{"line_number":123,"context_line":"        if (self._config.get(\"ca_certs\")):"},{"line_number":124,"context_line":"            verify \u003d self._config.get(\"ca_certs\")"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        proxyDict \u003d None"},{"line_number":127,"context_line":"        if (self._config.get(\"proxy\")):"},{"line_number":128,"context_line":"            proxyDict \u003d {\"https\": self._config.get(\"proxy\")}"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"        try:"},{"line_number":131,"context_line":"            # Posting on the given URL"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_1d760fa4","line":128,"range":{"start_line":126,"start_character":0,"end_line":128,"end_character":60},"updated":"2016-09-15 17:36:11.000000000","message":"This is not in the commit message","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"286c6ab57a9418ad82def8bf4c5e9ece9e284341","unresolved":false,"context_lines":[{"line_number":123,"context_line":"        if (self._config.get(\"ca_certs\")):"},{"line_number":124,"context_line":"            verify \u003d self._config.get(\"ca_certs\")"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        proxyDict \u003d None"},{"line_number":127,"context_line":"        if (self._config.get(\"proxy\")):"},{"line_number":128,"context_line":"            proxyDict \u003d {\"https\": self._config.get(\"proxy\")}"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"        try:"},{"line_number":131,"context_line":"            # Posting on the given URL"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_6e0ea633","line":128,"range":{"start_line":126,"start_character":0,"end_line":128,"end_character":60},"in_reply_to":"7a8ec9b2_1d760fa4","updated":"2016-09-20 17:28:39.000000000","message":"Done","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"3189ad79175d9b2fd6358cff57b53e87ca91d22f","unresolved":false,"context_lines":[{"line_number":58,"context_line":"    def _build_hipchat_message(self, notification):"},{"line_number":59,"context_line":"        if self._config.get(\"custom_formatter\"):"},{"line_number":60,"context_line":"            try:"},{"line_number":61,"context_line":"                with open(self._config.get(\"custom_formatter\")) as f:"},{"line_number":62,"context_line":"                    hipchat_request_format \u003d yaml.load(f)"},{"line_number":63,"context_line":"                    return self._build_custom_hipchat_message(notification, hipchat_request_format)"},{"line_number":64,"context_line":"            except:"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa6399be_7838363e","line":61,"updated":"2016-10-19 05:05:59.000000000","message":"do we want to load this file for every possible notification ?","commit_id":"bc2b35fbfe5c5cb31ca0346cb95cb1b382929746"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"3189ad79175d9b2fd6358cff57b53e87ca91d22f","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        if self._config.get(\"custom_formatter\"):"},{"line_number":60,"context_line":"            try:"},{"line_number":61,"context_line":"                with open(self._config.get(\"custom_formatter\")) as f:"},{"line_number":62,"context_line":"                    hipchat_request_format \u003d yaml.load(f)"},{"line_number":63,"context_line":"                    return self._build_custom_hipchat_message(notification, hipchat_request_format)"},{"line_number":64,"context_line":"            except:"},{"line_number":65,"context_line":"                self._log.exception(\"Error reading custom formatter for hipchat. Using default formatting\")"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa6399be_78b756f5","line":62,"updated":"2016-10-19 05:05:59.000000000","message":"yaml.safe_load","commit_id":"bc2b35fbfe5c5cb31ca0346cb95cb1b382929746"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"625b5f7487ed7c6dd2a02c4b4142695b0a785b8d","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        if self._config.get(\"custom_formatter\"):"},{"line_number":60,"context_line":"            try:"},{"line_number":61,"context_line":"                with open(self._config.get(\"custom_formatter\")) as f:"},{"line_number":62,"context_line":"                    hipchat_request_format \u003d yaml.load(f)"},{"line_number":63,"context_line":"                    return self._build_custom_hipchat_message(notification, hipchat_request_format)"},{"line_number":64,"context_line":"            except:"},{"line_number":65,"context_line":"                self._log.exception(\"Error reading custom formatter for hipchat. Using default formatting\")"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa6399be_62b4d1f1","line":62,"in_reply_to":"fa6399be_78b756f5","updated":"2016-10-31 22:25:07.000000000","message":"Yes, agree with Tomasz, this should be yaml.safe_load.","commit_id":"bc2b35fbfe5c5cb31ca0346cb95cb1b382929746"}],"monasca_notification/plugins/hipchatformat.yml":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"053b4c35159ef776ea617efc95a7c769cbf7a269","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Refer the following url for request parameters."},{"line_number":2,"context_line":"# https://www.hipchat.com/docs/apiv2/method/send_room_notification"},{"line_number":3,"context_line":"# https://developer.atlassian.com/hipchat/guide/sending-messages -- List html tags supported"},{"line_number":4,"context_line":"# You can either use card or message to send the notification. Message will work with all the"}],"source_content_type":"text/x-yaml","patch_set":14,"id":"7a8ec9b2_bdaefbe3","line":1,"updated":"2016-09-15 17:36:11.000000000","message":"Probably need the copyright here","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"}],"monasca_notification/plugins/slack_notifier.py":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"053b4c35159ef776ea617efc95a7c769cbf7a269","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        if (self._config.get(\"ca_certs\")):"},{"line_number":89,"context_line":"            verify \u003d self._config.get(\"ca_certs\")"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        proxyDict \u003d None"},{"line_number":92,"context_line":"        if (self._config.get(\"proxy\")):"},{"line_number":93,"context_line":"            proxyDict \u003d {\"https\": self._config.get(\"proxy\")}"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        try:"},{"line_number":96,"context_line":"            # Posting on the given URL"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_dd8e6778","line":93,"range":{"start_line":91,"start_character":0,"end_line":93,"end_character":60},"updated":"2016-09-15 17:36:11.000000000","message":"Not in the commit message.","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"286c6ab57a9418ad82def8bf4c5e9ece9e284341","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        if (self._config.get(\"ca_certs\")):"},{"line_number":89,"context_line":"            verify \u003d self._config.get(\"ca_certs\")"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        proxyDict \u003d None"},{"line_number":92,"context_line":"        if (self._config.get(\"proxy\")):"},{"line_number":93,"context_line":"            proxyDict \u003d {\"https\": self._config.get(\"proxy\")}"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        try:"},{"line_number":96,"context_line":"            # Posting on the given URL"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_ae2fce86","line":93,"range":{"start_line":91,"start_character":0,"end_line":93,"end_character":60},"in_reply_to":"7a8ec9b2_dd8e6778","updated":"2016-09-20 17:28:39.000000000","message":"Done","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"}],"tests/test_hipchat_notifications.py":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"053b4c35159ef776ea617efc95a7c769cbf7a269","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        self.assertRegexpMatches(error, \"Error trying to send to hipchat  on URL\")"},{"line_number":117,"context_line":"        self.assertFalse(return_value)"},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"    def test_hipchat_default_formatting(self):"},{"line_number":120,"context_line":"        \"\"\"HipChat notification"},{"line_number":121,"context_line":"        \"\"\""},{"line_number":122,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a8ec9b2_dd53c7e0","line":119,"range":{"start_line":119,"start_character":4,"end_line":119,"end_character":46},"updated":"2016-09-15 17:36:11.000000000","message":"Need a test with custom formatting","commit_id":"d838691dcab4b9e3f407949fb51afd8a46196282"}]}
