populus
populus copied to clipboard
Test run seriously slowing down when renaming contracts folder
- Populus Version: 1.11.0
- OS: linux/ubuntu
- Python 3.5.2 (default, Sep 14 2017, 22:51:06)
What was wrong?
consider folder structure:
contracts/
tests/
project.json
README.md
tests
folder has 52 items to run, running them all with command py.test -s --disable-pytest-warnings --populus-project=./ ./
takes ~85 seconds, maxing out load on one CPU core on my old laptop.
Now consider this folder structure:
ws_contracts/
tests/
project.json
README.md
Same files inside, project.json
amended to reference the right folder.
Running same tests with the same command takes 4-5 times longer, also maxing out load on one CPU core on my old laptop. No apparent reason why.
Expected: renaming the contracts folder should not affect the test running time.
Cute Animal Picture
I've tried this with the populus init
-made Greeter
project, and noticed that the ws_contracts
test run, executed as plain py.test
, produces several times more deprecation warnings. The "extra" ones seem to be mostly:
/home/veox/src/populus-greeter/.virtualenv/populus-greeter/lib/python3.6/site-packages/eth_utils/functional.py:21: DeprecationWarning: The `compose` function has been deprecated and will be removed in a subsequent release of `ethereum-utils`. It is recommended that you switch to use a library like `cytoolz` which provides similar functionality through the `cytoolz.functoolz.compose` function.
"The `compose` function has been deprecated and will be removed in a "
(The trunctation of the second line appears in both contracts
and ws_contracts
run; and for other warnings, too.)
Consider comparing the generated warnings (that you currently discard). These may point to the root of the issue.
EDIT: Actually, the fact they're more numerous may itself highlight the cause.
EDIT: Posted wrong DeprecationWarning
at first.
BTW, which Python version are you running?
Python 3.5.2 (default, Sep 14 2017, 22:51:06). Added to the issue description.
Yes, I discard general warnings because they point to all issues in all dependencies that is not really helpful, and as you see there is a lot of them. I'll check that though.