Skip to content

python: command not found #36

@lirenyeo

Description

@lirenyeo

Error Message:

[22:03:43.349] STDERR: Gist[[Run Script] functions.sh: line 236: python: command not found

I'm not sure how does the shim work for Alfred? I have python 2 installed via pyenv:

❯ which python                                                                                                                                                                          ─╯
/Users/liren/.pyenv/shims/python

❯ python --version                                                                                                                                                                      ─╯
Python 2.7.18

However the /usr/bin/python3 executable could be read by the Alfred Workflow, so I tried changing the script to python3:

echo -n "$1" | python3 -c 'import json,sys; print json.dumps(sys.stdin.read())'

But I don't think the string can be parsed correctly because I will still get error from gist API:

{
  "message": "Problems parsing JSON",
  "documentation_url": "https://docs.github.com/rest/reference/gists#create-a-gist"
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions