Skip to content

Commit

Permalink
POSTHOG_DISABLED for dev
Browse files Browse the repository at this point in the history
  • Loading branch information
Matvey-Kuk committed Nov 20, 2024
1 parent c05007e commit 242cf40
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions docker/Dockerfile.dev.api
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ RUN . /venv/bin/activate && poetry install --no-root
ENV PYTHONPATH="/app:${PYTHONPATH}"
ENV PATH="/venv/bin:${PATH}"
ENV VIRTUAL_ENV="/venv"
ENV POSTHOG_DISABLED="true"

ENTRYPOINT ["/app/keep/entrypoint.sh"]

Expand Down
2 changes: 1 addition & 1 deletion keep/api/core/posthog.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
except metadata.PackageNotFoundError:
KEEP_VERSION = os.environ.get("KEEP_VERSION", "unknown")

POSTHOG_DISABLED = os.getenv("POSTHOG_DISABLED", "false") == "true"
POSTHOG_DISABLED = os.getenv("POSTHOG_DISABLED", "false").lower() == "true"

if POSTHOG_DISABLED:
posthog.disabled = True
Expand Down

0 comments on commit 242cf40

Please sign in to comment.