I am using Windows 10 I have downloaded LEAN and installed all its dependencies except for pythonnet. When I tried to run setup.py I get this error message:
Install/updates required packages
---------------------------------
[conda] Successfully installed/updated: setuptools, pandas, pip, conda, wheel
Install/updates pythonnet
-------------------------
Could not install packages due to an EnvironmentError: [WinError 5] Access is denied: 'C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\pip-uninstall-0v3f60vy\\users\\administrator\\appdata\\local\\continuum\\anaconda3\\lib\\site-packages\\clr.pyd'
Consider using the `--user` option or check the permissions.
When I tried to compile lean with visual studio I get this error on my backtest window log
2018-09-17T04:57:04.7466506Z Error Algorithm.Initialize() Error: During the algorithm initialization, the following exception has occurred: Loader.TryCreatePythonAlgorithm(): Unable to import python module ../../../Algorithm.Python/BasicTemplateAlgorithm.py. AlgorithmPythonWrapper(): The dynamic-link library for python3.6m could not be found. Please visit https://github.com/QuantConnect/Lean/blob/master/Algorithm.Python/readme.md for instructions on how to enable python support in Win32NT Unable to load DLL 'python3.6m': The specified module could not be found. (Exception from HRESULT: 0x8007007E) Stack Trace: QuantConnect.Lean.Engine.Setup.AlgorithmSetupException: During the algorithm initialization, the following exception has occurred: Loader.TryCreatePythonAlgorithm(): Unable to import python module ../../../Algorithm.Python/BasicTemplateAlgorithm.py. AlgorithmPythonWrapper(): The dynamic-link library for python3.6m could not be found. Please visit https://github.com/QuantConnect/Lean/blob/master/Algorithm.Python/readme.md for instructions on how to enable python support in Win32NT Unable to load DLL 'python3.6m': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at QuantConnect.Lean.Engine.Setup.ConsoleSetupHandler.CreateAlgorithmInstance(AlgorithmNodePacket algorithmNodePacket, String assemblyPath) in C:\Users\Administrator\Desktop\Lean-master\Engine\Setup\ConsoleSetupHandler.cs:line 92
at QuantConnect.Lean.Engine.Engine.Run(AlgorithmNodePacket job, AlgorithmManager manager, String assemblyPath) in C:\Users\Administrator\Desktop\Lean-master\Engine\Engine.cs:line 114
QuantConnect.Lean.Engine.Setup.AlgorithmSetupException: During the algorithm initialization, the following exception has occurred: Loader.TryCreatePythonAlgorithm(): Unable to import python module ../../../Algorithm.Python/BasicTemplateAlgorithm.py. AlgorithmPythonWrapper(): The dynamic-link library for python3.6m could not be found. Please visit https://github.com/QuantConnect/Lean/blob/master/Algorithm.Python/readme.md for instructions on how to enable python support in Win32NT Unable to load DLL 'python3.6m': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at QuantConnect.Lean.Engine.Setup.ConsoleSetupHandler.CreateAlgorithmInstance(AlgorithmNodePacket algorithmNodePacket, String assemblyPath) in C:\Users\Administrator\Desktop\Lean-master\Engine\Setup\ConsoleSetupHandler.cs:line 92
at QuantConnect.Lean.Engine.Engine.Run(AlgorithmNodePacket job, AlgorithmManager manager, String assemblyPath) in C:\Users\Administrator\Desktop\Lean-master\Engine\Engine.cs:line 114
It seems to me the issue is probably this
Unable to import python module ../../../Algorithm.Python/BasicTemplateAlgorithm.py. AlgorithmPythonWrapper(): The dynamic-link library for python3.6m could not be found.
Any help will be appreciated
Alexandre Catarino
Could please check whether pip have access rights to anaconda's site-package folder?
The error message is a consequence of this command:
pip install git+https://github.com/QuantConnect/pythonnet
Please try to run it in the command line, if it fails, you can try to add --user.
Benjamin Chow
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!