Heroku throws ModuleNotFoundError for app that is installed

I am trying to deploy my first Django app to Heroku, but the environment variables are driving me nuts. I tried both environs and django-environ and in both cases I get errors that look like the following.

File “/app/.heroku/python/lib/python3.11/site-packages/django/db/utils.py”, line 153, in databases
2023-09-30T16:06:33.120714+00:00 app[release.5173]: self._databases = settings.DATABASES
2023-09-30T16:06:33.120734+00:00 app[release.5173]: ^^^^^^^^^^^^^^^^^^
2023-09-30T16:06:33.120734+00:00 app[release.5173]: File “/app/.heroku/python/lib/python3.11/site-packages/django/conf/init.py”, line 82, in getattr
2023-09-30T16:06:33.120789+00:00 app[release.5173]: self._setup(name)
2023-09-30T16:06:33.120789+00:00 app[release.5173]: File “/app/.heroku/python/lib/python3.11/site-packages/django/conf/init.py”, line 69, in _setup
2023-09-30T16:06:33.120834+00:00 app[release.5173]: self._wrapped = Settings(settings_module)
2023-09-30T16:06:33.120883+00:00 app[release.5173]: ^^^^^^^^^^^^^^^^^^^^^^^^^
2023-09-30T16:06:33.120911+00:00 app[release.5173]: File “/app/.heroku/python/lib/python3.11/site-packages/django/conf/init.py”, line 170, in init
2023-09-30T16:06:33.120956+00:00 app[release.5173]: mod = importlib.import_module(self.SETTINGS_MODULE)
2023-09-30T16:06:33.121051+00:00 app[release.5173]: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2023-09-30T16:06:33.121064+00:00 app[release.5173]: File “/app/.heroku/python/lib/python3.11/importlib/init.py”, line 126, in import_module
2023-09-30T16:06:33.121115+00:00 app[release.5173]: return _bootstrap._gcd_import(name[level:], package, level)
2023-09-30T16:06:33.121230+00:00 app[release.5173]: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2023-09-30T16:06:33.121230+00:00 app[release.5173]: File “”, line 1206, in _gcd_import
2023-09-30T16:06:33.121245+00:00 app[release.5173]: File “”, line 1178, in _find_and_load
2023-09-30T16:06:33.121245+00:00 app[release.5173]: File “”, line 1149, in _find_and_load_unlocked
2023-09-30T16:06:33.121276+00:00 app[release.5173]: File “”, line 690, in _load_unlocked
2023-09-30T16:06:33.121277+00:00 app[release.5173]: File “”, line 940, in exec_module
2023-09-30T16:06:33.121277+00:00 app[release.5173]: File “”, line 241, in _call_with_frames_removed
2023-09-30T16:06:33.121277+00:00 app[release.5173]: File “/app/ladder/settings/dev_settings.py”, line 16, in
2023-09-30T16:06:33.121335+00:00 app[release.5173]: import environ
2023-09-30T16:06:33.121357+00:00 app[release.5173]: ModuleNotFoundError: No module named ‘environ’
2023-09-30T16:06:33.282201+00:00 heroku[release.5173]: Process exited with status 1
2023-09-30T16:06:33.309024+00:00 heroku[release.5173]: State changed from up to complete
2023-09-30T16:06:34.000000+00:00 app[api]: Build succeeded
2023-09-30T16:06:35.288910+00:00 app[api]: Release v22 command failed by user

Here’s the problem. I installed the app in my environment, as well as in INSTALLED APPS. It is also in my requirements.txt. The settings are set as suggested on the django-environ website. (For environs, I followed Django for Professionals / Real Pythons website / and another set of websites, all to no avail. In the case of environs, I get the exact same error except “environs” instead of “environ” (django-environ).

If anyone has encountered this error, please let me know.

Alternatively, if anyone can suggest a fail-safe way to get things up on Heroku, I’m all ears. Having worked on this for close on 3 days I am very close to giving up on Heroku … and would be open to alternative platforms that are easier to deploy to.

Please note I’m trying to do this without Docker since allegedly all you need is venv.

Thanks in advance.