pola-rs / tpch

MIT License
64 stars 35 forks source link

`make tables` failed #98

Closed anmyachev closed 3 months ago

anmyachev commented 3 months ago
~/tpch$ make tables
make -C tpch-dbgen all
make[1]: Entering directory '/home/anatoly/tpch/tpch-dbgen'
make[1]: Nothing to be done for 'all'.
make[1]: Leaving directory '/home/anatoly/tpch/tpch-dbgen'
cd tpch-dbgen && ./dbgen -vf -s 10 && cd ..
TPC-H Population Generator (Version 2.17.2)
Copyright Transaction Processing Performance Council 1994 - 2010
Generating data for suppliers table/
Preloading text ... 100%
done.
Generating data for customers tabledone.
Generating data for orders/lineitem tablesdone.
Generating data for part/partsupplier tablesdone.
Generating data for nation tabledone.
Generating data for region tabledone.
mkdir -p "data/tables/scale-10"
mv tpch-dbgen/*.tbl data/tables/scale-10/
.venv/bin/python scripts/prepare_data.py 10
Traceback (most recent call last):
  File "/home/anatoly/tpch/scripts/prepare_data.py", line 4, in <module>
    import polars as pl
ModuleNotFoundError: No module named 'polars'
make: *** [Makefile:39: tables] Error 1

It looks like the virtual environment is not being activated correctly.

make version: GNU Make 4.3

Perhaps the problem is in the name of the prerequisite .venv.

stinodego commented 3 months ago

Looks like you set up your virtual environment incorrectly. If you just run make tables from a clean repo it should work.

anmyachev commented 3 months ago

Looks like you set up your virtual environment incorrectly. If you just run make tables from a clean repo it should work.

You are right, however I have a suggestion on how to make it more error-pruned: https://github.com/pola-rs/tpch/pull/99#issuecomment-2037179487. What do you think?