# Pip install cryptography fails on py36

**URL:** <https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233>\
**Category:** Python\
**Tags:** python\
**Created:** [March 2, 2021, 9:03am UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233 "2021-03-02T09:03:12Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![pletnes](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/pletnes/32/6249_2.png) [@pletnes](https://travis-ci.community/u/pletnes)\
**Post date:** [March 2, 2021, 9:03am UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/1 "2021-03-02T09:03:12Z")

</div>

Dear builders,

I’m trying to `pip install cryptography`, essentially, and it works just great on py37 and py38. For py36 I get an error that I’m missing a Rust compiler. It seems py36 tries to build from source whereas on pypi I find wheels for py36, py37, py38. Why does it try to build from source on py36, or am I not understanding the issue here? Is the environment py36 somehow different from the others?

PR, for context

> <https://github.com/SAP/cloud-pysec/pull/52/files>

Build success/failure here (depending on python version)  
[https://travis-ci.org/github/SAP/cloud-pysec/builds/760937377](https://travis-ci.org/github/SAP/cloud-pysec/builds/760937377)

Pypi wheel seems to be py36+ compatible?

> **[cryptography](https://pypi.org/project/cryptography/#files)**
>
> cryptography is a package which provides cryptographic recipes and primitives to Python developers.

Thanks in advance.  
Paul

---

<div class="post-metadata">

**Author:** ![webknjaz](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/webknjaz/32/34_2.png) [@webknjaz](https://travis-ci.community/u/webknjaz)\
**Post date:** [March 2, 2021, 2:41pm UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/2 "2021-03-02T14:41:27Z")

</div>

Your pip version is probably old and doesn’t understand ABI3 tags in wheels. Upgrade it first.

---

<div class="post-metadata">

**Author:** ![pletnes](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/pletnes/32/6249_2.png) [@pletnes](https://travis-ci.community/u/pletnes)\
**Post date:** [March 2, 2021, 3:12pm UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/3 "2021-03-02T15:12:56Z")

</div>

In the .travis.yml file (it’s in the PR), there’s already this command:

```auto
   - pip install -U tox pip

```

That should do it, right?

---

<div class="post-metadata">

**Author:** ![webknjaz](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/webknjaz/32/34_2.png) [@webknjaz](https://travis-ci.community/u/webknjaz)\
**Post date:** [March 2, 2021, 3:37pm UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/4 "2021-03-02T15:37:50Z")

</div>

Tox creates separate virtualenvs, you probably want newer pip there. So upgrade `virtualenv` because it has a specific version of pip bundled.

---

<div class="post-metadata">

**Author:** ![pletnes](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/pletnes/32/6249_2.png) [@pletnes](https://travis-ci.community/u/pletnes)\
**Post date:** [March 2, 2021, 4:46pm UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/5 "2021-03-02T16:46:58Z")

</div>

@webknjaz thanks, very helpful of you! This resolved the issue.

---

<div class="post-metadata">

**Author:** ![maurol](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/maurol/32/7084_2.png) [@maurol](https://travis-ci.community/u/maurol)\
**Post date:** [September 8, 2021, 7:43pm UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/6 "2021-09-08T19:43:00Z")

</div>

@pletnes I am facing the same issue and tried to update `pip` and `virtualenv`, however my error hasn’t been resolved. Could you share, where you updated what? Thank you

---

<div class="post-metadata">

**Author:** ![pletnes](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/pletnes/32/6249_2.png) [@pletnes](https://travis-ci.community/u/pletnes)\
**Post date:** [September 10, 2021, 9:47am UTC](https://travis-ci.community/t/pip-install-cryptography-fails-on-py36/11233/7 "2021-09-10T09:47:24Z")

</div>

> **[cloud-pysec/.travis.yml at master · SAP/cloud-pysec](https://github.com/SAP/cloud-pysec/blame/master/.travis.yml)**
>
> Cloud Container Security API for python. Contribute to SAP/cloud-pysec development by creating an account on GitHub.

Have a look at the blame. Did this help? It boils down to

```auto
before_install:
  - python -m pip install --upgrade virtualenv

```
