Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
1b23d0f
full refactor
mredolatti Apr 12, 2019
5b8b7ab
add configurations to split model
mredolatti Apr 12, 2019
94a941b
return configurations from evaluator
mredolatti Apr 12, 2019
66f5d29
update clients & input validator to work with new methods *_with_config
mredolatti Apr 12, 2019
2fea2db
more tests & redis
mredolatti Apr 15, 2019
7dd4d03
reorder tasks
mredolatti Apr 15, 2019
a37bdee
add localhost support for dynamic configs
mredolatti Apr 16, 2019
48ab64c
improve logging
mredolatti Apr 16, 2019
385ee2a
docstring cleanup
mredolatti Apr 16, 2019
ebabec2
fix input validation log interpolation
mredolatti Apr 17, 2019
f2ed31a
input validation for factory instantiation
mredolatti Apr 17, 2019
d0e58cb
factory ready methods
mredolatti Apr 17, 2019
5eba7d0
Merge branch 'full_refactor' of github.com:splitio/python-client into…
mredolatti Apr 17, 2019
27d9cc2
Merge branch 'feature/dynamic-configs-splitchanges' of github.com:spl…
mredolatti Apr 17, 2019
9eaaa02
merge with latest changes in refactor
mredolatti Apr 17, 2019
db630c2
Merge pull request #130 from splitio/feature/dynamic-configs-splitcha…
mredolatti Apr 17, 2019
ca9ddc2
Merge pull request #131 from splitio/feature/dynamic-configs-evaluator
mredolatti Apr 17, 2019
137072e
Merge pull request #132 from splitio/feature/dynamic-configs-client
mredolatti Apr 17, 2019
1b17f6b
Merge branch 'full_refactor' of github.com:splitio/python-client into…
mredolatti Apr 17, 2019
a959773
fix yaml/legacy selection and test it
mredolatti Apr 17, 2019
1daeb1d
add e2e tests for localhost yaml file
mredolatti Apr 17, 2019
a57e7ec
add `configs` in testview
mredolatti Apr 17, 2019
3f2c0e3
Merge pull request #133 from splitio/feature/dynamic-config-localhost
mredolatti Apr 17, 2019
70044ac
Merge branch 'full_refactor' of github.com:splitio/python-client into…
mredolatti Apr 17, 2019
2fc3c7a
Merge pull request #134 from splitio/feature/dynamic-configs-splitview
mredolatti Apr 17, 2019
e1fc0a2
more e2e tests
mredolatti Apr 22, 2019
56e6bca
remove unnecessary print
mredolatti Apr 22, 2019
0a45113
update e2e tests
mredolatti Apr 22, 2019
527b0f3
fix tests in py3
mredolatti Apr 23, 2019
cd33c26
forward config to metadata builder
mredolatti Apr 23, 2019
e7b7b81
Merge pull request #135 from splitio/feature/dynamic-configs-splitview
mredolatti Apr 23, 2019
72bd9b1
fix impression listener. move to utils.raise_from
mredolatti Apr 23, 2019
0f1033d
reorganize exceptions
mredolatti Apr 23, 2019
3a8d4ac
conver mget result to list of strings
mredolatti Apr 23, 2019
add69ec
fix track issue in redis, fix tests
mredolatti Apr 23, 2019
81ee307
look for sentinels as well when guessing operation mode
mredolatti Apr 23, 2019
7b06c62
use a pool in uwsgi mode as well to increase segment fetching throughput
mredolatti Apr 23, 2019
605908b
more uwsgi optimizations
mredolatti Apr 23, 2019
4723b9f
start the pool
mredolatti Apr 23, 2019
04b1995
fix segment fetching in uwsgi mode
mredolatti Apr 23, 2019
9d3157c
do not fail when removing nonexistant split in uwsgi. Keep tasks goin…
mredolatti Apr 23, 2019
8b08be6
Merge pull request #129 from splitio/full_refactor
mredolatti Apr 24, 2019
9895591
Merge branch 'master' of github.com:splitio/python-client into develo…
mredolatti Apr 24, 2019
18ec7ce
update travis config
mredolatti Apr 24, 2019
eeec9ae
fix travis.yml
mredolatti Apr 24, 2019
ddbb852
remove old legacy test
mredolatti Apr 24, 2019
d6c87a0
tests in verbose mode
mredolatti Apr 24, 2019
7a7596e
add a method to build metadata headers
mredolatti Apr 24, 2019
88e2e00
Added python 3.6
Israphel Apr 24, 2019
3f59ce1
bump version & update changes.txt
mredolatti Apr 24, 2019
e91e795
Merge branch 'development' of github.com:splitio/python-client into d…
mredolatti Apr 24, 2019
cd2f4b2
wait for factory to be ready in localhost tests
mredolatti Apr 24, 2019
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
3 changes: 2 additions & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
* Bullet 2

