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

myth: command not found #546

Closed
msayyad opened this issue Oct 7, 2018 · 11 comments
Closed

myth: command not found #546

msayyad opened this issue Oct 7, 2018 · 11 comments

Comments

@msayyad
Copy link

msayyad commented Oct 7, 2018

after doing steps for installing mythril, ubuntu shell will show error and cant find it:

hex0r@ubuntu:~$ myth
myth: command not found

@dmuhs
Copy link
Contributor

dmuhs commented Oct 7, 2018

Did you install Mythril using pip3?
In that case on Ubuntu your binary should be located in /home/<username>/.local/bin/myth. With echo $PATH you can output your current path variable to make sure that the path contains the local bin directory.

@msayyad
Copy link
Author

msayyad commented Oct 9, 2018

i install it using pip3. i run mythril from /.local/binmyth but get error

uuu@ubuntu:~/.local/bin$ myth
Traceback (most recent call last):
File "/usr/local/bin/myth", line 4, in
import('pkg_resources').run_script('mythril==0.18.11', 'myth')
File "/home/hex0r/.local/lib/python3.5/site-packages/pkg_resources/init.py", line 661, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/home/hex0r/.local/lib/python3.5/site-packages/pkg_resources/init.py", line 1441, in run_script
exec(code, namespace, namespace)
File "/usr/local/lib/python3.5/dist-packages/mythril-0.18.11-py3.5.egg/EGG-INFO/scripts/myth", line 6, in
import mythril.interfaces.cli
File "/usr/local/lib/python3.5/dist-packages/mythril-0.18.11-py3.5.egg/mythril/interfaces/cli.py", line 16, in
from mythril.mythril import Mythril
File "/usr/local/lib/python3.5/dist-packages/mythril-0.18.11-py3.5.egg/mythril/mythril.py", line 13, in
from ethereum import utils
File "/home/hex0r/.local/lib/python3.5/site-packages/ethereum/init.py", line 11, in
from . import slogging # noqa
File "/home/hex0r/.local/lib/python3.5/site-packages/ethereum/slogging.py", line 6, in
from ethereum.utils import bcolors, is_numeric
File "/home/hex0r/.local/lib/python3.5/site-packages/ethereum/utils.py", line 11, in
import rlp
File "/home/hex0r/.local/lib/python3.5/site-packages/rlp/init.py", line 1, in
from . import sedes # noqa: F401
File "/home/hex0r/.local/lib/python3.5/site-packages/rlp/sedes/init.py", line 4, in
from .big_endian_int import BigEndianInt, big_endian_int # noqa: F401
File "/home/hex0r/.local/lib/python3.5/site-packages/rlp/sedes/big_endian_int.py", line 1, in
from eth_utils import (
File "/home/hex0r/.local/lib/python3.5/site-packages/eth_utils/init.py", line 24, in
from .applicators import ( # noqa: F401
File "/home/hex0r/.local/lib/python3.5/site-packages/eth_utils/applicators.py", line 29, in
def combine_argument_formatters(*formatters: List[Callable[..., Any]]) -> Formatters:
File "/usr/lib/python3.5/typing.py", line 1025, in getitem
tvars = _type_vars(params)
File "/usr/lib/python3.5/typing.py", line 284, in _type_vars
_get_type_vars(types, tvars)
File "/usr/lib/python3.5/typing.py", line 279, in _get_type_vars
t._get_type_vars(tvars)
File "/usr/lib/python3.5/typing.py", line 786, in _get_type_vars
_get_type_vars(self.args, tvars)
File "/usr/lib/python3.5/typing.py", line 277, in _get_type_vars
for t in types:
TypeError: 'ellipsis' object is not iterable

@dmuhs
Copy link
Contributor

dmuhs commented Oct 9, 2018

This seems to be an issue with the typing of Python 3.5. Can you provide the output of python3.5 -V? There might be typing issues with versions below Python 3.5.3.

@dmuhs
Copy link
Contributor

dmuhs commented Oct 18, 2018

@msayyad Any update on the issue?

@msayyad
Copy link
Author

msayyad commented Oct 23, 2018

@dmuhs i install python 3.5.5 from source and try with pip3 but this erorr

error: could not create '/usr/local/lib/python3.5/site-packages/pycparser': Permission denied

----------------------------------------

Command "/usr/local/bin/python3.5 -u -c "import setuptools, tokenize;file='/tmp/pip-build-e3wncqpq/pycparser/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-m15xzmef-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-e3wncqpq/pycparser/
You are using pip version 9.0.1, however version 18.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

@dmuhs
Copy link
Contributor

dmuhs commented Oct 23, 2018

@msayyad This seems to be less of an issue connected to Mythril but rather a permission issue with your Python installation. Please check out other solutions for that problem.

@JoranHonig
Copy link
Collaborator

This seems to be a stale issue -> closing 🙌

@DmytroShalaiev
Copy link

Have same issue, installed using pip3

illuschwo@MacBook-Pro-Dmytro dist % mytxs-cli
zsh: command not found: mytxs-cli
illuschwo@MacBook-Pro-Dmytro dist % mythx
zsh: command not found: mythx
illuschwo@MacBook-Pro-Dmytro dist % 
illuschwo@MacBook-Pro-Dmytro site-packages % pip3 show mythx-cli    
Name: mythx-cli
Version: 0.7.2
Summary: A command line interface for the MythX smart contract security analysis API
Home-page: https://github.com/dmuhs/mythx-cli
Author: Dominik Muhs
Author-email: dominik.muhs@consensys.net
License: MIT license
Location: /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages
Requires: Click, htmlmin, Jinja2, MarkupSafe, py-solc-x, pythx, PyYAML, tabulate
Required-by: 
illuschwo@MacBook-Pro-Dmytro site-packages % 

@RojhatToptamus
Copy link

RojhatToptamus commented Aug 22, 2022

You should add Mythril location to the PATH

  1. Copy the location: pip3 show mythril
  2. open ~/.zshrc
  3. Paste the location on zshrc file: export PATH="/Library/Frameworks/Python.framework/Versions/3.10/bin:${PATH}"
  4. Update the CLI: source ~/.zshrc
  5. myth

@pietrociatta
Copy link

Location:

Follower your guide, but still "command not found"... i've the same path as the previous guy /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages but in your guide you say to add another one... why?

@prik
Copy link

prik commented Feb 20, 2023

Follower your guide, but still "command not found"... i've the same path as the previous guy /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages but in your guide you say to add another one... why?

For those with the same question, here is the likely solution:

export PATH=$PATH:/Users/[USER]/Library/Python/3.9/bin
source ~/.zshrc

Replace 3.9 with your version if needed.
I hope this helped 🥂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants