Skip to content

Small fixes #219

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 1, 2022
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
2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.github_slack_token }}
SLACK_WEBHOOK_URL: ${{ secrets.slack_webhook }}
if: always()
if: ${{ github.event.pull_request.head.repo.full_name != 'Unleash/unleash-client-python' }} && (success() || failure())

tox:
runs-on: ubuntu-latest
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## v5.3.0
* (Minor) Add retries to GET /features. Thanks @janboll!
* (Minor) Add global segments. Thanks @sighphyre!
* (Minor) Documentation updates and tweaks. Thanks @inirudebwoy, @sighphyre, @thomasheartman !

## v5.2.0
* (Minor) Add support for bootstrapping UnleashClient with an initial configuration.
* (Minor) Add flag to disable toggle polling from server. Thanks @povilasb!
Expand Down
4 changes: 2 additions & 2 deletions UnleashClient/cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import requests
from fcache.cache import FileCache as _FileCache
from UnleashClient.constants import FEATURES_URL
from UnleashClient.constants import FEATURES_URL, REQUEST_TIMEOUT


class BaseCache(abc.ABC):
Expand Down Expand Up @@ -104,7 +104,7 @@ def bootstrap_from_url(self, initial_config_url: str, headers: Optional[dict] =
:param initial_configuration_url: Url that returns document containing initial configuration. Must return JSON.
:param headers: Headers to use when GETing the initial configuration URL.
"""
response = requests.get(initial_config_url, headers=headers)
response = requests.get(initial_config_url, headers=headers, timeout=REQUEST_TIMEOUT)
self.set(FEATURES_URL, response.json())
self.bootstrapped = True

Expand Down