Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automator not working #6

Closed
LinusKaiser opened this issue Mar 8, 2022 · 2 comments
Closed

Automator not working #6

LinusKaiser opened this issue Mar 8, 2022 · 2 comments

Comments

@LinusKaiser
Copy link

LinusKaiser commented Mar 8, 2022

It seems that when using the automator installations that come with the pubmex the pubmex.py can not be found.

    for f in "$@"
    do
        pubmex.py $f
    done

The following error is displayed:

The action “Run Shell Script” encountered an error: “zsh:3: command not found: pubmex.py”

When specifying the direct location of just the pubmex.py file another error occures.

    for f in "$@"
    do
        /users/suntim/miniforge3/bin/pubmex.py $f
    done

The following error is displayed:

The action “Run Shell Script” encountered an error: “”

When specifying the direct location of python and the pubmex.py file another error occures.

    for f in "$@"
    do
        /usr/local/bin/python3 /users/suntim/miniforge3/bin/pubmex.py $f
    done

The following error is displayed:

The action “Run Shell Script” encountered an error: “Traceback (most recent call last): File "/users/suntim/miniforge3/bin/pubmex.py", line 27, in <module> from Bio import Entrez ModuleNotFoundError: No module named 'Bio'”

I have all dependencies installed pip3 install pubmex, pip3 install biopython, brew install poppler. As it says in the readme.md that biopython should be isntalled via brew I assume that was a mistake. I instead installed it via pip3.

The same error messages occure regardless of using the zsh or bash version.

@LinusKaiser
Copy link
Author

I came up with a solution to this problem. The environment variables of the automator zsh are not the same of the main system. by changing the path to the system paths it works. For me:

PATH=/Users/suntim/miniforge3/bin:/Users/suntim/miniforge3/condabin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games

With that it works

@mmagnus
Copy link
Owner

mmagnus commented Mar 12, 2022

dear @LinusKaiser or add source ~/.zshrc at the beginning of the Workflow, this should also help to find pubmex.py

I updated the Workflows now in this repo as well.

sc 2022-03-12 at 18 35 05

mmagnus added a commit that referenced this issue Mar 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants