I have an existing Python 3.7 project. When adding a new variable to the .env, it is not loading.
Here is an example of my .env file.
# Existing
DB_HOST=localhost
DB_PORT=3307
# New variable
API_BASE_URL=https://testing.mysite.com.au/api/v1/
# Load api settings
api_base_url = os.getenv('API_BASE_URL')
The database variables are working fine however, api_base_url returns None.
I don't believe it is a path/load_dotenv issue, as the existing variables are loading correctly.
Do I need to refresh/reload the .env file?