Skip to content
Merged
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 .github/linters/.python-lint
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ ignored-classes=optparse.Values,thread._local,_thread._local
# supports qualified module names, as well as Unix pattern matching.
ignored-modules=flask,
flask_talisman,
google.api_core.exceptions,
google.auth.exceptions,
google.cloud,
jinja2,
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ jobs:
uses: super-linter/super-linter/slim@v8
env:
DEFAULT_BRANCH: main
ENABLE_GITHUB_PULL_REQUEST_SUMMARY_COMMENT: false
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
FILTER_REGEX_EXCLUDE: .*\.min\..*
VALIDATE_BASH: true
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ jobs:
- name: Lint Generated HTML
uses: super-linter/super-linter/slim@v8
env:
ENABLE_GITHUB_PULL_REQUEST_SUMMARY_COMMENT: false
FILTER_REGEX_INCLUDE: static/html/.*
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VALIDATE_HTML: true
Expand Down
10 changes: 9 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions server/dates.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
import logging

from google.cloud import storage
from google.auth.exceptions import DefaultCredentialsError
from google.auth.exceptions import DefaultCredentialsError, RefreshError
from google.api_core.exceptions import Forbidden

# Create/configure stream handler
sh = logging.StreamHandler()
Expand All @@ -21,7 +22,8 @@
LOAD_DATES_FROM_GCS = True
try:
gcs = storage.Client()
except DefaultCredentialsError: # pragma: no cover
gcs.get_bucket(GCS_BUCKET) # pragma: no cover
except (DefaultCredentialsError, RefreshError, Forbidden): # pragma: no cover
logger.warning("Unable to authenticate to Google Cloud Storage.")
LOAD_DATES_FROM_GCS = False

Expand Down
Loading