afewmail / afew

an initial tagging script for notmuch mail
ISC License
325 stars 98 forks source link

Installation fail (python 3.5), notmuch dependency not found by pip #209

Closed reyman closed 5 years ago

reyman commented 6 years ago

I try the two way (with python 3.2 and python 3.5) to install afew with pyenv virtualenv, and notmuch dependency is not found in both case.

I'm using the latest version of code on github

Using python setup.py install

Extracting afew-1.3.1.dev25+g6322531-py3.5.egg to /home/reyman/.pyenv/versions/3.5.0/envs/afew/lib/python3.5/site-packages
afew 1.3.1.dev25+g6322531 is already the active version in easy-install.pth
Installing afew script to /home/reyman/.pyenv/versions/3.5.0/envs/afew/bin

Installed /home/reyman/.pyenv/versions/3.5.0/envs/afew/lib/python3.5/site-packages/afew-1.3.1.dev25+g6322531-py3.5.egg
Processing dependencies for afew==1.3.1.dev25+g6322531
Searching for notmuch
Reading https://pypi.python.org/simple/notmuch/
Couldn't find index page for 'notmuch' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading https://pypi.python.org/simple/
No local packages or download links found for notmuch
error: Could not find suitable distribution for Requirement.parse('notmuch')
(3.5.0/envs/afew) 

Using pip install

Requirement already satisfied: afew in /home/reyman/.pyenv/versions/3.5.0/envs/afew/lib/python3.5/site-packages/afew-1.3.1.dev25+g6322531-py3.5.egg (1.3.1.dev25+g6322531)
Collecting notmuch (from afew)
  Could not find a version that satisfies the requirement notmuch (from afew) (from versions: )
No matching distribution found for notmuch (from afew)
reyman commented 6 years ago

Found the way ...

a) Install python3-notmuch or python-notmuch binding on your system b) Clone the notmuch repo to your home c) go to /bindings/python/ d) run python setup.py install to build notmuch package e) go back to afew folder f) run python setup.py install to build afew, pip found the notmuch package build on d)

flokli commented 5 years ago

@reyman did you spot https://github.com/afewmail/afew/blob/master/docs/source/installation.rst ? It should already properly document how to install it…

dmitrym0 commented 5 years ago

@flokli I ignored the aptitude command line 'cause I'm on a mac :)

dmitrym0 commented 5 years ago

On MacOS Mojave

flokli commented 5 years ago

@dmitrym0 on MacOS, you could probably also simply use Nix to install afew, including its dependencies.

I'm not sure on the homebrew state of things - last time I checked, the notmuch python bindings there were Python 2 only, while afew stopped supporting Python 2 some time ago.

pejaab commented 5 years ago

In case someone else stumbles over this issue. On MacOs one can also symlink the brew installed notmuch python bindings to wherever afew is installed to, i.e. ln -s /path/to/notmuch/0.29.1/lib/python3.7/site-packages/notmuch-0.29.1-py3.7.egg-info/ /path/to/lib/python3.7/site-packages/