Skip to content

Commit

Permalink
Draft #170
Browse files Browse the repository at this point in the history
  • Loading branch information
heming-langrenn committed Jan 1, 2024
1 parent e2bf7e1 commit f0f44f8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ Du må sette opp ei .env fil med miljøvariable. Eksempel:
JWT_SECRET=secret
ADMIN_USERNAME=admin
ADMIN_PASSWORD=password
GOOGLE_APPLICATION_CREDENTIALS=/home/heming/github/secrets/application_default_credentials.json
COMPETITION_FORMAT_HOST_PORT=8094
COMPETITION_FORMAT_HOST_SERVER=localhost
DB_USER=admin
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ services:
environment:
- ADMIN_USERNAME=${ADMIN_USERNAME}
- ADMIN_PASSWORD=${ADMIN_PASSWORD}
- GOOGLE_APPLICATION_CREDENTIALS=${GOOGLE_APPLICATION_CREDENTIALS}
- HOST_PORT=8080
- EVENT_GUI_HOST_SERVER=event-service-gui
- EVENT_GUI_HOST_PORT=8080
Expand Down
4 changes: 4 additions & 0 deletions result_service_gui/services/google_pub_sub_adapter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""Module for google pub/sub adapter."""
import json
import logging
import os

from google.api_core import retry
from google.cloud import pubsub_v1 # type: ignore[attr-defined]
Expand Down Expand Up @@ -66,6 +67,9 @@ async def pull_messages(self) -> list:
)
except Exception as err:
logging.error(f"{servicename}. Error: {err}")
# write current path to error log
logging.error(f"Current directory: {os.getcwd()}")

raise err

return message_body

0 comments on commit f0f44f8

Please sign in to comment.