{"id":49,"date":"2026-04-03T02:49:52","date_gmt":"2026-04-03T07:49:52","guid":{"rendered":"https:\/\/jeffsantillan.com\/blog\/?p=49"},"modified":"2026-04-03T03:04:18","modified_gmt":"2026-04-03T08:04:18","slug":"multiples-version-de-python-en-linux-con-ubuntu","status":"publish","type":"post","link":"https:\/\/jeffsantillan.com\/blog\/multiples-version-de-python-en-linux-con-ubuntu\/","title":{"rendered":"Multiples version de Python en Linux con Ubuntu"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Ubuntu viene con Python preinstalado, pero con dos particularidades: se llama <code>python3<\/code> en lugar de <code>python<\/code>, y su versi\u00f3n est\u00e1 atada al sistema operativo. Actualizarla directamente es arriesgado, ya que varios componentes del SO dependen de ella y podr\u00eda romperse la instalaci\u00f3n.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Lo que haremos es instalar una versi\u00f3n m\u00e1s reciente de forma paralela, pudiendo as\u00ed alternar entre versiones: una estable que usa el sistema por defecto y otra m\u00e1s moderna para pruebas.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Versi\u00f3n actual<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>python3 --version<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Asi que vamos a instalar una versi\u00f3n nueva en paralelo, haciendo uso del PPA de deadsnakes.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># Agregar el repositorio\n\nsudo add-apt-repository ppa:deadsnakes\/ppa\nsudo apt-get update\n\n# Instalar la versi\u00f3n que quieras (ejemplo: 3.12 o 3.13)\n\nsudo apt-get install python3.14<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verificar la versi\u00f3n<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>python3.14 --version<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"601\" height=\"113\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-1.png\" alt=\"\" class=\"wp-image-50\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-1.png 601w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-1-300x56.png 300w\" sizes=\"auto, (max-width: 601px) 100vw, 601px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Vamos a realizar que python3 apunte a la version mas reciente.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># Ver las versiones instaladas.\n\nls \/usr\/bin\/python3*<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"728\" height=\"94\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-2.png\" alt=\"\" class=\"wp-image-51\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-2.png 728w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-2-300x39.png 300w\" sizes=\"auto, (max-width: 728px) 100vw, 728px\" \/><\/figure>\n\n\n\n<pre class=\"wp-block-code\"><code># Configurar alternativas\n\nsudo update-alternatives --install \/usr\/bin\/python3 python3 \/usr\/bin\/python3.14 1<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"169\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-4-1024x169.png\" alt=\"\" class=\"wp-image-53\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-4-1024x169.png 1024w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-4-300x49.png 300w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-4-768x127.png 768w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-4.png 1347w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<pre class=\"wp-block-code\"><code># Elegir cual utilizar\n\nsudo update-alternatives --config python3 <\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"253\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-5-1024x253.png\" alt=\"\" class=\"wp-image-54\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-5-1024x253.png 1024w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-5-300x74.png 300w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-5-768x189.png 768w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-5.png 1042w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Finalmente, hacer que python funcione sin el 3 (python3)<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get install python-is-python3<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"473\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-6-1024x473.png\" alt=\"\" class=\"wp-image-55\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-6-1024x473.png 1024w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-6-300x139.png 300w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-6-768x355.png 768w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-6.png 1221w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Considera, que Ubuntu internamente rutas absolutas como \/usr\/bin\/python3.13 para sus herramientas criticas, no el symlink gen\u00e9rico.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">update-alternatives solo cambia el symlink, no afecta, elimina o reemplaza el python 3.13<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong><em>\u00bfProblemas con el pip?<\/em><\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Es posible que python-apt sigue apuntando a 3.13 sera mejor reinstalar.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get install --reinstall python3-apt<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Adem\u00e1s, instalar pip para Python 3.14<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get install python3-pip<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Validar y verificar las versiones<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>python3 --version\npip3 --version\npip3 list<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"520\" src=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-7-1024x520.png\" alt=\"\" class=\"wp-image-59\" srcset=\"https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-7-1024x520.png 1024w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-7-300x152.png 300w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-7-768x390.png 768w, https:\/\/jeffsantillan.com\/blog\/wp-content\/uploads\/2026\/04\/image-7.png 1281w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Saludos<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Python: <a href=\"https:\/\/www.python.org\/\">Enlace<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ubuntu viene con Python preinstalado, pero con dos particularidades: se llama python3 en lugar de python, &hellip; <a title=\"Multiples version de Python en Linux con Ubuntu\" class=\"hm-read-more\" href=\"https:\/\/jeffsantillan.com\/blog\/multiples-version-de-python-en-linux-con-ubuntu\/\"><span class=\"screen-reader-text\">Multiples version de Python en Linux con Ubuntu<\/span>Leer m\u00e1s<\/a><\/p>\n","protected":false},"author":2,"featured_media":10,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,5],"tags":[10],"class_list":["post-49","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-programacion","category-python","tag-python"],"_links":{"self":[{"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/posts\/49","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/comments?post=49"}],"version-history":[{"count":6,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/posts\/49\/revisions"}],"predecessor-version":[{"id":63,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/posts\/49\/revisions\/63"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/media\/10"}],"wp:attachment":[{"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/media?parent=49"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/categories?post=49"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jeffsantillan.com\/blog\/wp-json\/wp\/v2\/tags?post=49"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}