Skip to content

Commit

Permalink
fix: use proper UTC timezone
Browse files Browse the repository at this point in the history
  • Loading branch information
joaodaher committed Mar 13, 2024
1 parent 135ce14 commit e065635
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions gcp_pilot/scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

from gcp_pilot.base import AppEngineBasedService, GoogleCloudPilotAPI

DEFAULT_TIMEZONE = os.environ.get("TIMEZONE", None) # UTC
DEFAULT_TIMEZONE = os.environ.get("TIMEZONE", "Etc/UTC") # UTC
MAX_TIMEOUT = 30 * 60 # max allowed to HTTP endpoints is 30 minutes


Expand All @@ -32,7 +32,7 @@ def create(
url: str,
payload: str,
cron: str,
timezone: str | None = None,
timezone: str = DEFAULT_TIMEZONE,
method: int = DEFAULT_METHOD,
headers: dict[str, str] | None = None,
project_id: str | None = None,
Expand Down Expand Up @@ -64,7 +64,7 @@ def update(
url: str,
payload: str,
cron: str,
timezone: str | None = None,
timezone: str | None = DEFAULT_TIMEZONE,
method: int = DEFAULT_METHOD,
headers: dict[str, str] | None = None,
project_id: str | None = None,
Expand Down Expand Up @@ -115,7 +115,7 @@ def put(
url: str,
payload: str,
cron: str,
timezone: str | None = None,
timezone: str = DEFAULT_TIMEZONE,
method: int = DEFAULT_METHOD,
headers: dict[str, str] | None = None,
project_id: str | None = None,
Expand Down

0 comments on commit e065635

Please sign in to comment.