Django porting with python3.6 ERROR: root: code for hash sha3_224 not found

Hello, I read the Django tutorials and I have an error related to the specific hash function sha3_224 during the migration process. How to solve this problem? Thanks.

 (venv) linuxoid@linuxoid-ThinkPad-L540 :~/myprojects/myproject$ python manage.py makemigrations ERROR:root:code for hash sha3_224 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_sha3_224' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type sha3_224 ERROR:root:code for hash sha3_256 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_sha3_256' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type sha3_256 ERROR:root:code for hash sha3_384 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_sha3_384' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type sha3_384 ERROR:root:code for hash sha3_512 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_sha3_512' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type sha3_512 ERROR:root:code for hash shake_128 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_shake_128' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type shake_128 ERROR:root:code for hash shake_256 was not found. Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 121, in __get_openssl_constructor f = getattr(_hashlib, 'openssl_' + name) AttributeError: module '_hashlib' has no attribute 'openssl_shake_256' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 243, in <module> globals()[__func_name] = __get_hash(__func_name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 128, in __get_openssl_constructor return __get_builtin_constructor(name) File "/home/linuxoid/myprojects/venv/lib/python3.6/hashlib.py", line 113, in __get_builtin_constructor raise ValueError('unsupported hash type ' + name) ValueError: unsupported hash type shake_256 No changes detected 
+5
source share
4 answers

This problem appears in the new version of python - 3.6.3.

Lowering to 3.6.2 helped me

Here is the deprecated PPA: https://launchpad.net/~fkrull/+archive/ubuntu/deadsnakes/+index?batch=75&direction=backwards&start=75

+3
source

Check if your python has been updated recently. Vienna can point to the old one, recreating Vienna, he corrected it for us.

Running mkvirtualenv venv or virtualenv venv (depending on how you created it first) should also work while saving installed packages.

+12
source

This solved my problem:

 cd /usr/bin sudo cp python3.6 python3 

I used to have 3.6.2, after apt-upgrade system was broken.

+2
source

This happened to me after upgrading to 3.6.3. Try creating a new virtualenv with Python 3.6.3 or later. This solved the problem for me.

0
source

Source: https://habr.com/ru/post/1272436/


All Articles