# Python subprocess can't work more

**URL:** https://travis-ci.community/t/python-subprocess-cant-work-more/4403
**Category:** Environments
**Tags:** python
**Created:** [July 26, 2019, 12:46pm UTC](https://travis-ci.community/t/python-subprocess-cant-work-more/4403 "2019-07-26T12:46:31Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![zeroincombenze](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/zeroincombenze/32/2354_2.png) [@zeroincombenze](https://travis-ci.community/u/zeroincombenze)
#### Post date: [July 26, 2019, 12:46pm UTC](https://travis-ci.community/t/python-subprocess-cant-work-more/4403/1 "2019-07-26T12:46:31Z")

</div>

Hi to All,  
I need to test a package which comunicates with Odoo.  
So I have to run Odoo in background, execute tests and then stop Odoo.  
I used following statements to start/stop Odoo:  
\>\>\> prc = Process(target=run\_odoo\_cmd, args=(cmd\_odoo,))  
\>\>\> prc.start()  
[…] here test code […]  
\>\>\> prc.terminate()

Above test worked until July, 14th. After this date Odoo cannot start more, so test fails.

Is it changed something in travis environment?

Last failed test:  
[https://travis-ci.org/zeroincombenze/tools/jobs/563878251](https://travis-ci.org/zeroincombenze/tools/jobs/563878251)

Last succesfull test:  
[https://travis-ci.org/zeroincombenze/tools/jobs/558942006](https://travis-ci.org/zeroincombenze/tools/jobs/558942006)

---

<div class="post-metadata">

### Author: ![native-api](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/native-api/32/430_2.png) [@native-api](https://travis-ci.community/u/native-api)
#### Post date: [July 26, 2019, 2:30pm UTC](https://travis-ci.community/t/python-subprocess-cant-work-more/4403/2 "2019-07-26T14:30:30Z")

</div>

> **[Xenial as the default build environment - Travis CI changelog](https://changelog.travis-ci.com/xenial-as-the-default-build-environment-99476)**
>
>  New  
> As announced two weeks ago, we've started incrementally updating the default build environment to Ubuntu...

In particular, in the raw log, I see an error about `pip` inable to upgrade some (presumably apt-installed) Python packages which ultimately results in an error about an incompatible version of one of them being present.

> [@Python 3.6 and 3.7 with system\_site\_packages enabled fails to activate on xenial](https://travis-ci.community/t/python-3-6-and-3-7-with-system-site-packages-enabled-fails-to-activate-on-xenial/1697/2):
>
> You don’t. "System site-packages" is only a thing for Python versions provided by distro – which for Xenial are [2.7.12](https://packages.ubuntu.com/xenial-updates/python) and [3.5.1](https://packages.ubuntu.com/xenial/python3). Other Python versions are installed manually (into /opt as of this writing), and the only global packages there are pip and setuptools (you can see all this by examining the Python tarball that the build log refers to). So if you’re using alternative Python versions, you don’t have access to any apt-get Python packages anyway. As such, the most straightforward solu…

---

<div class="post-metadata">

### Author: ![native-api](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/native-api/32/430_2.png) [@native-api](https://travis-ci.community/u/native-api)
#### Post date: [July 26, 2019, 11:16pm UTC](https://travis-ci.community/t/python-subprocess-cant-work-more/4403/3 "2019-07-26T23:16:44Z")

</div>

`--ignore-installed` is another problematic option: it is very likely to create a potentially broken configuration. Which is exactly what happened in your case.

> <https://stackoverflow.com/questions/53807511/pip-cannot-uninstall-package-it-is-a-distutils-installed-project/53807588#53807588>
