Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-param for openSUSE:Factory checked in at 2025-12-10 15:32:54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-param (Old) and /work/SRC/openSUSE:Factory/.python-param.new.1939 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-param" Wed Dec 10 15:32:54 2025 rev:34 rq:1321798 version:2.3.1 Changes: -------- --- /work/SRC/openSUSE:Factory/python-param/python-param.changes 2025-11-24 17:17:42.374223945 +0100 +++ /work/SRC/openSUSE:Factory/.python-param.new.1939/python-param.changes 2025-12-10 15:33:45.282412058 +0100 @@ -1,0 +2,6 @@ +Tue Dec 9 12:50:27 UTC 2025 - John Paul Adrian Glaubitz <[email protected]> + +- Update to 2.3.1 + * Fix edit_constant to prevent class value mutation when not constant + +------------------------------------------------------------------- Old: ---- param-2.3.0.tar.gz New: ---- param-2.3.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-param.spec ++++++ --- /var/tmp/diff_new_pack.glTLd9/_old 2025-12-10 15:33:46.278454197 +0100 +++ /var/tmp/diff_new_pack.glTLd9/_new 2025-12-10 15:33:46.282454367 +0100 @@ -17,7 +17,7 @@ %{?sle15_python_module_pythons} Name: python-param -Version: 2.3.0 +Version: 2.3.1 Release: 0 Summary: Declarative Python programming using Parameters License: BSD-3-Clause ++++++ param-2.3.0.tar.gz -> param-2.3.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/param-2.3.0/PKG-INFO new/param-2.3.1/PKG-INFO --- old/param-2.3.0/PKG-INFO 2020-02-02 01:00:00.000000000 +0100 +++ new/param-2.3.1/PKG-INFO 2020-02-02 01:00:00.000000000 +0100 @@ -1,7 +1,7 @@ Metadata-Version: 2.4 Name: param -Version: 2.3.0 -Summary: Make your Python code clearer and more reliable by declaring Parameters. +Version: 2.3.1 +Summary: Declarative parameters for robust Python classes and a rich API for reactive programming Project-URL: Homepage, https://param.holoviz.org/ Project-URL: Tracker, https://github.com/holoviz/param/issues Project-URL: Releases, https://github.com/holoviz/param/releases diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/param-2.3.0/param/_version.py new/param-2.3.1/param/_version.py --- old/param-2.3.0/param/_version.py 2020-02-02 01:00:00.000000000 +0100 +++ new/param-2.3.1/param/_version.py 2020-02-02 01:00:00.000000000 +0100 @@ -28,7 +28,7 @@ commit_id: COMMIT_ID __commit_id__: COMMIT_ID -__version__ = version = '2.3.0' -__version_tuple__ = version_tuple = (2, 3, 0) +__version__ = version = '2.3.1' +__version_tuple__ = version_tuple = (2, 3, 1) __commit_id__ = commit_id = None diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/param-2.3.0/param/parameterized.py new/param-2.3.1/param/parameterized.py --- old/param-2.3.0/param/parameterized.py 2020-02-02 01:00:00.000000000 +0100 +++ new/param-2.3.1/param/parameterized.py 2020-02-02 01:00:00.000000000 +0100 @@ -428,6 +428,7 @@ """ kls_params = parameterized.param.objects(instance=False) inst_params = parameterized._param__private.params + init_inst_params = list(inst_params) updated = [] for pname, pobj in (kls_params | inst_params).items(): if pobj.constant: @@ -439,7 +440,7 @@ for pname in updated: # Some operations trigger a parameter instantiation (copy), # we ensure both the class and instance parameters are reset. - if pname in kls_params: + if pname in kls_params and pname not in init_inst_params: type(parameterized).param[pname].constant=True if pname in inst_params: parameterized.param[pname].constant = True diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/param-2.3.0/pyproject.toml new/param-2.3.1/pyproject.toml --- old/param-2.3.0/pyproject.toml 2020-02-02 01:00:00.000000000 +0100 +++ new/param-2.3.1/pyproject.toml 2020-02-02 01:00:00.000000000 +0100 @@ -5,7 +5,7 @@ [project] name = "param" dynamic = ["version"] -description = "Make your Python code clearer and more reliable by declaring Parameters." +description = "Declarative parameters for robust Python classes and a rich API for reactive programming" readme = "README.md" license = { text = "BSD-3-Clause" } requires-python = ">=3.10" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/param-2.3.0/tests/testparameterizedobject.py new/param-2.3.1/tests/testparameterizedobject.py --- old/param-2.3.0/tests/testparameterizedobject.py 2020-02-02 01:00:00.000000000 +0100 +++ new/param-2.3.1/tests/testparameterizedobject.py 2020-02-02 01:00:00.000000000 +0100 @@ -329,6 +329,26 @@ assert TestPO.param['const'].constant assert TestPO.param['const'].default not in (670, 891) + def test_edit_constant_does_not_mutate_cls_value_if_not_constant(self): + # Regression https://github.com/holoviz/param/issues/1100 + class P(param.Parameterized): + a = param.Number() + + + p = P() + + # Manually set p.param.a.constant to True + p.param.a.constant = True + + assert p.param.a.constant is True + assert P.param.a.constant is False + + with param.parameterized.edit_constant(p): + pass + + assert p.param.a.constant is True + assert P.param.a.constant is False + def test_readonly_parameter(self): """Test that you can't set a read-only parameter on construction or as an attribute.""" testpo = TestPO()
