{"id":10487,"date":"2020-07-14T17:39:03","date_gmt":"2020-07-14T17:39:03","guid":{"rendered":"http:\/\/ubuntuhandbook.org\/?p=10487"},"modified":"2020-07-14T17:39:03","modified_gmt":"2020-07-14T17:39:03","slug":"python-3-8-4-released-install-ubuntu-18-04-16-04","status":"publish","type":"post","link":"https:\/\/ubuntuhandbook.org\/index.php\/2020\/07\/python-3-8-4-released-install-ubuntu-18-04-16-04\/","title":{"rendered":"Python 3.8.4 Released! How to Install in Ubuntu 18.04 \/ 16.04"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2017\/07\/python-icon245.png\" alt=\"\" width=\"245\" height=\"250\" class=\"aligncenter size-full wp-image-6928\" \/><\/p>\n<p>Python 3.8.4 was released a few days ago as the latest stable release of the Python language. Here&#8217;s how to install it in Ubuntu 18.04 and Ubuntu 16.04.<\/p>\n<blockquote><p>This is the first bugfix release that is considerably smaller than the previous three. There\u2019s almost 20% fewer changes at 162 commits than the average of previous three bugfix releases. Detailed information about all changes made in version 3.8.4 specifically can be found in <a href=\"https:\/\/docs.python.org\/release\/3.8.4\/whatsnew\/changelog.html#python-3-8-4-final\" rel=\"noopener\" target=\"_blank\">its change log<\/a>. Note that compared to 3.8.3, version 3.8.4 also contains the changes introduced in 3.8.4rc1.<\/p><\/blockquote>\n<p>The <a href=\"https:\/\/launchpad.net\/~deadsnakes\/+archive\/ubuntu\/ppa\" rel=\"noopener\" target=\"_blank\">deadsnakes team<\/a> maintains unofficial Python packages for different Ubuntu releases. Note the PPA does not contain Python 3.8 for Ubuntu 20.04 as upstream ubuntu provides the package.<\/p>\n<h4>Install Python 3.8.4 in Ubuntu 18.04, 16.04:<\/h4>\n<p><b>1.)<\/b> Open terminal either by pressing Ctrl+Alt+T on keyboard, or by searching for &#8216;terminal&#8217; from system application launcher.<\/p>\n<p>When terminal opens, run command to add the PPA:<\/p>\n<pre style=\"border:none;\">sudo add-apt-repository ppa:deadsnakes\/ppa<\/pre>\n<p><i>Type user password (no asterisk feedback) when it prompts and hit Enter to continue.<\/i><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/deadsnakes-bionic.jpg\" alt=\"\" width=\"500\" height=\"67\" class=\"aligncenter size-full wp-image-10488\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/deadsnakes-bionic.jpg 500w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/deadsnakes-bionic-450x60.jpg 450w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/p>\n<p><b>2.)<\/b> Then run commands to refresh system package cache, and install Python 3.8:<\/p>\n<pre style=\"border:none;\">sudo apt update\r\n\r\nsudo apt install python3.8<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/apt-python3.8-bionic.png\" alt=\"\" width=\"500\" height=\"213\" class=\"aligncenter size-full wp-image-10489\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/apt-python3.8-bionic.png 500w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/apt-python3.8-bionic-450x192.png 450w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/p>\n<p><b>3.)<\/b> Once successfully installed, check your system Python versions (python &#8211;version):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python-versions-bionic.png\" alt=\"\" width=\"500\" height=\"116\" class=\"aligncenter size-full wp-image-10490\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python-versions-bionic.png 500w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python-versions-bionic-450x104.png 450w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/p>\n<p><b>4.) (Optional)<\/b> To use Python 3.8 as the default <code>python3<\/code>, run commands:<\/p>\n<pre style=\"border:none;\">sudo update-alternatives --install \/usr\/bin\/python3 python3 \/usr\/bin\/python3.6 1\r\n\r\nsudo update-alternatives --install \/usr\/bin\/python3 python3 \/usr\/bin\/python3.8 2<\/pre>\n<p><i>For <b>Ubuntu 16.04<\/b> replace python3.6 with <b>python3.5<\/b><\/i>. And you can then switch between the two Python3 versions via command:<\/p>\n<pre style=\"border:None;\">sudo update-alternatives --config python3<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python38-default.png\" alt=\"\" width=\"500\" height=\"254\" class=\"aligncenter size-full wp-image-10491\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python38-default.png 500w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/07\/python38-default-450x229.png 450w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/p>\n<p><b>NOTE:<\/b> Due to known bug, terminal won&#8217;t open if you changed <code>python3<\/code> symlink. An workaround is recreate a symlink via command (<i>For <b>Ubuntu 16.04<\/b> replace python3.6 with <b>python3.5<\/b><\/i>):<\/p>\n<pre style=\"border:none;\">sudo rm \/usr\/bin\/python3; sudo ln -s python3.6 \/usr\/bin\/python3<\/pre>\n<h4>Uninstall:<\/h4>\n<p>To uninstall the Python3.8 packages, run command:<\/p>\n<pre style=\"border:none;\">sudo apt remove --autoremove python3.8 python3.8-minimal<\/pre>\n<p>To remove the Deadsnakes PPA, launch <b>Software &#038; Updates<\/b> and go to <i>Other Software<\/i> tab, then remove the repository line and close the window.<\/p>","protected":false},"excerpt":{"rendered":"<p>Python 3.8.4 was released a few days ago as the latest stable release of the Python language. Here&#8217;s how to install it in Ubuntu 18.04 and Ubuntu 16.04. This is the first bugfix release that is considerably smaller than the previous three. There\u2019s almost 20% fewer changes at 162 commits than the average of previous [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9,6],"tags":[1753],"class_list":["post-10487","post","type-post","status-publish","format-standard","hentry","category-howtos","category-news","tag-python-3-8"],"_links":{"self":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/10487","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/comments?post=10487"}],"version-history":[{"count":0,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/10487\/revisions"}],"wp:attachment":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/media?parent=10487"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/categories?post=10487"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/tags?post=10487"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}