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

Manticore not running - ModuleNotFoundError: No module named 'fcntl' #2612

Open
krypston104 opened this issue Jan 1, 2023 · 2 comments
Open
Labels

Comments

@krypston104
Copy link

I installed Manticore with pip3 install manticore in a python virtual environment. It went trouble free save for some warnings. Logs are attached below.

When I try to run Manticore I get the error: ModuleNotFoundError: No module named 'fcntl'

(env) PS D:\PROJECTS\SOLIDITY\TEST\contracts\farm> manticore LevelMaster.sol               
Traceback (most recent call last):
  File "C:\Program Files\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Program Files\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "D:\PROJECTS\SOLIDITY\TEST\env\Scripts\manticore.exe\__main__.py", line 4, in <module>
  File "D:\PROJECTS\SOLIDITY\TEST\env\lib\site-packages\manticore\__init__.py", line 9, in <module>
    from .core.smtlib import issymbolic, istainted
  File "D:\PROJECTS\SOLIDITY\TEST\env\lib\site-packages\manticore\core\smtlib\__init__.py", line 3, in <module>
    from .solver import *  # noqa
  File "D:\PROJECTS\SOLIDITY\TEST\env\lib\site-packages\manticore\core\smtlib\solver.py", line 18, in <module> 
    import fcntl
ModuleNotFoundError: No module named 'fcntl'

As far as I could find out there is no such a package available for Windows, which I am using. Does this mean Manticore does not run on windows. Is there a way to get over this?

Manticore version

Name: manticore
Version: 0.3.7

Python version

Python 3.10.9

OS / Environment

Windows 10 Pro

Dependencies

crytic-compile==0.2.2
cytoolz==0.12.1
eth-hash==0.5.1
eth-typing==3.2.0
eth-utils==2.1.0
future==0.18.2
intervaltree==3.1.0
manticore==0.3.7
ply==3.11
prettytable==3.5.0
protobuf==4.21.12
pyevmasm==0.2.3
pysha3==1.0.2
PyYAML==6.0
rlp==3.0.0
sortedcontainers==2.4.0
toolz==0.12.0
wasm==1.2
wcwidth==0.2.5
z3-solver==4.11.2.0

Any relevant logs

Installation logs:

(env) PS D:\PROJECTS\NPM\SOLIDITY\HACK TESTS\LEVEL FINANCE\level-core-contracts-master> pip3 install manticore
Collecting manticore
  Using cached manticore-0.3.7-py3-none-any.whl (420 kB)
Collecting crytic-compile==0.2.2
  Using cached crytic_compile-0.2.2-py3-none-any.whl
Collecting wasm
  Using cached wasm-1.2-py3-none-any.whl (15 kB)
Collecting pyevmasm>=0.2.3
  Using cached pyevmasm-0.2.3-py3-none-any.whl (15 kB)
Collecting rlp
  Using cached rlp-3.0.0-py2.py3-none-any.whl (20 kB)
Collecting protobuf
  Using cached protobuf-4.21.12-cp310-abi3-win_amd64.whl (527 kB)
Collecting intervaltree
  Using cached intervaltree-3.1.0.tar.gz (32 kB)
  Preparing metadata (setup.py) ... done
Collecting pyyaml
  Using cached PyYAML-6.0-cp310-cp310-win_amd64.whl (151 kB)
Collecting z3-solver
  Using cached z3_solver-4.11.2.0-py2.py3-none-win_amd64.whl (56.2 MB)
Collecting prettytable
  Using cached prettytable-3.5.0-py3-none-any.whl (26 kB)
Collecting pysha3
  Using cached pysha3-1.0.2.tar.gz (829 kB)
  Preparing metadata (setup.py) ... done
Collecting ply
  Using cached ply-3.11-py2.py3-none-any.whl (49 kB)
Collecting future
  Using cached future-0.18.2.tar.gz (829 kB)
  Preparing metadata (setup.py) ... done
Collecting sortedcontainers<3.0,>=2.0
  Using cached sortedcontainers-2.4.0-py2.py3-none-any.whl (29 kB)
Collecting wcwidth
  Using cached wcwidth-0.2.5-py2.py3-none-any.whl (30 kB)
Collecting eth-utils<3,>=2.0.0
  Using cached eth_utils-2.1.0-py3-none-any.whl (24 kB)
Requirement already satisfied: setuptools in d:\projects\npm\solidity\hack tests\level finance\level-core-contracts-master\env\lib\site-packages (from wasm->manticore) (65.5.0)
Collecting cytoolz>=0.10.1
  Downloading cytoolz-0.12.1-cp310-cp310-win_amd64.whl (321 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 321.4/321.4 kB 4.0 MB/s eta 0:00:00
Collecting eth-hash>=0.3.1
  Using cached eth_hash-0.5.1-py3-none-any.whl (9.0 kB)
Collecting eth-typing>=3.0.0
Collecting toolz>=0.8.0
  Using cached toolz-0.12.0-py3-none-any.whl (55 kB)
Installing collected packages: z3-solver, wcwidth, sortedcontainers, pysha3, ply, wasm, toolz, pyyaml, protobuf, prettytable, intervaltree, future, eth-typing, eth-hash, crytic-compile, pyevmasm, cytoolz, eth-utils, rlp, manticore
  DEPRECATION: pysha3 is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will 
enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559
  Running setup.py install for pysha3 ... done
  DEPRECATION: intervaltree is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559
  Running setup.py install for intervaltree ... done
  DEPRECATION: future is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will 
enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559
  Running setup.py install for future ... done
otobuf-4.21.12 pyevmasm-0.2.3 pysha3-1.0.2 pyyaml-6.0 rlp-3.0.0 sortedcontainers-2.4.0 toolz-0.12.0 wasm-1.2 wcwidth-0.2.5 z3-solver-4.11.2.0


@krypston104 krypston104 added the bug label Jan 1, 2023
@ekilmer
Copy link
Contributor

ekilmer commented Jan 3, 2023

Unfortunately, Manticore does not support installation or running on Windows. You could try installing and running through Windows Subsystem for Linux (WSL) or using the Dockerfile in this repo

@Simon1V
Copy link

Simon1V commented Jan 6, 2023

The main culprit is fcntl, which isn't available on Windows. A possible alternative could be Portalocker which appears to deliver an adequate functionality but is available on Windows as well.

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

No branches or pull requests

3 participants