Closed vinostroud closed 6 months ago
@vinostroud see commit above (https://github.com/vinostroud/nfl_analytics/pull/22/commits/3f8a679baf41bf3a10c7de6189c7f545a55294c2) - you need a relative import here
OK. This is now working and I should have plenty to do between now and the next time we speak.
Was the relative import the problem with pytest? Or was the issue pytest was in included in poetry.lock file (which is strange because I used poetry add
for pytest).
Anyway - I will merge working branch into main. Then create new branch to work on tests for the analytics
file.
Thank you very much, this was super helpful.
Yes the issue was the import, to import from one module into another, in the same package, it's best to use relative import (see fix). Also apps.analytics_py
- I don't see any package or module in this project that is named apps
? So what were you referring to there?
Yes the issue was the import, to import from one module into another, in the same package, it's best to use relative import (see fix). Also
apps.analytics_py
- I don't see any package or module in this project that is namedapps
? So what were you referring to there?
Ah, sorry - I tried different folder names (going back and forth between 'apps' folder and 'src' folder to see if I could get the folder recognized. That is an artifact that I will fix.
So you can this when doing a
poetry run pytest
?