Skip to content

Commit

Permalink
Merge 20a11eb into 42d74b2
Browse files Browse the repository at this point in the history
  • Loading branch information
aliabbasrizvi committed Sep 19, 2018
2 parents 42d74b2 + 20a11eb commit 765d718
Show file tree
Hide file tree
Showing 7 changed files with 333 additions and 270 deletions.
129 changes: 0 additions & 129 deletions CHANGELOG.md

This file was deleted.

119 changes: 119 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
2.1.1
-----

August 21st, 2018

- Fix: record conversions for all experiments using an event when using
track(\ `#136`_).

.. _section-1:

2.1.0
-----

July 2nd, 2018

- Introduced support for bot filtering (`#121`_).
- Overhauled logging to use standard Python logging (`#123`_).

.. _section-2:

2.0.1
-----

June 19th, 2018

- Fix: send impression event for Feature Test when Feature is disabled
(`#128`_).

.. _section-3:

2.0.0
-----

April 12th, 2018

This major release introduces APIs for Feature Management. It also
introduces some breaking changes listed below.

New Features
~~~~~~~~~~~~

- Introduced the ``is_feature_enabled`` API to determine whether to
show a feature to a user or not.

::

is_enabled = optimizel_client.is_feature_enabled('my_feature_key', 'my_user', user_attributes)

- All enabled features for the user can be retrieved by calling:

::

enabled_features = optimizely_client.get_enabled_features('my_user', user_attributes)

- Introduced Feature Variables to configure or parameterize a feature.
There are four variable types: ``String``, ``Integer``, ``Double``,
``Boolean``.

::

string_variable = optimizely_client.get_feature_variable_string('my_feature_key', 'string_variable_key', 'my_user')
integer_variable = optimizely_client.get_feature_variable_integer('my_feature_key', 'integer_variable_key', 'my_user')
double_variable = optimizely_client.get_feature_variable_double('my_feature_key', 'double_variable_key', 'my_user')
boolean_variable = optimizely_client.get_feature_variable_boolean('my_feature_key', 'boolean_variable_key', 'my_user')

Breaking changes
~~~~~~~~~~~~~~~~

- The ``track`` API with revenue value as a stand-alone parameter has
been removed. The revenue value should be passed in as an entry in
the event tags dict. The key for the revenue tag is ``revenue`` and
the passed in value will be treated by Optimizely as the value for
computing results.

::

event_tags = {
'revenue': 1200
}

optimizely_client.track('event_key', 'my_user', user_attributes, event_tags)

2.0.0b1
-------

March 29th, 2018

This beta release introduces APIs for Feature Management. It also
introduces some breaking changes listed below.

.. _new-features-1:

New Features
~~~~~~~~~~~~

- Introduced the ``is_feature_enabled`` API to determine whether to
show a feature to a user or not.

::

is_enabled = optimizel_client.is_feature_enabled('my_feature_key', 'my_user', user_attributes)

- All enabled features for the user can be retrieved by calling:

::

enabled_features = optimizely_client.get_enabled_features('my_user', user_attributes)

- Introduced Feature Variables to configure or parameterize a feature.
There are four variable types: ``String``, ``Integer``, ``Double``,
``Boolean``. \``\` string_variable =
optimizely_client.get_feature_variable_string(‘my_feature_key’,
‘string_variable_key’, ‘my_user’) integer_variable =
optimizely_client.get_feature_variable_integer(’my_fea

.. _#136: https://github.com/optimizely/python-sdk/pull/136
.. _#121: https://github.com/optimizely/python-sdk/pull/121
.. _#123: https://github.com/optimizely/python-sdk/pull/123
.. _#128: https://github.com/optimizely/python-sdk/pull/128
50 changes: 0 additions & 50 deletions CONTRIBUTING.md

This file was deleted.

80 changes: 80 additions & 0 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
Contributing to the Optimizely Python SDK
=========================================

We welcome contributions and feedback! All contributors must sign our
`Contributor License Agreement (CLA)`_ to be eligible to contribute.
Please read the `README`_ to set up your development environment, then
read the guidelines below for information on submitting your code.

Development process
-------------------

1. Create a branch off of ``master``:
``git checkout -b YOUR_NAME/branch_name``.
2. Commit your changes. Make sure to add tests!
3. Lint your changes before submitting: ``pep8 YOUR_CHANGED_FILES.py``.
4. ``git push`` your changes to GitHub.
5. Make sure that all unit tests are passing and that there are no merge
conflicts between your branch and ``master``.
6. Open a pull request from ``YOUR_NAME/branch_name`` to ``master``.
7. A repository maintainer will review your pull request and, if all
goes well, squash and merge it!

Pull request acceptance criteria
--------------------------------

- **All code must have test coverage.** We use unittest. Changes in
functionality should have accompanying unit tests. Bug fixes should
have accompanying regression tests.

- Tests are located in ``/tests`` with one file per class.

- Please don’t change the ``__version__``. We’ll take care of bumping
the version when we next release.
- Lint your code with PEP-8 before submitting.

Style
-----

We enforce PEP-8 rules with a few minor `deviations`_.

License
-------

All contributions are under the CLA mentioned above. For this project,
Optimizely uses the Apache 2.0 license, and so asks that by contributing
your code, you agree to license your contribution under the terms of the
`Apache License v2.0`_. Your contributions should also include the
following header:

::

# Copyright YEAR, Optimizely, Inc. and contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

The YEAR above should be the year of the contribution. If work on the
file has been done over multiple years, list each year in the section
above. Example: Optimizely writes the file and releases it in 2014. No
changes are made in 2015. Change made in 2016. YEAR should be “2014,
2016”.

Contact
-------

If you have questions, please contact developers@optimizely.com.

.. _Contributor License Agreement (CLA): https://docs.google.com/a/optimizely.com/forms/d/e/1FAIpQLSf9cbouWptIpMgukAKZZOIAhafvjFCV8hS00XJLWQnWDFtwtA/viewform
.. _README: README.md
.. _deviations: https://github.com/optimizely/python-sdk/blob/master/tox.ini
.. _Apache License v2.0: http://www.apache.org/licenses/LICENSE-2.0
Loading

0 comments on commit 765d718

Please sign in to comment.