Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
REDCAP_OPEN_API_KEY=
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ venv/
ENV/
env.bak/
venv.bak/
!.env.example

# Python specific content
venv
Expand Down
4 changes: 3 additions & 1 deletion src/questionnaire_data/common/dotenv.py

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With #107 do we still need this? It skips fine if .env is missing without loading the example env.

Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ def load_env_vars() -> None:

First, env vars are loaded from the shared project folder on GenomeDK.
Then, they are overwritten by values from the local .env file (if this exists).
Otherwise it will use the default, though empty, `.env.example`.
"""
load_dotenv("/faststorage/project/sdca-dpnext-study/env/.quest-env")
load_dotenv(".env.example")
load_dotenv("/faststorage/project/sdca-dpnext-study/env/.quest-env", override=True)
load_dotenv(".env", override=True)
Loading