Skip to content

Commit

Permalink
Enable stale_if_error, stale_while_revalidate
Browse files Browse the repository at this point in the history
  • Loading branch information
glensc committed Nov 8, 2024
1 parent b7d34c8 commit d103ba7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions plextraktsync/factory/Factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,10 @@ def session(self):
cache_name=self.config.cache_path,
cache_control=True,
urls_expire_after=self.urls_expire_after,
# https://requests-cache.readthedocs.io/en/stable/user_guide/expiration.html#expiration-and-error-handling
stale_if_error=True,
# https://requests-cache.readthedocs.io/en/stable/user_guide/expiration.html#asynchronous-revalidation
stale_while_revalidate=True,
# Plex doesn't Send Vary: X-Plex-Container-Start
match_headers=["X-Plex-Container-Start"],
)
Expand Down

0 comments on commit d103ba7

Please sign in to comment.