No project description provided
Project description
rust_decider
Rust implementation of bucketing, targeting, overrides, and dynamic config logic.
Usage
source .env/bin/activate
maturin develop
python
import rust_decider
d = rust_decider.init("darkmode fractional_availability value", "../cfg.json")
d.printer() # prints yooo
ctx = rust_decider.make_ctx({"user_id": "8"})
x = d.choose("exp_1", ctx)
x.decision() # prints the variant!!!!
y = d.get_map("dc_map", ctx) # fetch a map DC
y.err() # check that error is empty
y.val() # get the actual map itself
Development
cd decider-py/
and run maturin develop
to build reddit-decider
python wheel.
Publishing
package in test.pypi.org: https://test.pypi.org/project/decider-py
Upload to test.pypi via:
maturin publish -r https://test.pypi.org/legacy/ --username mattknox --password “”
Download from test.pypi via:
pip3 install --index-url https://test.pypi.org/simple/ decider-py
Formatting / Linting
cargo fmt --manifest-path decider-py/test/Cargo.toml cargo clippy --manifest-path decider-py/test/Cargo.toml
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
reddit_decider-1.1.7.tar.gz
(22.3 kB
view hashes)
Built Distributions
Close
Hashes for reddit_decider-1.1.7-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3e6b982316617dd85a7785d2567a9df5ce921da3c554a158c842ead812e9c01c |
|
MD5 | 256ded903a66dcbabc2ad0da855ca54d |
|
BLAKE2b-256 | 5d557a561b10b20c903e109fbb7ff26e658c2c031b4b27a59a5fc1f5466281c2 |
Close
Hashes for reddit_decider-1.1.7-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5e4189b6d78f92576848f39f1b2db4258b2aa79600267dbd42c076f948c640e8 |
|
MD5 | 17c4a863522a38c6b44a1427fa3bfa31 |
|
BLAKE2b-256 | 323c1ff766c6859d875afb9b6a2b0bca167963193ccca149eb7a3391ec94739d |
Close
Hashes for reddit_decider-1.1.7-cp38-cp38-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3072de1592e5f3ae75044d6b03e4f53677205c7dc3dbbcb2738c43055fcb7403 |
|
MD5 | e61ec8fd72d1824d5e4b93a8beef4166 |
|
BLAKE2b-256 | 16d202376e4b40ce036f92c5c2a603e3a2b5efca56196712c4d126242c566a0c |
Close
Hashes for reddit_decider-1.1.7-cp37-cp37m-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4e617f902ba02fc416c8eae5b1f8a083f22828eb3d8b291c9dad16052aefbbc9 |
|
MD5 | 34b577b2e151bcc689ee386762582b77 |
|
BLAKE2b-256 | 00ef7a6a1c677eed06efd3c01722b811304a05375edc8a38278732830a75c675 |