Python algos in a file with the algo name like C#

build.bat (batch.sh in Linux) includes the code inside the file with the desired algorithm (set in config.json by "algorithm-type-name") in the python DLL (QuantConnect.Algorithm.Python.dll) via IronPython.
In the AlgorithmFactory,  Loader.TryCreatePythonAlgorithm imports the module with the algorithm name instead of "main".
This commit is contained in:
AlexCatarino
2016-02-13 10:52:44 -02:00
parent da957790ec
commit 0af069d541
5 changed files with 58 additions and 7 deletions
@@ -96,9 +96,6 @@
</None>
<None Include="Lib\ensurepip\_bundled\pip-1.5.6-py2.py3-none-any.whl" />
<None Include="Lib\ensurepip\_bundled\setuptools-3.6-py2.py3-none-any.whl" />
<None Include="main.py">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="build.bat">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
@@ -106,6 +103,7 @@
<None Include="readme.md" />
</ItemGroup>
<ItemGroup>
<Content Include="BasicTemplateAlgorithm.py" />
<Content Include="Lib\abc.py" />
<Content Include="Lib\aifc.py" />
<Content Include="Lib\antigravity.py" />