{"id":1999,"date":"2019-03-27T09:05:14","date_gmt":"2019-03-27T01:05:14","guid":{"rendered":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/?p=1999"},"modified":"2019-03-27T09:06:05","modified_gmt":"2019-03-27T01:06:05","slug":"bitbucket-mercurial%e5%9c%a8debain8%e4%b8%8a%e7%9a%84%e4%b8%80%e7%82%b9%e5%b0%8f%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/2019\/03\/27\/bitbucket-mercurial%e5%9c%a8debain8%e4%b8%8a%e7%9a%84%e4%b8%80%e7%82%b9%e5%b0%8f%e9%97%ae%e9%a2%98\/","title":{"rendered":"Bitbucket\/Mercurial\u5728Debain8\u4e0a\u7684\u4e00\u70b9\u5c0f\u95ee\u9898"},"content":{"rendered":"<p>\u7531\u4e8eDebian 7\u5df2\u7ecf\u88ab\u65e0\u60c5\u5730\u7ec8\u7ed3\u4e86\u751f\u547d\u5468\u671f\uff0c\u56e0\u6b64\u4e0d\u5f97\u4e0d\u5c06\u90e8\u5206\u751f\u4ea7\u73af\u5883\u5347\u7ea7\u5230Debian 8\u3002\u603b\u4f53\u4e0a\u8fd8\u6bd4\u8f83\u987a\u5229\uff0c\u5728mercurial\u5e93\u65b9\u9762\u9047\u5230\u70b9\u95ee\u9898\uff0c\u8bb0\u5f55\u5982\u4e0b\uff1a<\/p>\n<h2>\u95ee\u98981\uff1aUnicodeDecodeError: &#8216;ascii&#8217; codec can&#8217;t decode<\/h2>\n<p>\u8fd9\u662fPython\u811a\u672c\u7f16\u7801\u7684\u95ee\u9898\u3002\u4e00\u4e2a\u597d\u7684py\u811a\u672c\uff0c\u5e94\u8be5\u5728\u811a\u672c\u8d77\u59cb\u5904\u5c31\u6807\u660e\u7f16\u7801\u65b9\u5f0f\uff0c\u53ef\u60dcmercurial\u7684\u5f88\u591a\u811a\u672c\u6ca1\u6709\u8fd9\u4e48\u505a\u3002Debian 8\u91c7\u7528Python 2.7.9\uff0c\u9ed8\u8ba4\u662fascii\u7f16\u7801\uff0c\u9700\u8981\u4fee\u6539\u4e3a\u9ed8\u8ba4utf-8\u7f16\u7801\u3002\u6ce8\u610f\uff0cDebian 8\u5b89\u88c5\u4e86\u591a\u4e2aPython\u7248\u672c\uff0c\u9996\u5148\u8981\u786e\u8ba4\u9ed8\u8ba4\u7248\u672c\u53f7\uff1a<\/p>\n<pre>python -V<\/pre>\n<p>\u63a5\u7740\u4fee\u6539\u201c\/etc\/python2.7\/sitecustomize.py\u201d\u6587\u4ef6\uff08\u5982\u679c\u6ca1\u6709\u7684\u8bdd\uff0c\u53ef\u4ee5\u624b\u5de5\u521b\u5efa\u4e00\u4e2a\uff09\uff0c\u5728\u6587\u4ef6\u8d77\u59cb\u5904\u6dfb\u52a0\u4ee5\u4e0b\u4ee3\u7801\uff1a<\/p>\n<pre>import sys\r\nreload(sys)\r\nsys.setdefaultencoding('utf-8')<\/pre>\n<h2>\u95ee\u98982: [SSL: WRONG_VERSION_NUMBER] wrong version number<\/h2>\n<p>Bitbucket\u7f51\u7ad9\u7981\u6b62\u4e86\u6709\u7f3a\u9677\u7684TLSv1\uff0cTLSv1.1\u52a0\u5bc6\u65b9\u5f0f\uff0c\u5947\u602a\u7684\u662fmercurial\u4e3a\u4ec0\u4e48\u6ca1\u6709\u6839\u636e\u534f\u5546\u91c7\u7528SSL\u6216\u8005TLSv1.2\uff1f \u4fee\u6539\u65b9\u5f0f\u4e5f\u7b80\u5355\uff0c\u5f3a\u5236mercurial\u7981\u6b62\u6389TLS\u3002\u4fee\u6539\u201c\/etc\/mercurial\/hgrc\u201d\uff0c\u589e\u52a0\u4ee5\u4e0b\u5185\u5bb9\uff1a<\/p>\n<pre>[ui]\r\ntls=False<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u7531\u4e8eDebian 7\u5df2\u7ecf\u88ab\u65e0\u60c5\u5730\u7ec8\u7ed3\u4e86\u751f\u547d\u5468\u671f\uff0c\u56e0\u6b64\u4e0d\u5f97\u4e0d\u5c06\u90e8\u5206\u751f\u4ea7\u73af\u5883\u5347\u7ea7\u5230Debian 8\u3002\u603b\u4f53\u4e0a\u8fd8\u6bd4\u8f83\u987a\u5229\uff0c\u5728mercurial\u5e93\u65b9\u9762\u9047\u5230\u70b9\u95ee\u9898\uff0c\u8bb0\u5f55\u5982\u4e0b&#8230;<\/p>\n<p class=\"read-more\"><a class=\"btn btn-default\" href=\"https:\/\/www.myvoipapp.com\/blogs\/yxh\/2019\/03\/27\/bitbucket-mercurial%e5%9c%a8debain8%e4%b8%8a%e7%9a%84%e4%b8%80%e7%82%b9%e5%b0%8f%e9%97%ae%e9%a2%98\/\"> Read More<span class=\"screen-reader-text\">  Read More<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[737,735,736,314,84,266,646],"class_list":["post-1999","post","type-post","status-publish","format-standard","hentry","category-6","tag-ascii","tag-bitbucket","tag-debian-8","tag-hg","tag-ssl","tag-tls","tag-utf-8"],"_links":{"self":[{"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/posts\/1999","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/comments?post=1999"}],"version-history":[{"count":2,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/posts\/1999\/revisions"}],"predecessor-version":[{"id":2001,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/posts\/1999\/revisions\/2001"}],"wp:attachment":[{"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/media?parent=1999"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/categories?post=1999"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.myvoipapp.com\/blogs\/yxh\/wp-json\/wp\/v2\/tags?post=1999"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}