-
Notifications
You must be signed in to change notification settings - Fork 18
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
Build fails under pyenv: build/bin/grumpc: line 18: A Python -> Go transcompiler.: command not found #24
Comments
Can you paste the result of:
|
here you are ➜ grumpy git:(master) head build/src/grumpy/lib/__builtin__/module.go
Version: ImageMagick 6.9.5-1 Q16 x86_64 2016-07-11 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2016 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Features: Cipher DPC Modules
Delegates (built-in): bzlib freetype jng jpeg ltdl lzma png tiff xml zlib
Usage: import [options ...] [ file ]
Image Settings:
-adjoin join images into a single multi-image file
-border include window border in the output image |
That's very odd. It looks like some random program has generated the module.go file, not grumpc, the Grumpy compiler. There must be something unexpected in your environment. I would suggest |
Now I met error like it ➜ grumpy git:(master) rm -rf build
➜ grumpy git:(master) echo "print 'hello, world'" | make run
build/bin/grumpc: line 18: A Python -> Go transcompiler.: command not found
import: delegate library support not built-in `' (X11) @ error/import.c/ImportImageCommand/1297.
import: delegate library support not built-in `' (X11) @ error/import.c/ImportImageCommand/1297.
import: delegate library support not built-in `' (X11) @ error/import.c/ImportImageCommand/1297.
import: delegate library support not built-in `' (X11) @ error/import.c/ImportImageCommand/1297.
from: can't read /var/mail/grumpy.compiler
from: can't read /var/mail/grumpy.compiler
from: can't read /var/mail/grumpy.compiler
build/bin/grumpc: line 30: syntax error near unexpected token `('
build/bin/grumpc: line 30: `parser = argparse.ArgumentParser()'
make: *** [build/src/grumpy/lib/__builtin__/module.go] Error 2 |
import is screen shot command by imagemagick, looks like your shell doing something different. Try |
Now it works! What's the problem? ➜ grumpy git:(master) git checkout 3adaa1a
Note: checking out '3adaa1a'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
git checkout -b <new-branch-name>
HEAD is now at 3adaa1a... make itertools.chain be a class and from_iterable a classmethod of chain
➜ grumpy git:(3adaa1a) rm -rf build
➜ grumpy git:(3adaa1a) make clean
➜ grumpy git:(3adaa1a) echo "print 'hello, world'" | make run
hello, world |
@trotterdylan, Looks like there is some issue with recent Makefile changes. I can't think of which one though. @growingdever , what is your python -V, python2 -V, env python -V? |
I'm using pyenv. Global python, python2 version is 2.7.12 |
@growingdever Could you paste the output of: |
Looks like shebang is lost, so may be another sed issue
|
|
What you get when you type |
@growingdever I meant what is Thanks for your help debugging this. |
➜ grumpy git:(3adaa1a) /usr/bin/env python -V
Python 2.7.12 |
@S-YOU I think you're right that the shebang line is gone and it's being interpreted as a sh script. |
His head output show there is still #!/usr/bin/env python and /usr/bin/env python -V correct though, |
@S-YOU But I think that shebang line is from 3adaa1a, before the Makefile change. |
I see, does make run change those shebang on the fly? |
|
@growingdever , I think we need head build/bin/grumpc and /usr/bin/env python -V from master, not that commit. Please do git checkout master and make clean, make, head build/bin/grumpc, /usr/bin/env python -V |
|
how about |
I don't configure any python versions for grumpy.
|
looks like those python binary are shell scripts @trotterdylan, may be instead of replacing the whole shebang, |
Yes. It's shell script. ➜ grumpy git:(master) cat ~/.pyenv/shims/python
#!/usr/bin/env bash
set -e
[ -n "$PYENV_DEBUG" ] && set -x
program="${0##*/}"
if [[ "$program" = "python"* ]]; then
for arg; do
case "$arg" in
-c* | -- ) break ;;
*/* )
if [ -f "$arg" ]; then
export PYENV_FILE_ARG="$arg"
break
fi
;;
esac
done
fi
export PYENV_ROOT="/Users/juhongjung/.pyenv"
exec "/Users/juhongjung/.pyenv/libexec/pyenv" exec "$program" "$@" |
If you have a system install of Python you might be able to work around this by specifying it as the PYTHON variable to make. First |
Right. |
Thanks for reporting this. I think I'll need to try pyenv to reproduce this issue so I may not get around to it right away. |
Closing in favor of #25. It was imported correctly. |
I cloned grumpy and run method 1, but it cause error
The text was updated successfully, but these errors were encountered: