{"id":188400,"date":"2013-07-30T21:03:02","date_gmt":"2013-07-30T17:03:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=188400"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=188400","title":{"rendered":"<span class=\"post_title\">\u041a\u0440\u0430\u0441\u0438\u0432\u044b\u0435 \u0442\u0440\u0435\u0439\u0441\u0431\u0435\u043a\u0438 \u0432 Python<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t\u041a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u0432\u0430\u043c \u043f\u0440\u0438\u0441\u044b\u043b\u0430\u044e\u0442 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0435 \u043e\u0442\u0447\u0435\u0442\u044b \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0435?<\/p>\n<pre><code class=\"python\">Traceback (most recent call last): ...   File &quot;...&quot;, line ..., in ...     process(lst[index]) IndexError: list index out of range <\/code><\/pre>\n<p>  <i>\u041e\u0445, \u0435\u0441\u043b\u0438 \u0431\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 lst \u0438 index \u043d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442&#8230;<\/i><\/p>\n<p>  <b>python-catcher \u2014 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f HTML-\u0442\u0440\u0435\u0439\u0441\u0431\u0435\u043a\u043e\u0432 \u0441 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u043c\u0438 \u0438 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0430\u043c\u0438, + \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442<\/b> \u2014 \u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435\u0441\u044c \u043d\u0430 \u0437\u0434\u043e\u0440\u043e\u0432\u044c\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/4b8\/188\/5fe\/4b81885fe8582d835c557af1d71884b9.png\"\/><\/p>\n<p>  <a name=\"habracut\"><\/a><\/p>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440 \u0441\u0430\u043c\u043e\u0433\u043e \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u0433\u043e \u043e\u0442\u0447\u0435\u0442\u0430: <a href=\"http:\/\/ajenti.org\/catcher\/view\/10\">ajenti.org\/catcher\/view\/10<\/a><\/p>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f:<\/p>\n<pre><code class=\"python\">import catcher  try:     launch_important_stuff() except Exception, e:     report = catcher.collect(e)     html = catcher.formatters.HTMLFormatter().format(report, maxdepth=4)     url = catcher.uploaders.AjentiOrgUploader().upload(html)      print 'Application has crashed. Please submit this link along with the bug report:'     print url <\/code><\/pre>\n<p>  <a href=\"https:\/\/pypi.python.org\/pypi\/python-catcher\">PyPI<\/a>, <a href=\"https:\/\/github.com\/Eugeny\/catcher\">Github<\/a>, \u0441\u0432\u0435\u0436\u0438\u0435 deb <a href=\"http:\/\/docs.ajenti.org\/man\/install\/general.html\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<p>  \u0411\u043e\u043b\u044c\u0448\u0435 \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u0435\u0447\u0435\u0433\u043e \ud83d\ude42    \t<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/188400\/\"> http:\/\/habrahabr.ru\/post\/188400\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t\u041a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u0432\u0430\u043c \u043f\u0440\u0438\u0441\u044b\u043b\u0430\u044e\u0442 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0435 \u043e\u0442\u0447\u0435\u0442\u044b \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0435?<\/p>\n<pre><code class=\"python\">Traceback (most recent call last): ...   File &quot;...&quot;, line ..., in ...     process(lst[index]) IndexError: list index out of range <\/code><\/pre>\n<p>  <i>\u041e\u0445, \u0435\u0441\u043b\u0438 \u0431\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 lst \u0438 index \u043d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442&#8230;<\/i><\/p>\n<p>  <b>python-catcher \u2014 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f HTML-\u0442\u0440\u0435\u0439\u0441\u0431\u0435\u043a\u043e\u0432 \u0441 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u043c\u0438 \u0438 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0430\u043c\u0438, + \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442<\/b> \u2014 \u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435\u0441\u044c \u043d\u0430 \u0437\u0434\u043e\u0440\u043e\u0432\u044c\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/4b8\/188\/5fe\/4b81885fe8582d835c557af1d71884b9.png\"\/><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-188400","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/188400","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=188400"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/188400\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=188400"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=188400"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=188400"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}