changement vers google drive storage pour les contrats.
CI - Security, Lint & Tests / validate (push) Failing after 1m15s

Tentative d'obtenir un token de connection échoue
This commit is contained in:
cedrick2711
2026-08-26 20:52:40 -04:00
parent 38defc53a5
commit 820cccb25e
20 changed files with 476 additions and 2746 deletions
+7 -1
View File
@@ -34,8 +34,14 @@ import os
from app.google_drive import (
GoogleDriveStorageError,
)
from app.google_drive import (
delete_file as delete_google_drive_file,
)
from app.google_drive import (
download_file as download_google_drive_file,
)
from app.google_drive import (
upload_file as upload_google_drive_file,
)
@@ -112,7 +118,7 @@ def _rooted(env_name, default_name):
def document_storage_backend():
"""Return the configured backend for new document uploads."""
backend = os.getenv(DOCUMENT_STORAGE_BACKEND_ENV, 'google_drive').strip().lower()
backend = os.getenv(DOCUMENT_STORAGE_BACKEND_ENV, 'local').strip().lower()
if backend not in {'google_drive', 'local'}:
raise ValueError(
f'{DOCUMENT_STORAGE_BACKEND_ENV} must be "google_drive" or "local", not {backend!r}'