Search code examples
pythoninstallationkivysubprocesskivymd

Why it says error when installing KivyMD on Windows?


Please help me solve this error. I followed the instructions from kivy documentation but this is what happened. I don't know what to do in this problem.

I tried installing kivymd zip file, but I encountered error. Then, I tried replacing the "master.zip" into the .zip which became "pip install https://github.com/kivymd/KivyMD/archive/3d3e45dda146fef3f4758aea548da199e10eb382.zip". Still, I encountred the same error. this is the outcome:

ERROR: Could not find a version that satisfies the requirement kivy_deps.sdl2_dev~=0.3.1 (from versions: 0.5.1, 0.6.0, 0.7.0)
      ERROR: No matching distribution found for kivy_deps.sdl2_dev~=0.3.1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.`

I'm completely a beginner in kivy and generally, in coding so I really felt hopelessness after my numerous try with it.


Solution

  • I also had a similar problem that could not install kivymd. this is how it was resolved: in cmd:

    netstat -a -n
    

    then it gives a proxy list. Try some of them (ID:port) :

    pip install --proxy="https://ID:port" kivymd
    

    It may give an error, but continue:

    C:\...\python.exe -m pip install --upgrade pip
    

    (C:..) is the path of Python.exe on your computer. this way updates the pip. then:

    pip install kivymd
    

    This way was helpful for me. I hope it will be useful for others.