Pipda

Latest version: v0.13.1

Safety actively analyzes 681844 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 5 of 10

0.5.3

- 🚑 Fix operator func lookup for `Operator`
- 🩹 Don't stringify the Symbolic object
python
f.a
previously: "f.a", now: "a"
f['a']
previously: "f[a]", now: "a"
f.a['b']
previously: "f.a[b]", now: "a[b]"
mean(f.a)
previously: "mean(f.a)", now: "mean(a)"
f.a + 1
previously: "f.a + 1", now: "a + 1"

0.5.2

- Add `level` argument to context.getitem()/getattr() so that the expression level can be used in evaluation;
- Add `eval_symbolic()` to context to allow evaluate Symbolic objects in different ways.

0.5.1

- Remove abstract property `name` from contexts (`name` is no longer a required property to subclass `ContextBase`)
- Allow meta data of context to be passed down
python
from pipda import Symbolic, register_func, register_verb, evaluate_expr
from pipda.context import Context, ContextEval

f = Symbolic()

register_func(None, context=Context.SELECT)
def wrapper(x):
return x

register_func(None, context=Context.EVAL)
def times_meta(x, _context=None):
return x * _context.meta["val"]

register_verb(dict, context=ContextEval({"val": 10}))
def add(x, y):
return x["a"] + y

metadata passed down to times_meta
{"a": 1} >> add(wrapper(use_meta(f["a"])))
12

0.5.0

- Stringify `Expression` objects reasonably

f.a -> "f.a"
f['a'] -> "f[a]"
mean(f.a) -> "mean(f.a)"
f.a + 1 -> "f.a + 1"

- (Breaking) Deprecate `DirectRefAttr` and `DirectRefItem`. Use `ref._pipda_level` instead.

f -> f._pipda_level == 0
f.a -> f._pipda_level == 1
f.a.b -> f._pipda_level == 2

- Household
Use `flake8` instead of `pylint` for linting.

0.4.5

- Add `CallingEnvs.REGULAR`

0.4.4

- Add `options` and `options_context`.
- Move `warn_astnode_failure` to options
- Add `assume_all_piping` mode

Page 5 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.