# Issues with Python 3.6 ppa on Ubuntu 18.04 LTS

**URL:** <https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100>\
**Category:** Developers\
**Created:** [December 11, 2019, 1:58pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100 "2019-12-11T13:58:07Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [December 11, 2019, 1:58pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/1 "2019-12-11T13:58:07Z")

</div>

It seems the ppa for Python 3.6 is no longer available and it's causing the scripts to fail:

> TASK [apt] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
> [WARNING]: Could not find aptitude. Using apt-get instead
> 
> fatal: [192.168.253.21]: FAILED! =\> {"changed": false, "msg": "Failed to update apt cache: W:Updating from such a repository can't be done securely, and is therefore disabled by default., W:See apt-secure(8) manpage for repository creation and user configuration details., E:The repository '[http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu](http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu) bionic Release' no longer has a Release file."}

Im unable to remove it from the cache for some reason - i've tried

> sudo add-apt-repository -r ppa:jonathonf/python-3.6

As well as

> sudo ppa-purge ppa:jonathonf/python-3.6

Any idea if I can remove it manually somehow to allow the deployment to continue?

This from Jonathonf:

> [https://launchpad.net/~jonathonf/+archive/ubuntu/python-3.6](https://launchpad.net/~jonathonf/+archive/ubuntu/python-3.6)  
> This PPA has been removed from public access as part of a protest against the abuse of open-source projects by large companies. For more detail visit the main page here: [https://launchpad.net/~jonathonf](https://launchpad.net/~jonathonf)
> 
> If you are a company and you would like this PPA to continue then let me know your preferred route for contributions and I will arrange something.
> 
> If we have already been in contact then ping me your Launchpad ID and I will add you to a private PPA in the meantime.

---

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [December 11, 2019, 3:12pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/2 "2019-12-11T15:12:54Z")

</div>

Just replying to my own post - I found the references in /etc/apt/sources.list.d  
so

`sudo rm /etc/apt/sources.list.d/*jonathon*`

resolved this one

---

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [December 11, 2019, 4:11pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/3 "2019-12-11T16:11:12Z")

</div>

OK, seems I spoke too soon. The Ansible scripts fail with:

> TASK [common\_installs : Add Python PPA for bionic and xenial] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
> An exception occurred during task execution. To see the full traceback, use -vvv. The error was: apt.cache.FetchFailedException: E:The repository '[http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu](http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu) bionic Release' does not have a Release file.  
> fatal: [192.168.253.21]: FAILED! =\> {"changed": false, "module\_stderr": "Traceback (most recent call last):\n File "", line 114, in \n File "", line 106, in \_ansiballz\_main\n File "", line 49, in invoke\_module\n File "/tmp/ansible\_apt\_repository\_payload\_PWnHXY/ **main**.py", line 554, in \n File "/tmp/ansible\_apt\_repository\_payload\_PWnHXY/ **main**.py", line 546, in main\n File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 559, in update\n raise FetchFailedException(e)\napt.cache.FetchFailedException: E:The repository '[http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu](http://ppa.launchpad.net/jonathonf/python-3.6/ubuntu) bionic Release' does not have a Release file.\n", "module\_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}

---

<div class="post-metadata">

**Author:** ![Clayton\_Sims](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/clayton_sims/32/496_2.png) [@Clayton\_Sims](https://forum.dimagi.com/u/Clayton_Sims)\
**Post date:** [December 11, 2019, 8:39pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/4 "2019-12-11T20:39:22Z")

</div>

Hi Ed,

Sorry about this mess, we are working on figuring out the best workaround for this, but if the target machines already have the packages installed, you should be able to deploy by removing this dependency from your ansible deploy scripts (and removing the line from the apt sources as you did)

[https://github.com/dimagi/commcare-cloud/blob/55fa0571aac410ed2f666542edf58b07b0c1ce86/src/commcare\_cloud/ansible/roles/common\_installs/tasks/main.yml#L27](https://github.com/dimagi/commcare-cloud/blob/55fa0571aac410ed2f666542edf58b07b0c1ce86/src/commcare_cloud/ansible/roles/common_installs/tasks/main.yml#L27)

-Clayton

---

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [December 12, 2019, 1:15pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/5 "2019-12-12T13:15:22Z")

</div>

Thanks Clayton, will do!

---

<div class="post-metadata">

**Author:** ![jaihonikhil](https://dimagi.b-cdn.net/letter_avatar_proxy/v4/letter/j/7ba0ec/32.png) [@jaihonikhil](https://forum.dimagi.com/u/jaihonikhil)\
**Post date:** [May 9, 2020, 6:06am UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/6 "2020-05-09T06:06:37Z")

</div>

Hi ! I am facing a similar issue

 ![image](https://dimagi.b-cdn.net/uploads/default/original/2X/6/6eab1f73f1bb32d07d348ca55be45fc9fa69b49c.png)  
Can you please guide and help me out? this is preventing my system to update.  
I have already done all the steps above to mention.

update:I followed this link [[Solved] Could not get lock /var/lib/dpkg/lock Error in Ubuntu](https://itsfoss.com/could-not-get-lock-error/) adn [How to Remove or Delete PPA in Ubuntu Linux](https://itsfoss.com/how-to-remove-or-delete-ppas-quick-tip/) and deleted the PPA file manually from the script.  
Hope it helps!

---

<div class="post-metadata">

**Author:** ![sanjay.chinthala](https://dimagi.b-cdn.net/letter_avatar_proxy/v4/letter/s/54ee81/32.png) [@sanjay.chinthala](https://forum.dimagi.com/u/sanjay.chinthala)\
**Post date:** [May 11, 2020, 9:34am UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/7 "2020-05-11T09:34:13Z")

</div>

Hi Jaihonikhil,

Can you please move the filename starts with _jonathon_ to other path from /etc/source.list.d and try update

Thanks,  
Sanjay

---

<div class="post-metadata">

**Author:** ![Norman\_Hooper](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/norman_hooper/32/2493_2.png) [@Norman\_Hooper](https://forum.dimagi.com/u/Norman_Hooper)\
**Post date:** [May 11, 2020, 9:36am UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/8 "2020-05-11T09:36:04Z")

</div>

Thanks for adding the update. That's super useful!

I am curious how the PPA for Python 3.6 got there. I think Ubuntu 18.04 uses Python 3.6 by default, so I'm not sure why it needs that PPA. Do you know whether this machine upgraded from a previous version of Ubuntu?

---

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [May 11, 2020, 10:57am UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/9 "2020-05-11T10:57:34Z")

</div>

Hi @Norman_Hooper  
Speaking for myself, this happened out of the box when running the scripts on a clean install on 18.04. I haven't run them recently.

---

<div class="post-metadata">

**Author:** ![Norman\_Hooper](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/norman_hooper/32/2493_2.png) [@Norman\_Hooper](https://forum.dimagi.com/u/Norman_Hooper)\
**Post date:** [May 11, 2020, 3:29pm UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/10 "2020-05-11T15:29:12Z")

</div>

Thanks, @erobinson. The link Clayton posted explains it: It used to be part of the deployment, but it isn't any longer.

---

<div class="post-metadata">

**Author:** ![erobinson](https://dimagi.b-cdn.net/user_avatar/forum.dimagi.com/erobinson/32/2652_2.png) [@erobinson](https://forum.dimagi.com/u/erobinson)\
**Post date:** [May 12, 2020, 8:31am UTC](https://forum.dimagi.com/t/issues-with-python-3-6-ppa-on-ubuntu-18-04-lts/7100/11 "2020-05-12T08:31:23Z")

</div>

No worries, I'll give it a spin myself when I have a gap and provide feedback. Thanks!
