Closed spitzbubchen closed 3 years ago
Hi, try using python 3.6. Other versions will be supported in the future after I get everything stabled.
Sorry for hijacking this issue...would you mind to perhaps elaborate on you idea/plans to 'get everything stable'? I guess if you would be able to split this in small or bigger chunks (or perhaps just a general road map) you potentially could leverage parts of community input/contributions
Hi @TheSnoozer, not in a specific order, but these are some of the things ahead:
but it all depends on how the community around this package grows
Still no luck... This is what I tried:
sudo add-apt-repository ppa:deadsnakes/ppa sudo apt-get update sudo apt-get install libatlas-base-dev python-dev gfortran pkg-config libfreetype6-dev hdf5-tools python3-virtualenv python3.6 git clone https://github.com/shlomikushchi/zipline-trader.git cd zipline-trader virtualenv -p python3.6 venv-3.6 . venv-3.6/bin/activate pip install -e .
(venv-3.6) spitz:~/Projects/zipline-trader$ pip install -e .
Obtaining file:///home/rod/Projects/zipline-trader
Requirement already satisfied: pip>=7.1.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (20.3.3)
Requirement already satisfied: setuptools>18.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (51.0.0)
Requirement already satisfied: Logbook>=0.12.5 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.5.3)
Requirement already satisfied: click>=4.0.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (7.1.2)
Requirement already satisfied: six>=1.10.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.15.0)
Requirement already satisfied: python-interface>=1.5.3 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.6.0)
Requirement already satisfied: multipledispatch>=0.6.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.6.0)
Requirement already satisfied: toolz>=0.8.2 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.11.1)
Requirement already satisfied: numpy>=1.11.3 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.19.4)
Requirement already satisfied: pandas<=0.22,>=0.18.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.22.0)
Requirement already satisfied: pandas-datareader<0.9.0,>=0.2.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.8.1)
Requirement already satisfied: scipy>=0.17.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.5.4)
Requirement already satisfied: patsy>=0.4.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.5.1)
Requirement already satisfied: statsmodels>=0.6.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.12.1)
Requirement already satisfied: empyrical>=0.5.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.5.5)
Requirement already satisfied: pytz>=2018.5 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (2020.4)
Requirement already satisfied: iso3166>=0.9 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.0.1)
Requirement already satisfied: trading-calendars>=1.6.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (2.1.0)
Requirement already satisfied: requests>=2.9.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (2.25.1)
Requirement already satisfied: sqlalchemy>=1.0.8 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.3.22)
Requirement already satisfied: tables>=3.4.3 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (3.6.1)
Requirement already satisfied: lru-dict>=1.1.4 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.1.6)
Requirement already satisfied: intervaltree>=2.1.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (3.1.0)
Requirement already satisfied: bottleneck>=1.0.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.3.2)
Requirement already satisfied: networkx<2.0,>=1.9.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.11)
Requirement already satisfied: numexpr>=2.6.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (2.7.1)
Requirement already satisfied: iso4217>=1.6.20180829 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.6.20180829)
Requirement already satisfied: websockets<9,>=7.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (8.1)
Requirement already satisfied: PyYAML==5.3.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (5.3.1)
Requirement already satisfied: IbPy2==0.8.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.8.0)
Requirement already satisfied: polling==0.3.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (0.3.1)
Requirement already satisfied: h5py==2.10.0 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (2.10.0)
Requirement already satisfied: html5lib==1.1 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (1.1)
Requirement already satisfied: beautifulsoup4==4.9.3 in ./venv-3.6/lib/python3.6/site-packages (from zipline-trader==1.5.0rc7+66.g1af970ca) (4.9.3)
Collecting bcolz==1.2.1
Using cached bcolz-1.2.1.tar.gz (1.5 MB)
Requirement already satisfied: soupsieve>1.2 in ./venv-3.6/lib/python3.6/site-packages (from beautifulsoup4==4.9.3->zipline-trader==1.5.0rc7+66.g1af970ca) (2.1)
Requirement already satisfied: webencodings in ./venv-3.6/lib/python3.6/site-packages (from html5lib==1.1->zipline-trader==1.5.0rc7+66.g1af970ca) (0.5.1)
Collecting alembic>=0.7.7
Using cached alembic-1.4.3-py2.py3-none-any.whl (159 kB)
Requirement already satisfied: Mako in ./venv-3.6/lib/python3.6/site-packages (from alembic>=0.7.7->zipline-trader==1.5.0rc7+66.g1af970ca) (1.1.3)
Requirement already satisfied: python-editor>=0.3 in ./venv-3.6/lib/python3.6/site-packages (from alembic>=0.7.7->zipline-trader==1.5.0rc7+66.g1af970ca) (1.0.4)
Requirement already satisfied: python-dateutil in ./venv-3.6/lib/python3.6/site-packages (from alembic>=0.7.7->zipline-trader==1.5.0rc7+66.g1af970ca) (2.8.1)
Collecting alpaca-trade-api>=0.51.0
Using cached alpaca_trade_api-0.51.0-py3-none-any.whl (39 kB)
Requirement already satisfied: websocket-client<1,>=0.56.0 in ./venv-3.6/lib/python3.6/site-packages (from alpaca-trade-api>=0.51.0->zipline-trader==1.5.0rc7+66.g1af970ca) (0.57.0)
Requirement already satisfied: urllib3<1.26,>1.24 in ./venv-3.6/lib/python3.6/site-packages (from alpaca-trade-api>=0.51.0->zipline-trader==1.5.0rc7+66.g1af970ca) (1.25.11)
Requirement already satisfied: sortedcontainers<3.0,>=2.0 in ./venv-3.6/lib/python3.6/site-packages (from intervaltree>=2.1.0->zipline-trader==1.5.0rc7+66.g1af970ca) (2.3.0)
Requirement already satisfied: decorator>=3.4.0 in ./venv-3.6/lib/python3.6/site-packages (from networkx<2.0,>=1.9.1->zipline-trader==1.5.0rc7+66.g1af970ca) (4.4.2)
Requirement already satisfied: lxml in ./venv-3.6/lib/python3.6/site-packages (from pandas-datareader<0.9.0,>=0.2.1->zipline-trader==1.5.0rc7+66.g1af970ca) (4.6.2)
Requirement already satisfied: certifi>=2017.4.17 in ./venv-3.6/lib/python3.6/site-packages (from requests>=2.9.1->zipline-trader==1.5.0rc7+66.g1af970ca) (2020.12.5)
Requirement already satisfied: chardet<5,>=3.0.2 in ./venv-3.6/lib/python3.6/site-packages (from requests>=2.9.1->zipline-trader==1.5.0rc7+66.g1af970ca) (4.0.0)
Requirement already satisfied: idna<3,>=2.5 in ./venv-3.6/lib/python3.6/site-packages (from requests>=2.9.1->zipline-trader==1.5.0rc7+66.g1af970ca) (2.10)
Requirement already satisfied: MarkupSafe>=0.9.2 in ./venv-3.6/lib/python3.6/site-packages (from Mako->alembic>=0.7.7->zipline-trader==1.5.0rc7+66.g1af970ca) (1.1.1)
Building wheels for collected packages: bcolz
Building wheel for bcolz (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /home/rod/Projects/zipline-trader/venv-3.6/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-z6d8sxor
cwd: /tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/
Complete output (76 lines):
SSE2 detected
AVX2 detected
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.6
creating build/lib.linux-x86_64-3.6/bcolz
copying bcolz/attrs.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/defaults.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/arrayprint.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/utils.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/py2help_tests.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/version.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/toplevel.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/py2help.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/__init__.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/ctable.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/chunked_eval.py -> build/lib.linux-x86_64-3.6/bcolz
creating build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/common.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_carray.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/__init__.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/all.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_ndcarray.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_attrs.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_queries.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_carray_objects.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_ctable.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/carray_ext.pxd -> build/lib.linux-x86_64-3.6/bcolz
running build_ext
skipping 'bcolz/carray_ext.c' Cython extension (up-to-date)
building 'bcolz.carray_ext' extension
creating build/temp.linux-x86_64-3.6
creating build/temp.linux-x86_64-3.6/bcolz
creating build/temp.linux-x86_64-3.6/c-blosc
creating build/temp.linux-x86_64-3.6/c-blosc/blosc
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/lz4-1.8.1.2
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/snappy-1.1.1
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zlib-1.2.8
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/compress
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/deprecated
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/decompress
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/legacy
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/dictBuilder
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/common
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c bcolz/carray_ext.c -o build/temp.linux-x86_64-3.6/bcolz/carray_ext.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
In file included from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822,
from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from bcolz/carray_ext.c:525:
/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
17 | #warning "Using deprecated NumPy API, disable it with " \
| ^~~~~~~
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c c-blosc/blosc/shuffle-generic.c -o build/temp.linux-x86_64-3.6/c-blosc/blosc/shuffle-generic.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c c-blosc/blosc/shuffle.c -o build/temp.linux-x86_64-3.6/c-blosc/blosc/shuffle.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
c-blosc/blosc/shuffle.c:170:1: error: conflicting types for ‘_xgetbv’
170 | _xgetbv(uint32_t xcr) {
| ^~~~~~~
In file included from /usr/lib/gcc/x86_64-linux-gnu/9/include/immintrin.h:43,
from c-blosc/blosc/blosc-common.h:77,
from c-blosc/blosc/shuffle.h:18,
from c-blosc/blosc/shuffle.c:10:
/usr/lib/gcc/x86_64-linux-gnu/9/include/xsaveintrin.h:60:1: note: previous definition of ‘_xgetbv’ was here
60 | _xgetbv (unsigned int __A)
| ^~~~~~~
In file included from c-blosc/blosc/shuffle.c:11:
c-blosc/blosc/shuffle-generic.h:61:13: warning: ‘unshuffle_generic_inline’ defined but not used [-Wunused-function]
61 | static void unshuffle_generic_inline(const size_t type_size,
| ^~~~~~~~~~~~~~~~~~~~~~~~
c-blosc/blosc/shuffle-generic.h:32:13: warning: ‘shuffle_generic_inline’ defined but not used [-Wunused-function]
32 | static void shuffle_generic_inline(const size_t type_size,
| ^~~~~~~~~~~~~~~~~~~~~~
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for bcolz
Running setup.py clean for bcolz
Failed to build bcolz
Installing collected packages: bcolz, alpaca-trade-api, alembic, zipline-trader
Running setup.py install for bcolz ... error
ERROR: Command errored out with exit status 1:
command: /home/rod/Projects/zipline-trader/venv-3.6/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/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-record-7swjbyzt/install-record.txt --single-version-externally-managed --compile --install-headers /home/rod/Projects/zipline-trader/venv-3.6/include/site/python3.6/bcolz
cwd: /tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/
Complete output (76 lines):
SSE2 detected
AVX2 detected
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.6
creating build/lib.linux-x86_64-3.6/bcolz
copying bcolz/attrs.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/defaults.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/arrayprint.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/utils.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/py2help_tests.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/version.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/toplevel.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/py2help.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/__init__.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/ctable.py -> build/lib.linux-x86_64-3.6/bcolz
copying bcolz/chunked_eval.py -> build/lib.linux-x86_64-3.6/bcolz
creating build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/common.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_carray.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/__init__.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/all.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_ndcarray.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_attrs.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_queries.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_carray_objects.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/tests/test_ctable.py -> build/lib.linux-x86_64-3.6/bcolz/tests
copying bcolz/carray_ext.pxd -> build/lib.linux-x86_64-3.6/bcolz
running build_ext
skipping 'bcolz/carray_ext.c' Cython extension (up-to-date)
building 'bcolz.carray_ext' extension
creating build/temp.linux-x86_64-3.6
creating build/temp.linux-x86_64-3.6/bcolz
creating build/temp.linux-x86_64-3.6/c-blosc
creating build/temp.linux-x86_64-3.6/c-blosc/blosc
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/lz4-1.8.1.2
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/snappy-1.1.1
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zlib-1.2.8
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/compress
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/deprecated
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/decompress
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/legacy
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/dictBuilder
creating build/temp.linux-x86_64-3.6/c-blosc/internal-complibs/zstd-1.3.4/common
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c bcolz/carray_ext.c -o build/temp.linux-x86_64-3.6/bcolz/carray_ext.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
In file included from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822,
from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from bcolz/carray_ext.c:525:
/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
17 | #warning "Using deprecated NumPy API, disable it with " \
| ^~~~~~~
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c c-blosc/blosc/shuffle-generic.c -o build/temp.linux-x86_64-3.6/c-blosc/blosc/shuffle-generic.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fdebug-prefix-map=/build/python3.6-yK1u7P/python3.6-3.6.12=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DHAVE_LZ4=1 -DHAVE_SNAPPY=1 -DHAVE_ZLIB=1 -DHAVE_ZSTD=1 -Ibcolz -Ic-blosc/blosc -Ic-blosc/internal-complibs/lz4-1.8.1.2 -Ic-blosc/internal-complibs/zstd-1.3.4 -Ic-blosc/internal-complibs/snappy-1.1.1 -Ic-blosc/internal-complibs/zlib-1.2.8 -Ic-blosc/internal-complibs/zstd-1.3.4/compress -Ic-blosc/internal-complibs/zstd-1.3.4/deprecated -Ic-blosc/internal-complibs/zstd-1.3.4/decompress -Ic-blosc/internal-complibs/zstd-1.3.4/legacy -Ic-blosc/internal-complibs/zstd-1.3.4/dll -Ic-blosc/internal-complibs/zstd-1.3.4/dictBuilder -Ic-blosc/internal-complibs/zstd-1.3.4/common -I/home/rod/Projects/zipline-trader/venv-3.6/lib/python3.6/site-packages/numpy/core/include -I/home/rod/Projects/zipline-trader/venv-3.6/include -I/usr/include/python3.6m -c c-blosc/blosc/shuffle.c -o build/temp.linux-x86_64-3.6/c-blosc/blosc/shuffle.o -DSHUFFLE_SSE2_ENABLED -msse2 -DSHUFFLE_AVX2_ENABLED -mavx2
c-blosc/blosc/shuffle.c:170:1: error: conflicting types for ‘_xgetbv’
170 | _xgetbv(uint32_t xcr) {
| ^~~~~~~
In file included from /usr/lib/gcc/x86_64-linux-gnu/9/include/immintrin.h:43,
from c-blosc/blosc/blosc-common.h:77,
from c-blosc/blosc/shuffle.h:18,
from c-blosc/blosc/shuffle.c:10:
/usr/lib/gcc/x86_64-linux-gnu/9/include/xsaveintrin.h:60:1: note: previous definition of ‘_xgetbv’ was here
60 | _xgetbv (unsigned int __A)
| ^~~~~~~
In file included from c-blosc/blosc/shuffle.c:11:
c-blosc/blosc/shuffle-generic.h:61:13: warning: ‘unshuffle_generic_inline’ defined but not used [-Wunused-function]
61 | static void unshuffle_generic_inline(const size_t type_size,
| ^~~~~~~~~~~~~~~~~~~~~~~~
c-blosc/blosc/shuffle-generic.h:32:13: warning: ‘shuffle_generic_inline’ defined but not used [-Wunused-function]
32 | static void shuffle_generic_inline(const size_t type_size,
| ^~~~~~~~~~~~~~~~~~~~~~
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /home/rod/Projects/zipline-trader/venv-3.6/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lmc595fj/bcolz_c1a6b6cd231740f195e3ed66b7b82779/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-record-7swjbyzt/install-record.txt --single-version-externally-managed --compile --install-headers /home/rod/Projects/zipline-trader/venv-3.6/include/site/python3.6/bcolz Check the logs for full command output.
are you using mac? this is a known issue on mac os with bcolz (which is not yet solved) the solution for now is using a docker container that runs linux
Ubuntu 20.04 LTS
try using the docker image. use this as a reference: https://github.com/shlomikushchi/zipline-trader/blob/master/Dockerfile
Okay, finally got it to install using pip. This is the procedure I followed:
sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt-get update
sudo apt-get install libatlas-base-dev python-dev gfortran pkg-config libfreetype6-dev hdf5-tools python3-virtualenv python3.6
git clone https://github.com/shlomikushchi/zipline-trader.git
cd zipline-trader
virtualenv -p python3.6 venv
. venv/bin/activate
pip install -e . # if bcolz 1.2.1 crash try
export DISABLE_BCOLZ_AVX2=true
python setup.py build_ext --inplace
pip install -e .
However, after I ingest the alpaca bundle:
python zipline/data/bundles/alpaca_api.py
I get the following error when running the https://zipline-trader.readthedocs.io/en/latest/backtest.html example:
zipline.errors.SymbolNotFound: Symbol 'AMZN' was not found.
that means you didn't ingest amazon.
you can define the universe you ingest in the alpaca.yaml
file. I didn't document that yet, but I will soon.
even though, the default universe is SP500 which includes AMZN, you could try changing the symbol for now. I will document universe selection soon
I did have a hard time following the instructions located at https://zipline-trader.readthedocs.io/en/latest/alpaca-bundle-ingestion.html. I was not sure where or in what file to define ZIPLINE_ROOT=~/.zipline
or if running python zipline/data/bundles/alpaca_api.py
is the correct way.
Hi, I updated the docs. please see if it answers everything you encountered: https://zipline-trader.readthedocs.io/en/latest/alpaca-bundle-ingestion.html
thank you for your feedback.
To ingest I add os.environ['ZIPLINE_ROOT'] = '/home/rod/Desktop/alpaca'
to alpaca_api.py which seems to run fine and stores data at the specified directory.
python zipline/data/bundles/alpaca_api.py
zipline/data/bundles/alpaca_api.py:277: UserWarning: Overwriting bundle with name 'alpaca_api'
def api_to_bundle(interval=['1m']):
zipline/data/bundles/alpaca_api.py:352: UserWarning: Overwriting bundle with name 'alpaca_api'
end_session=end_date
Merging daily equity files: [####################################]
symbol start_date end_date \
0 AAPL 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
1 ABBV 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
2 ABT 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
3 ACN 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
4 ADBE 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
5 AIG 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
6 ALL 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
7 AMGN 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
8 AMT 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
9 AMZN 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
10 AXP 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
11 BA 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
12 BAC 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
13 BIIB 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
14 BK 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
15 BKNG 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
16 BLK 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
17 BMY 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
18 BRK.B 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
19 C 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
20 CAT 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
21 CHTR 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
22 CL 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
23 CMCSA 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
24 COF 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
25 COP 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
26 COST 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
27 CRM 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
28 CSCO 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
29 CVS 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
.. ... ... ...
71 NFLX 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
72 NKE 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
73 NVDA 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
74 ORCL 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
75 PEP 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
76 PFE 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
77 PG 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
78 PM 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
79 PYPL 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
80 QCOM 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
81 RTX 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
82 SBUX 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
83 SLB 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
84 SO 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
85 SPG 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
86 T 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
87 TGT 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
88 TMO 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
89 TSLA 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
90 TXN 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
91 UNH 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
92 UNP 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
93 UPS 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
94 USB 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
95 V 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
96 VZ 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
97 WBA 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
98 WFC 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
99 WMT 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
100 XOM 2020-12-01 00:00:00+00:00 2020-12-31 00:00:00+00:00
first_traded auto_close_date exchange asset_name
0 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
1 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
2 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
3 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
4 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
5 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
6 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
7 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
8 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
9 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
10 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
11 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
12 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
13 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
14 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
15 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
16 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
17 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
18 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
19 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
20 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
21 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
22 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
23 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
24 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
25 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
26 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
27 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
28 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
29 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
.. ... ... ... ...
71 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
72 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
73 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
74 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
75 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
76 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
77 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
78 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
79 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
80 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
81 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
82 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
83 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
84 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
85 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
86 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
87 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
88 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
89 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
90 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
91 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
92 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
93 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
94 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
95 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
96 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
97 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
98 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
99 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
100 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00 NYSE None
[101 rows x 7 columns]
--- 12.853231430053711 seconds ---
I then added os.environ['ZIPLINE_ROOT'] = '/home/rod/Desktop/alpaca'
to the test file at https://zipline-trader.readthedocs.io/en/latest/backtest.html but still get the same error:
python test.py
Traceback (most recent call last):
File "test.py", line 70, in <module>
data_frequency='daily'
File "/home/rod/Projects/zipline-trader/zipline/utils/run_algo.py", line 486, in run_algorithm
execution_id=execution_id
File "/home/rod/Projects/zipline-trader/zipline/utils/run_algo.py", line 268, in _run
'script': algotext,
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 669, in run
for perf in self.get_generator():
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 645, in get_generator
return self._create_generator(self.sim_params)
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 603, in _create_generator
self.initialize(**self.initialize_kwargs)
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 456, in initialize
self._initialize(self, *args, **kwargs)
File "test.py", line 25, in initialize
context.equity = symbol("AMZN")
File "/home/rod/Projects/zipline-trader/zipline/utils/api_support.py", line 56, in wrapped
return getattr(algo_instance, f.__name__)(*args, **kwargs)
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 1076, in symbol
)
File "/home/rod/Projects/zipline-trader/zipline/algorithm.py", line 1111, in symbol
country_code=country_code,
File "/home/rod/Projects/zipline-trader/zipline/assets/assets.py", line 1018, in lookup_symbol
as_of_date,
File "/home/rod/Projects/zipline-trader/zipline/assets/assets.py", line 857, in _lookup_symbol_strict
raise SymbolNotFound(symbol=symbol)
zipline.errors.SymbolNotFound: Symbol 'AMZN' was not found.
Hi,
import os
print(os.environ['ZIPLINE_ROOT'])
Yes, print(os.environ['ZIPLINE_ROOT'])
gives the correct directory. Tried AAPL and UPS and same error.
what dates are you running your scripts in? you ingested in this range: 2020-12-01 00:00:00+00:00 2021-01-01 00:00:00+00:00
Yes, that was the problem. Thanks! Please feel free to close this issue.
Attempting to install this on ubuntu 20.04 LTS with python 3.8.5 (default with ubuntu) following the instructions on the zipline-trader docs page and I get the following error:
... after a few more pages of debug info ...