## How to test new changes?
*
* python setup.py test to test everythin
* pytest <SPECIFIC_FILE> to test a file in particular (requires pytest, pytest-cov & pytest-mock to be installed)

## Extra Notes
* Bullet 1
Expand Down
9 changes: 4 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@ language: python

python:
- "2.7"
- "3.6"

services:
- redis-server

install:
- pip install --upgrade setuptools
- pip install redis>=2.6
- pip install jsonpickle>=0.9.3
- pip install uwsgi>=2.0.0
- pip install -U setuptools pip
- pip install -e .[cpphash,redis,uwsgi]

script:
- python setup.py nosetests
- python setup.py test
8 changes: 8 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
8.0.0 (Apr 24, 2019)
- Full SDK Refactor/rewrite.
- New block until ready behaviour.
- Support for async destroy.
- Dynamic configs.
- Impressions not flushing on destroy bugfix.
- Removed unnecessary dependencies.
- Test suite rewritten.
7.0.1 (Mar 8, 2019)
- Updated Splits refreshing rate.
- Replaced exception log level to error level.
Expand Down
15 changes: 8 additions & 7 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,18 @@ description-file = README.md
max-line-length=100
exclude=tests/*

[nosetests]
verbosity=1
detailed-errors=1
with-coverage=1
cover-package=splitio
debug=nose.loader
[aliases]
test=pytest

[tool:pytest]
ignore_glob=./splitio/_OLD/*
addopts = --cov=splitio --verbose
python_classes=*Tests

[build_sphinx]
source-dir = doc/source
build-dir = doc/build
all_files = 1

[upload_sphinx]
upload-dir = doc/build/html
upload-dir = doc/build/html
15 changes: 8 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
"""Setup module."""
#!/usr/bin/env python

from setuptools import setup
from setuptools import setup, find_packages
from os import path
from sys import version_info

tests_require = ['flake8', 'nose', 'coverage']
tests_require = ['flake8', 'pytest', 'pytest-mock', 'coverage', 'pytest-cov']
install_requires = [
'arrow>=0.7.0',
'requests>=2.9.1',
'pyyaml>=5.1',
'future>=0.15.2',
'docopt>=0.6.2',
]
Expand All @@ -33,11 +34,11 @@
tests_require=tests_require,
extras_require={
'test': tests_require,
'redis': ['redis>=2.10.5', 'jsonpickle>=0.9.3'],
'uwsgi': ['uwsgi>=2.0.0', 'jsonpickle>=0.9.3'],
'redis': ['redis>=2.10.5'],
'uwsgi': ['uwsgi>=2.0.0'],
'cpphash': ['mmh3cffi>=0.1.4']
},
setup_requires=['nose'],
setup_requires=['pytest-runner'],
classifiers=[
'Development Status :: 3 - Alpha',
'Environment :: Console',
Expand All @@ -47,4 +48,4 @@
'Programming Language :: Python :: 3',
'Topic :: Software Development :: Libraries'
],
packages=['splitio', 'splitio.update_scripts', 'splitio.bin', 'splitio.hashfns'])
packages=find_packages())
31 changes: 3 additions & 28 deletions splitio/__init__.py
Original file line number Diff line number Diff line change
@@ -1,31 +1,6 @@
from __future__ import absolute_import, division, print_function, \
unicode_literals

from .factories import get_factory # noqa
from .key import Key # noqa
from .version import __version__ # noqa

__all__ = ('api', 'brokers', 'cache', 'clients', 'matchers', 'segments',
'settings', 'splits', 'splitters', 'transformers', 'treatments',
'version', 'factories', 'manager')


# Functions defined to maintain compatibility with previous sdk versions.
# ======================================================================
#
# This functions are not supposed to be used directly, factory method should be
# called instead, but since they were previously exposed, they're re-added here
# as helper function so that if someone was using we don't break their code.

def get_client(apikey, **kwargs):
from .clients import Client
from .brokers import get_self_refreshing_broker
broker = get_self_refreshing_broker(apikey, **kwargs)
return Client(broker)


def get_redis_client(apikey, **kwargs):
from .clients import Client
from .brokers import get_redis_broker
broker = get_redis_broker(apikey, **kwargs)
return Client(broker)
from splitio.client.factory import get_factory
from splitio.client.key import Key
from splitio.version import __version__
Loading