sunfounder / SunFounder_PiCar-V

Smart Video Car Kit V2.0 for Raspberry Pi from SunFounder
GNU General Public License v2.0
111 stars 175 forks source link

./install_dependecies fail #8

Open ythalorossy opened 6 years ago

ythalorossy commented 6 years ago

I noticed that this is a know error, but I have one suggestion:

pi@raspberrypi:~/SunFounder_PiCar-V $ sudo ./install_dependencies 
./install_dependencies: line 16: is_installed_libjpeg8-dev=False: command not found
Hit:1 http://mirrordirector.raspbian.org/raspbian stretch InRelease
Hit:2 http://archive.raspberrypi.org/debian stretch InRelease
Reading package lists... Done                      

Installing django 

Collecting django
  **Downloading Django-2.0.tar.gz (8.0MB)**
    100% |████████████████████████████████| 8.0MB 32kB/s 
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-4XOHna/django/setup.py", line 32, in <module>
        version = __import__('django').get_version()
      File "django/__init__.py", line 1, in <module>
        from django.utils.version import get_version
      File "django/utils/version.py", line 61, in <module>
        @functools.lru_cache()
    AttributeError: 'module' object has no attribute 'lru_cache'

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-4XOHna/django/
    Failed to installed django.
    Do you want to skip this? (yes/no) 
pi@raspberrypi:~ $ python -V
Python 2.7.13
pi@raspberrypi:~ $ which python
/usr/bin/python
pi@raspberrypi:~ $ which pip
/usr/bin/pip

Searching on the Django documentation I noticed that the Django 2.0 is not compatible with python 2.7.13. Django installation

I thinking that your script needs check the version of python and run the correct command.

In my case the version is 3.5.3 so I needed to use this command: sudo pip3 install django