Skip to content

Commit

Permalink
(BSR)[API] script: sync titelive book with higher statement_timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
cepehang committed Oct 21, 2024
1 parent c83320c commit 11b3f86
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions api/src/pcapi/scripts/titelive_book_sync/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import datetime

import sqlalchemy as sa

from pcapi.core.providers.titelive_book_search import TiteliveBookSearch
from pcapi.models import db


if __name__ == "__main__":
from pcapi.flask_app import app

app.app_context().push()

db.session.execute(sa.text("set session statement_timeout = '400s'"))
TiteliveBookSearch().synchronize_products(datetime.date(2024, 9, 18), 620)

0 comments on commit 11b3f86

Please sign in to comment.