Heroku Upload - Could not find a version that satisfies the requirement anaconda-client==1.4.0

后端 未结 5 1200
忘了有多久
忘了有多久 2020-12-17 17:45

I\'m trying to push a Django app onto Heroku, but am getting the following error upon running git push heroku master:

Counting objects: 80, done         


        
相关标签:
5条回答
  • 2020-12-17 18:25

    According to PyPI, there's no such thing as anaconda-client version 1.4.0: the highest version is 1.2.2.

    0 讨论(0)
  • 2020-12-17 18:28

    Try also this:

    pip freeze>requirements.txt
    

    Then try again with

    git add .
    git commit -m "something"
    git push heroku master
    
    0 讨论(0)
  • 2020-12-17 18:45

    For every message

    No matching distribution found for X

    that you get, you have to manually remove that line from requirements.txt file:

    1 - remove the line where X appears
    2 - save the file
    3 - commit
    4 - push

    do it again for the next error reported by the prompt, until you reach the end of the list cointained in requirements.txt

    0 讨论(0)
  • 2020-12-17 18:47

    Have you created environment in the conda ?

    If so, after you activate the env. you need to conda install pip to activate pip install, otherwise your pip freeze would go back to the default anaconda environment. (thats why you are seeing them there)

    1. conda install pip
    2. pip install all the available packages again. (e.g. pip install django)
    3. pip freeze > requirements.txt

    Please see myth 5 below https://jakevdp.github.io/blog/2016/08/25/conda-myths-and-misconceptions/

    0 讨论(0)
  • 2020-12-17 18:49

    The solution for this error is pretty simple:

    1. I hope you already have created requirements.txt file in your app folder, you ran pip > freeze command and made a commit and pushed.

    When you do that pip can also automatically add modules to the file, Pip can also install a dependency from your local codebase automatically. That can be a problem.

    1. Simply go to your requirement.txt file and look for anaconda-client==1.4.0 (or error starting with "No matching distribution found for" a module) and remove it from the file.

    2. Save the file, commit and push.

    I had the similar problem and error with conda and i took the same steps and it worked for me.

    I hope it helps some of you guys.

    0 讨论(0)
提交回复
热议问题