param 2.5.0b0__tar.gz → 2.5.0b2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {param-2.5.0b0 → param-2.5.0b2}/PKG-INFO +1 -1
- {param-2.5.0b0 → param-2.5.0b2}/param/_version.py +2 -2
- {param-2.5.0b0 → param-2.5.0b2}/param/reactive.py +1 -1
- {param-2.5.0b0 → param-2.5.0b2}/pyproject.toml +1 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testreactive.py +20 -0
- {param-2.5.0b0 → param-2.5.0b2}/.gitignore +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/LICENSE.txt +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/README.md +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/numbergen/__init__.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/__init__.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/_utils.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/depends.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/display.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/ipython.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/mypy_plugin.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/parameterized.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/parameters.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/py.typed +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/serializer.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/param/version.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/__init__.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/assert_types.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/conftest.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/pyrightconfig-bare.json +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testaddparameter.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testbind.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testbooleanparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testbytesparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcalendardateparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcalendardaterangeparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcallable.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testclassselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcolorparameter.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcomparator.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcompositeparams.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testcustomparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdateparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdaterangeparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdefaultfactory.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdefaults.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdeprecations.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testdynamicparams.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testfiledeserialization.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testfileselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testimports.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testipythonmagic.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testjsonserialization.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testlist.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testlistselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testmultifileselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testnumbergen.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testnumberparameter.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testnumpy.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testobjectselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testpandas.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparamdepends.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparameter.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparameterizedobject.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparameterizedrepr.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparamoutput.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testparamunion.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testpathparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testpickle.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testrangeparameter.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testrefs.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testreprhtml.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testselector.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testsignatures.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/teststringparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testtimedependent.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testtupleparam.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testutils.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testversion.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/testwatch.py +0 -0
- {param-2.5.0b0 → param-2.5.0b2}/tests/utils.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: param
|
|
3
|
-
Version: 2.5.
|
|
3
|
+
Version: 2.5.0b2
|
|
4
4
|
Summary: Declarative parameters for robust Python classes and a rich API for reactive programming
|
|
5
5
|
Project-URL: Homepage, https://param.holoviz.org/
|
|
6
6
|
Project-URL: Tracker, https://github.com/holoviz/param/issues
|
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '2.5.
|
|
22
|
-
__version_tuple__ = version_tuple = (2, 5, 0, '
|
|
21
|
+
__version__ = version = '2.5.0b2'
|
|
22
|
+
__version_tuple__ = version_tuple = (2, 5, 0, 'b2')
|
|
23
23
|
|
|
24
24
|
__commit_id__ = commit_id = None
|
|
@@ -1530,7 +1530,7 @@ class reactive_ops:
|
|
|
1530
1530
|
params = self._reactive._params
|
|
1531
1531
|
else:
|
|
1532
1532
|
params = resolve_ref(self._reactive)
|
|
1533
|
-
trigger = Trigger(parameters=params)
|
|
1533
|
+
trigger = Trigger(parameters=params + xrefs + yrefs)
|
|
1534
1534
|
if xrefs:
|
|
1535
1535
|
def trigger_x(*args):
|
|
1536
1536
|
if t.cast("bool", self.value):
|
|
@@ -616,6 +616,26 @@ class TestSpecialMethods:
|
|
|
616
616
|
p.boolean = False
|
|
617
617
|
assert results == ['string', 'foo', 2.1]
|
|
618
618
|
|
|
619
|
+
def test_reactive_where_composed_argument_watches_selected_branch(self):
|
|
620
|
+
"""A composed selector must publish changes to its selected branch."""
|
|
621
|
+
condition, first, second = rx(True), rx(1), rx(2)
|
|
622
|
+
selected = condition.rx.where(first, second)
|
|
623
|
+
composed = rx(lambda value: value * 10)(selected)
|
|
624
|
+
fired = []
|
|
625
|
+
composed.rx.watch(fired.append)
|
|
626
|
+
|
|
627
|
+
assert composed.rx.value == 10
|
|
628
|
+
first.rx.value = 5
|
|
629
|
+
assert fired == [50]
|
|
630
|
+
assert composed.rx.value == 50
|
|
631
|
+
|
|
632
|
+
second.rx.value = 6
|
|
633
|
+
assert fired == [50]
|
|
634
|
+
condition.rx.value = False
|
|
635
|
+
assert fired == [50, 60]
|
|
636
|
+
second.rx.value = 7
|
|
637
|
+
assert fired == [50, 60, 70]
|
|
638
|
+
|
|
619
639
|
class TestWatch:
|
|
620
640
|
"""``.rx.watch()`` and its ``onlychanged``/lazy behavior."""
|
|
621
641
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|