You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add a CONTRIBUTING.md with how to run the tests #324
This would be very useful, I am just jotting down things quickly so some things may not be completely accurate. If someone wants to do it, that would be more than welcome!
I think for now adding a CONTRIBUTING.md and possibly add a link from the README.md is good enough. An alternative is to put it somewhere in the doc but this is a bit more effort.
tests who don't need a cluster
pytest dask_jobqueue
tests who need a cluster
They have @pytest.mark.env("scheduler-name") before the test function. With a cluster (cluster-name needs to match the name in the pytest.mark.env):
pytest dask_jobqueue -E <cluster-name>
e.g. on my SGE cluster I do:
pytest dask_jobqueue -E sge
running tests locally with our docker-compose setup
For some clusters (SGE, PBS, SLURM) at the time of writing, we have a docker-compose setup to run the tests locally.
cd ci/sge
./start-sge.sh
Sometimes there is a problem (never figured out when exactly) and you want to regenerate the docker images from scratch (there may be a better way to do this to be honest, because my feeling is that you want only to rerun the part of the conda install in the docker image not the full thing):
cd ci/sge
docker-compose build --no-cache
./start-sge.sh
@basnijholt, since you opened a few PRs recently, and if you are interested on working on this and you happen to have some free time of course, this would be more than welcome!
Indeed, I didn't know about the dev docs (or I forgot), this is nice.
I guess the main thing that needs to be added is:
can you run the tests on a cluster with pytest? This is useful for job schedulers
where we don't have any docker-compose setup but I am not sure it actually works. You may need to raise QUEUE_WAIT and maybe you need additional tweaks (for example to activate the right conda environments or define the right queue). In any case it would be nice if we had a way to run tests on real clusters and this was in the developer doc.
not crucial but I am a bit unsure about the jobqueue_before_install, jobqueue_install, etc ..., I'd rather have the ./start-sge.sh cluster and the docker command as in the dask-drmaa doc above. I agree then the CI and the local test can diverge but at least you understand a bit better what you are doing ...
This would definitely be helpful. I'm especially interested in the information here given that the HTCondor testing is currently... limited and would be interested in helping to improve that.
@mivade help on improving HTCondor testing would be more than welcome!
There are two things as far as I can tell:
add tests that don't need a cluster, this is only testing cluster.job_script(). I think there are already some tests like this in dask_jobqueue/tests/test_htcondor.py
Activity
lesteve commentedon Aug 23, 2019
@basnijholt, since you opened a few PRs recently, and if you are interested on working on this and you happen to have some free time of course, this would be more than welcome!
guillaumeeb commentedon Aug 23, 2019
@lesteve shouldn't this be put in https://jobqueue.dask.org/en/latest/develop.html ?
lesteve commentedon Aug 23, 2019
Indeed, I didn't know about the dev docs (or I forgot), this is nice.
I guess the main thing that needs to be added is:
where we don't have any docker-compose setup but I am not sure it actually works. You may need to raise
QUEUE_WAITand maybe you need additional tweaks (for example to activate the right conda environments or define the right queue). In any case it would be nice if we had a way to run tests on real clusters and this was in the developer doc.dask-drmaaactually: https://github.com/dask/dask-drmaa#testing)jobqueue_before_install,jobqueue_install, etc ..., I'd rather have the./start-sge.shcluster and thedockercommand as in thedask-drmaadoc above. I agree then the CI and the local test can diverge but at least you understand a bit better what you are doing ...mivade commentedon Aug 23, 2019
This would definitely be helpful. I'm especially interested in the information here given that the HTCondor testing is currently... limited and would be interested in helping to improve that.
lesteve commentedon Aug 26, 2019
@mivade help on improving HTCondor testing would be more than welcome!
There are two things as far as I can tell:
cluster.job_script(). I think there are already some tests like this indask_jobqueue/tests/test_htcondor.pydocker-composeset-up as we have for SLURM, PBS and SGE. This requires a bit more effort but CI for HTCondor using Docker #247 (comment) may help.mivade commentedon Aug 26, 2019
@lesteve, thanks for the pointers! I'll see if I can find some time in the coming days to work on this.