ska-sa / spead2

Library for the Streaming Protocol for Exchange of Astronomical Data (SPEAD)
http://spead2.readthedocs.io/en/latest/
GNU Lesser General Public License v3.0
23 stars 14 forks source link

Start of developer guide #265

Closed bmerry closed 1 year ago

bmerry commented 1 year ago

Add basic instructions for new developers to get a development environment set up and ready to make contributions.

bmerry commented 1 year ago

Everything looks fine, but I ran into an issue when I was following the instructions myself. I did it on dbelab07 just to ensure a fresh environment.

Did you perhaps put the virtual environment inside the source tree?

james-smith-za commented 1 year ago

Did you perhaps put the virtual environment inside the source tree?

What do you mean source tree exactly? The src/ directory? I had a .venv directory in the root of the repo folder, the same as my convention on katgpucbf.

I tried deleting it and making a new one outside the repo folder entirely but ran into the same result.

bmerry commented 1 year ago

Did you perhaps put the virtual environment inside the source tree?

What do you mean source tree exactly? The src/ directory? I had a .venv directory in the root of the repo folder, the same as my convention on katgpucbf.

I mean the repo root. I can see how that would trigger the error about "Note that this error message can also be triggered by external dependencies being installed within your source tree - it's not recommended to do this." I'll update the document to indicate that this shouldn't be done.

I tried deleting it and making a new one outside the repo folder entirely but ran into the same result.

Was it be any chance adjacent to the repository root and named spead2\<something>? I've just done a test and it seems like there might be a bug with it using string startswith instead of a proper path check.

james-smith-za commented 1 year ago

I mean the repo root. I can see how that would trigger the error about "Note that this error message can also be triggered by external dependencies being installed within your source tree - it's not recommended to do this." I'll update the document to indicate that this shouldn't be done.

Noted!

Was it be any chance adjacent to the repository root and named spead2? I've just done a test and it seems like there might be a bug with it using string startswith instead of a proper path check.

It was named spead2-venv so it would probably have triggerd that startswith bug. I re-tried it quickly with a different name (myvenv) and that seems to have worked just fine! Good sleuthing!