{"id":1007391,"date":"2024-12-27T10:53:11","date_gmt":"2024-12-27T02:53:11","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1007391.html"},"modified":"2024-12-27T10:53:19","modified_gmt":"2024-12-27T02:53:19","slug":"%e5%a6%82%e4%bd%95%e5%ae%89%e8%a3%85python3-6-2","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1007391.html","title":{"rendered":"\u5982\u4f55\u5b89\u88c5python3.6.2"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25083133\/ee513df1-8e6e-4a30-84bb-430ec5185a1c.webp\" alt=\"\u5982\u4f55\u5b89\u88c5python3.6.2\" \/><\/p>\n<p><p> \u5728\u56de\u7b54\u5982\u4f55\u5b89\u88c5Python 3.6.2\u8fd9\u4e2a\u95ee\u9898\u65f6\uff0c<strong>\u4e3b\u8981\u6b65\u9aa4\u5305\u62ec\uff1a\u4ecePython\u5b98\u65b9\u7f51\u7ad9\u4e0b\u8f7dPython 3.6.2\u5b89\u88c5\u7a0b\u5e8f\u3001\u8fd0\u884c\u5b89\u88c5\u7a0b\u5e8f\u8fdb\u884c\u5b89\u88c5\u3001\u8bbe\u7f6e\u73af\u5883\u53d8\u91cf<\/strong>\u3002\u5176\u4e2d\uff0c\u6700\u91cd\u8981\u7684\u4e00\u6b65\u662f\u4ecePython\u5b98\u65b9\u7f51\u7ad9\u4e0b\u8f7d\u76f8\u5e94\u7684\u5b89\u88c5\u7a0b\u5e8f\uff0c\u4ee5\u786e\u4fdd\u83b7\u53d6\u7684\u662f\u5b98\u65b9\u3001\u7a33\u5b9a\u7684\u7248\u672c\u3002\u63a5\u4e0b\u6765\uff0c\u6211\u5c06\u8be6\u7ec6\u9610\u8ff0\u8fd9\u4e9b\u6b65\u9aa4\uff0c\u5e76\u6db5\u76d6\u4e0d\u540c\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u7684\u5177\u4f53\u5b89\u88c5\u65b9\u6cd5\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001WINDOWS\u7cfb\u7edf\u4e0b\u7684Python 3.6.2\u5b89\u88c5<\/p>\n<\/p>\n<ol>\n<li>\n<p>\u4e0b\u8f7dPython 3.6.2\u5b89\u88c5\u7a0b\u5e8f<\/p>\n<\/p>\n<ul>\n<li>\u9996\u5148\uff0c\u8bbf\u95eePython\u7684\u5b98\u65b9\u7f51\u7ad9\uff08<a href=\"https:\/\/www.python.org\/%EF%BC%89%E3%80%82\">https:\/\/www.python.org\/\uff09\u3002<\/a><\/li>\n<li>\u5728\u4e3b\u9875\u5bfc\u822a\u680f\u4e2d\uff0c\u627e\u5230\u201cDownloads\u201d\u5e76\u70b9\u51fb\u3002<\/li>\n<li>\u5728\u4e0b\u8f7d\u9875\u9762\u4e0a\uff0c\u9009\u62e9\u201cView the full list of downloads\u201d\u4ee5\u67e5\u770b\u66f4\u591a\u7248\u672c\u3002<\/li>\n<li>\u5728\u5217\u8868\u4e2d\u627e\u5230Python 3.6.2\uff0c\u5e76\u9009\u62e9\u9002\u5408Windows\u7cfb\u7edf\u7684\u5b89\u88c5\u7a0b\u5e8f\uff08\u901a\u5e38\u662fWindows x86-64 MSI installer\u7528\u4e8e64\u4f4d\u7cfb\u7edf\uff0cWindows x86 MSI installer\u7528\u4e8e32\u4f4d\u7cfb\u7edf\uff09\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u8fd0\u884c\u5b89\u88c5\u7a0b\u5e8f<\/p>\n<\/p>\n<ul>\n<li>\u53cc\u51fb\u4e0b\u8f7d\u7684\u5b89\u88c5\u7a0b\u5e8f\u4ee5\u542f\u52a8\u5b89\u88c5\u8fc7\u7a0b\u3002<\/li>\n<li>\u5728\u5b89\u88c5\u754c\u9762\u4e2d\uff0c\u786e\u4fdd\u52fe\u9009\u201cAdd Python 3.6 to PATH\u201d\u9009\u9879\uff0c\u8fd9\u4e00\u6b65\u975e\u5e38\u91cd\u8981\uff0c\u56e0\u4e3a\u5b83\u4f1a\u5c06Python\u6dfb\u52a0\u5230\u7cfb\u7edf\u7684\u73af\u5883\u53d8\u91cf\u4e2d\u3002<\/li>\n<li>\u9009\u62e9\u201cCustomize installation\u201d\u4ee5\u8fdb\u884c\u81ea\u5b9a\u4e49\u5b89\u88c5\uff0c\u6216\u8005\u9009\u62e9\u201cInstall Now\u201d\u8fdb\u884c\u5feb\u901f\u5b89\u88c5\u3002<\/li>\n<li>\u5982\u679c\u9009\u62e9\u81ea\u5b9a\u4e49\u5b89\u88c5\uff0c\u53ef\u4ee5\u9009\u62e9\u5b89\u88c5\u7ec4\u4ef6\u548c\u5b89\u88c5\u8def\u5f84\u3002\u9ed8\u8ba4\u60c5\u51b5\u4e0b\u7684\u7ec4\u4ef6\u90fd\u5e94\u8be5\u88ab\u4fdd\u7559\u3002<\/li>\n<li>\u70b9\u51fb\u201cInstall\u201d\u5f00\u59cb\u5b89\u88c5\uff0c\u5e76\u5728\u5b8c\u6210\u540e\u5173\u95ed\u5b89\u88c5\u7a0b\u5e8f\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u914d\u7f6e\u73af\u5883\u53d8\u91cf<\/p>\n<\/p>\n<ul>\n<li>\u5982\u679c\u5728\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u672a\u52fe\u9009\u201cAdd Python 3.6 to PATH\u201d\uff0c\u9700\u8981\u624b\u52a8\u5c06Python\u76ee\u5f55\u6dfb\u52a0\u5230\u7cfb\u7edf\u7684\u73af\u5883\u53d8\u91cf\u4e2d\u3002<\/li>\n<li>\u53f3\u952e\u70b9\u51fb\u201c\u6b64\u7535\u8111\u201d\u6216\u201c\u6211\u7684\u7535\u8111\u201d\uff0c\u9009\u62e9\u201c\u5c5e\u6027\u201d\u3002<\/li>\n<li>\u8fdb\u5165\u201c\u9ad8\u7ea7\u7cfb\u7edf\u8bbe\u7f6e\u201d\uff0c\u70b9\u51fb\u201c\u73af\u5883\u53d8\u91cf\u201d\u3002<\/li>\n<li>\u5728\u201c\u7cfb\u7edf\u53d8\u91cf\u201d\u4e2d\u627e\u5230\u5e76\u7f16\u8f91\u201cPath\u201d\u53d8\u91cf\uff0c\u5c06Python\u7684\u5b89\u88c5\u76ee\u5f55\u548cScripts\u76ee\u5f55\u6dfb\u52a0\u8fdb\u53bb\uff08\u4f8b\u5982\uff1aC:\\Python36;C:\\Python36\\Scripts\uff09\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u9a8c\u8bc1\u5b89\u88c5<\/p>\n<\/p>\n<ul>\n<li>\u6253\u5f00\u547d\u4ee4\u63d0\u793a\u7b26\uff08cmd\uff09\uff0c\u8f93\u5165<code>python --version<\/code>\uff0c\u5982\u679c\u663e\u793aPython 3.6.2\uff0c\u5219\u8bf4\u660e\u5b89\u88c5\u6210\u529f\u3002<\/li>\n<li>\u8f93\u5165<code>pip --version<\/code>\u6765\u9a8c\u8bc1pip\u662f\u5426\u5df2\u6b63\u786e\u5b89\u88c5\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p><p>\u4e8c\u3001MAC OS\u7cfb\u7edf\u4e0b\u7684Python 3.6.2\u5b89\u88c5<\/p>\n<\/p>\n<ol>\n<li>\n<p>\u4f7f\u7528Homebrew\u5b89\u88c5<\/p>\n<\/p>\n<ul>\n<li>\u6253\u5f00\u7ec8\u7aef\u3002<\/li>\n<li>\u786e\u4fddHomebrew\u5df2\u5b89\u88c5\uff0c\u5982\u679c\u6ca1\u6709\uff0c\u8f93\u5165\u4ee5\u4e0b\u547d\u4ee4\u8fdb\u884c\u5b89\u88c5\uff1a\n<pre><code class=\"language-bash\">\/bin\/bash -c &quot;$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/HEAD\/install.sh)&quot;<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u4f7f\u7528Homebrew\u5b89\u88c5Python 3.6.2\uff1a\n<pre><code class=\"language-bash\">brew install pyenv<\/p>\n<p>pyenv install 3.6.2<\/p>\n<p>pyenv global 3.6.2<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u8fd9\u5c06\u5b89\u88c5\u5e76\u8bbe\u7f6ePython 3.6.2\u4e3a\u5168\u5c40\u7248\u672c\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u9a8c\u8bc1\u5b89\u88c5<\/p>\n<\/p>\n<ul>\n<li>\u5728\u7ec8\u7aef\u4e2d\uff0c\u8f93\u5165<code>python --version<\/code>\u6216<code>python3 --version<\/code>\u4ee5\u9a8c\u8bc1Python\u7248\u672c\u3002<\/li>\n<li>\u4f7f\u7528<code>pip --version<\/code>\u9a8c\u8bc1pip\u7248\u672c\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p><p>\u4e09\u3001LINUX\u7cfb\u7edf\u4e0b\u7684Python 3.6.2\u5b89\u88c5<\/p>\n<\/p>\n<ol>\n<li>\n<p>\u4f7f\u7528APT\u5305\u7ba1\u7406\u5668\u5b89\u88c5\uff08Ubuntu\/Debian\uff09<\/p>\n<\/p>\n<ul>\n<li>\u6253\u5f00\u7ec8\u7aef\u3002<\/li>\n<li>\u66f4\u65b0\u5305\u5217\u8868\uff1a\n<pre><code class=\"language-bash\">sudo apt update<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u5b89\u88c5Python 3.6\uff1a\n<pre><code class=\"language-bash\">sudo apt install python3.6<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u5982\u679c\u9700\u8981pip\uff0c\u53ef\u4ee5\u5b89\u88c5pip3\uff1a\n<pre><code class=\"language-bash\">sudo apt install python3-pip<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u4f7f\u7528\u6e90\u7801\u7f16\u8bd1\u5b89\u88c5<\/p>\n<\/p>\n<ul>\n<li>\u4e0b\u8f7dPython 3.6.2\u6e90\u4ee3\u7801\uff1a\n<pre><code class=\"language-bash\">wget https:\/\/www.python.org\/ftp\/python\/3.6.2\/Python-3.6.2.tgz<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u89e3\u538b\u6587\u4ef6\uff1a\n<pre><code class=\"language-bash\">tar -xvf Python-3.6.2.tgz<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u8fdb\u5165\u89e3\u538b\u540e\u7684\u76ee\u5f55\uff1a\n<pre><code class=\"language-bash\">cd Python-3.6.2<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u914d\u7f6e\u7f16\u8bd1\u73af\u5883\uff1a\n<pre><code class=\"language-bash\">.\/configure<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>\u7f16\u8bd1\u5e76\u5b89\u88c5\uff1a\n<pre><code class=\"language-bash\">make<\/p>\n<p>sudo make install<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u9a8c\u8bc1\u5b89\u88c5<\/p>\n<\/p>\n<ul>\n<li>\u5728\u7ec8\u7aef\u4e2d\u8f93\u5165<code>python3.6 --version<\/code>\u6765\u9a8c\u8bc1\u5b89\u88c5\u3002<\/li>\n<li>\u8f93\u5165<code>pip3 --version<\/code>\u6765\u9a8c\u8bc1pip\u5b89\u88c5\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p><p>\u56db\u3001\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u5e38\u89c1\u95ee\u9898\u53ca\u89e3\u51b3\u65b9\u6cd5<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u7f51\u7edc\u95ee\u9898\u5bfc\u81f4\u4e0b\u8f7d\u5931\u8d25<\/strong><\/p>\n<\/p>\n<ul>\n<li>\u786e\u4fdd\u7f51\u7edc\u8fde\u63a5\u6b63\u5e38\uff0c\u8003\u8651\u4f7f\u7528\u4e0b\u8f7d\u5de5\u5177\u5982wget\u6216curl\u8fdb\u884c\u4e0b\u8f7d\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>\u6743\u9650\u95ee\u9898<\/strong><\/p>\n<\/p>\n<ul>\n<li>\u5728Linux\u548cMacOS\u4e0a\uff0c\u5b89\u88c5\u65f6\u9700\u8981\u4f7f\u7528<code>sudo<\/code>\u4ee5\u83b7\u5f97\u7ba1\u7406\u5458\u6743\u9650\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>\u73af\u5883\u53d8\u91cf\u672a\u6b63\u786e\u914d\u7f6e<\/strong><\/p>\n<\/p>\n<ul>\n<li>\u786e\u4fddPython\u8def\u5f84\u5df2\u6b63\u786e\u6dfb\u52a0\u5230\u7cfb\u7edf\u7684\u73af\u5883\u53d8\u91cf\u4e2d\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>pip\u65e0\u6cd5\u4f7f\u7528<\/strong><\/p>\n<\/p>\n<ul>\n<li>\u786e\u8ba4pip\u5df2\u5b89\u88c5\u5e76\u6b63\u786e\u914d\u7f6e\uff0c\u6216\u8005\u4f7f\u7528<code>get-pip.py<\/code>\u811a\u672c\u91cd\u65b0\u5b89\u88c5pip\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p><p>\u901a\u8fc7\u4ee5\u4e0a\u6b65\u9aa4\uff0c\u60a8\u5e94\u8be5\u80fd\u591f\u5728\u4e0d\u540c\u7684\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u6210\u529f\u5b89\u88c5Python 3.6.2\u3002\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u5efa\u8bae\u60a8\u5b66\u4e60\u5982\u4f55\u4f7f\u7528Python\u7684\u57fa\u672c\u547d\u4ee4\u548c\u5e93\uff0c\u4ee5\u4fbf\u66f4\u597d\u5730\u5229\u7528\u8fd9\u4e2a\u5f3a\u5927\u7684\u7f16\u7a0b\u5de5\u5177\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u786e\u5b9a\u6211\u7684\u7535\u8111\u662f\u5426\u9002\u5408\u5b89\u88c5Python 3.6.2\uff1f<\/strong><br \/>\u5728\u5b89\u88c5Python 3.6.2\u4e4b\u524d\uff0c\u60a8\u9700\u8981\u786e\u4fdd\u60a8\u7684\u64cd\u4f5c\u7cfb\u7edf\u4e0e\u8be5\u7248\u672c\u517c\u5bb9\u3002Python 3.6.2\u652f\u6301Windows\u3001macOS\u548c\u591a\u79cdLinux\u53d1\u884c\u7248\u3002\u68c0\u67e5\u60a8\u7684\u64cd\u4f5c\u7cfb\u7edf\u7248\u672c\uff0c\u5e76\u786e\u8ba4\u5176\u7b26\u5408Python\u7684\u7cfb\u7edf\u8981\u6c42\u3002\u5728Windows\u4e0a\uff0c\u786e\u4fdd\u60a8\u4f7f\u7528\u7684\u662f64\u4f4d\u621632\u4f4d\u7248\u672c\uff0c\u53d6\u51b3\u4e8e\u60a8\u7684\u7cfb\u7edf\u67b6\u6784\u3002\u540c\u65f6\uff0c\u786e\u4fdd\u6709\u8db3\u591f\u7684\u786c\u76d8\u7a7a\u95f4\u6765\u5b8c\u6210\u5b89\u88c5\u3002<\/p>\n<p><strong>\u5b89\u88c5Python 3.6.2\u540e\uff0c\u5982\u4f55\u9a8c\u8bc1\u5176\u662f\u5426\u6210\u529f\u5b89\u88c5\uff1f<\/strong><br \/>\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u53ef\u4ee5\u901a\u8fc7\u547d\u4ee4\u884c\u6216\u7ec8\u7aef\u9a8c\u8bc1Python\u662f\u5426\u6210\u529f\u5b89\u88c5\u3002\u6253\u5f00\u547d\u4ee4\u63d0\u793a\u7b26\u6216\u7ec8\u7aef\uff0c\u8f93\u5165<code>python --version<\/code>\u6216<code>python3 --version<\/code>\uff0c\u5e94\u8be5\u4f1a\u663e\u793aPython 3.6.2\u7684\u7248\u672c\u4fe1\u606f\u3002\u5982\u679c\u770b\u5230\u6b63\u786e\u7684\u7248\u672c\u53f7\uff0c\u8bf4\u660e\u5b89\u88c5\u6210\u529f\u3002\u5982\u679c\u672a\u663e\u793a\u7248\u672c\u53f7\uff0c\u53ef\u80fd\u9700\u8981\u68c0\u67e5\u73af\u5883\u53d8\u91cf\u8bbe\u7f6e\u662f\u5426\u6b63\u786e\u3002<\/p>\n<p><strong>\u6211\u53ef\u4ee5\u5728\u540c\u4e00\u53f0\u673a\u5668\u4e0a\u5b89\u88c5\u591a\u4e2aPython\u7248\u672c\u5417\uff1f<\/strong><br \/>\u662f\u7684\uff0c\u60a8\u53ef\u4ee5\u5728\u540c\u4e00\u53f0\u673a\u5668\u4e0a\u5b89\u88c5\u591a\u4e2aPython\u7248\u672c\u3002\u4f7f\u7528\u4e0d\u540c\u7684\u7248\u672c\u65f6\uff0c\u53ef\u4ee5\u901a\u8fc7\u547d\u4ee4\u884c\u6307\u5b9a\u7248\u672c\uff0c\u4f8b\u5982\u4f7f\u7528<code>python3.6<\/code>\u6765\u8fd0\u884cPython 3.6.x\u7248\u672c\u3002\u6b64\u5916\uff0c\u4f7f\u7528\u865a\u62df\u73af\u5883\u662f\u7ba1\u7406\u591a\u4e2aPython\u7248\u672c\u548c\u4f9d\u8d56\u5305\u7684\u63a8\u8350\u65b9\u6cd5\u3002\u901a\u8fc7\u521b\u5efa\u865a\u62df\u73af\u5883\uff0c\u60a8\u53ef\u4ee5\u4e3a\u6bcf\u4e2a\u9879\u76ee\u8bbe\u7f6e\u72ec\u7acb\u7684Python\u7248\u672c\u548c\u5e93\uff0c\u907f\u514d\u7248\u672c\u51b2\u7a81\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5728\u56de\u7b54\u5982\u4f55\u5b89\u88c5Python 3.6.2\u8fd9\u4e2a\u95ee\u9898\u65f6\uff0c\u4e3b\u8981\u6b65\u9aa4\u5305\u62ec\uff1a\u4ecePython\u5b98\u65b9\u7f51\u7ad9\u4e0b\u8f7dPython 3.6 [&hellip;]","protected":false},"author":3,"featured_media":1007411,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1007391"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=1007391"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1007391\/revisions"}],"predecessor-version":[{"id":1007414,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1007391\/revisions\/1007414"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1007411"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1007391"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1007391"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1007391"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}