Closed ksuchak1990 closed 1 year ago
hmm oh never had that ever. but okay, i think with the relative paths now that should not be an issue, should it?
Exactly!
I would generally default to having my scripts in a directory called src/
, but you could also give it a different a name (I think technically this is supposed to be good practice - https://docs.python-guide.org/writing/structure/).
Exactly!
I would generally default to having my scripts in a directory called
src/
, but you could also give it a different a name (I think technically this is supposed to be good practice - https://docs.python-guide.org/writing/structure/).
okay. I did not know that either :)
+1 for giving the directory a package-like name. This may be one of the reason I was having problems with importing libraries things in the tests (https://github.com/eeyouol/Covid_policy_response_abm/pull/14)
How about covid
or covpol
?
+1 for giving the directory a package-like name. This may be one of the reason I was having problems with importing libraries things in the tests (#14)
How about
covid
orcovpol
?
do you refer the whole repository or just the folder with the code? I think src for scripts makes sense? But happy to name the whole repository covpol?
+1 for giving the directory a package-like name. This may be one of the reason I was having problems with importing libraries things in the tests (https://github.com/eeyouol/Covid_policy_response_abm/pull/14)
How about
covid
orcovpol
?
My vote would be for covpol
of those two.
+1 for giving the directory a package-like name. This may be one of the reason I was having problems with importing libraries things in the tests (#14) How about
covid
orcovpol
?do you refer the whole repository or just the folder with the code? I think src for scripts makes sense? But happy to name the whole repository covpol?
Just the folder with the code. Then the code becomes a 'package'. The advantage to this is that you can import it from elsewhere (like in the tests) with:
from covpol.agent_classs import CountryAgent
rather than
from src.agent_classs import CountryAgent
done
When I try to run the jupyter notebook with the update environment, I'm getting some errors that mean that the notebook cannot connect to the kernel. This looks like it arises from the python scripts being in a directory called
code
which apparently causes some conflicts somewhere. I've tried changing the directory name on my machine and the notebook can now connect to the kernel.Can we change the name of this directory to something like
src
?