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.0.tar.gz
(21.5 kB
view hashes)
Built Distributions
Close
Hashes for reddit_decider-1.1.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 555fe9227b59a3372f6a1989503dfe0d69b5ce178e07bb29fdbdf1da70f5eec0 |
|
MD5 | f3ed60d4c710dc2e36d5e68ca215ded9 |
|
BLAKE2b-256 | 897211c7ee93b86f39d92e1bd9f3ba008ebe4ae2109a35c3b9081f207e81640f |
Close
Hashes for reddit_decider-1.1.0-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 48b2d6dd8009cc553bdc6a46f070d841ada147c0911cd3540cd9c1d8e89a095f |
|
MD5 | 1b3e8fa121c8e5e4b7817e77b6930762 |
|
BLAKE2b-256 | ae49db05579fd818471bf4870caa8c2aa4cfd9baa30d233a0ceac41824e1bf32 |
Close
Hashes for reddit_decider-1.1.0-cp38-cp38-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 51a023820410b1960f085352d2f5b528333f8906e877f79ca6ad46d489a8da49 |
|
MD5 | cdcea60fd357b1c02682bf357fd6bc77 |
|
BLAKE2b-256 | add49b759bf66a6259eb4df3a8133c4cc90c0937e15c5f6c944df792dbe37457 |
Close
Hashes for reddit_decider-1.1.0-cp37-cp37m-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 38ade09d7e3e02231ad5d61d10b452a1a8309330355f1161e154fda097c21944 |
|
MD5 | 763fe9840604801de15cc638c3e1c64d |
|
BLAKE2b-256 | a8e2ed019745d618cebb0ab7ed5411e3a67202242cacb8a3ee379510ffb659d3 |