From 9ebb216f58d029f66c983ab732cc9f0d1429c688 Mon Sep 17 00:00:00 2001 From: Rob Nagler <5495179+robnagler@users.noreply.github.com> Date: Sat, 11 Apr 2026 23:10:26 +0000 Subject: [PATCH 1/2] Fix #640 fconf list of list should not merge --- pykern/fconf.py | 3 ++- tests/fconf_data/1.in/1.yml | 1 + tests/fconf_data/1.out/res.json | 5 +++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/pykern/fconf.py b/pykern/fconf.py index b89ea901..89fea058 100644 --- a/pykern/fconf.py +++ b/pykern/fconf.py @@ -457,7 +457,8 @@ def _list(self, new, base): # lists don't have base values with self._xpath(f"[{i}]"): x = self._do(e, None) - if isinstance(x, list): + # if list of lists, just append. If expression returns list, then extend + if not isinstance(e, list) and isinstance(x, list): res.extend(x) else: res.append(x) diff --git a/tests/fconf_data/1.in/1.yml b/tests/fconf_data/1.in/1.yml index 10aeea7b..05ca88d5 100644 --- a/tests/fconf_data/1.in/1.yml +++ b/tests/fconf_data/1.in/1.yml @@ -29,6 +29,7 @@ one: more_items(inside()): list: - r0 + - [a, b, c] - red() mixed: mymap(host, range(3, 5)) all_hosts: map(host, ${top.hosts}) diff --git a/tests/fconf_data/1.out/res.json b/tests/fconf_data/1.out/res.json index 96cee0db..05b69cc6 100644 --- a/tests/fconf_data/1.out/res.json +++ b/tests/fconf_data/1.out/res.json @@ -56,6 +56,11 @@ ], "list": [ "r0", + [ + "a", + "b", + "c" + ], "r1", "r2" ], From ad5e8ea41ac4288c25130a89a7f10a9d08eb9fd1 Mon Sep 17 00:00:00 2001 From: Rob Nagler <5495179+robnagler@users.noreply.github.com> Date: Sat, 11 Apr 2026 23:32:56 +0000 Subject: [PATCH 2/2] upgrade to 3.13 --- .readthedocs.yml | 2 +- pykern/package_data/projex/dot-readthedocs.yml.jinja | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index a4206602..fa10316d 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -4,7 +4,7 @@ version: 2 build: os: ubuntu-22.04 tools: - python: "3.9" + python: "3.13" jobs: pre_build: - curl https://radia.run | bash -s readthedocs diff --git a/pykern/package_data/projex/dot-readthedocs.yml.jinja b/pykern/package_data/projex/dot-readthedocs.yml.jinja index a4206602..fa10316d 100644 --- a/pykern/package_data/projex/dot-readthedocs.yml.jinja +++ b/pykern/package_data/projex/dot-readthedocs.yml.jinja @@ -4,7 +4,7 @@ version: 2 build: os: ubuntu-22.04 tools: - python: "3.9" + python: "3.13" jobs: pre_build: - curl https://radia.run | bash -s readthedocs