0s autopkgtest [17:07:50]: starting date and time: 2026-01-13 17:07:50+0000 0s autopkgtest [17:07:50]: git checkout: 4b346b80 nova: make wait_reboot return success even when a no-op 0s autopkgtest [17:07:50]: host juju-7f2275-prod-proposed-migration-environment-20; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.xsy8narz/out --timeout-copy=6000 --setup-commands /home/ubuntu/autopkgtest-cloud/worker-config-production/setup-canonical.sh --apt-pocket=proposed=src:mkdocstrings --apt-upgrade mkdocstrings-python-legacy --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 --env=ADT_TEST_TRIGGERS=mkdocstrings/1.0.0-1 -- ssh -s /home/ubuntu/autopkgtest/ssh-setup/nova -- --flavor autopkgtest-cpu2-ram4-disk20-amd64 --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-20@sto01-13.secgroup --name adt-resolute-amd64-mkdocstrings-python-legacy-20260113-170750-juju-7f2275-prod-proposed-migration-environment-20-a2b036da-d0c2-40c2-a6bc-32202daa2484 --image adt/ubuntu-resolute-amd64-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-20 --net-id=net_prod-autopkgtest-workers-amd64 -e TERM=linux --mirror=http://ftpmaster.internal/ubuntu/ 4s Creating nova instance adt-resolute-amd64-mkdocstrings-python-legacy-20260113-170750-juju-7f2275-prod-proposed-migration-environment-20-a2b036da-d0c2-40c2-a6bc-32202daa2484 from image adt/ubuntu-resolute-amd64-server-20260113.img (UUID 2b39d963-0c90-4dbc-a70f-d642e4fb05d5)... 84s autopkgtest [17:09:14]: testbed dpkg architecture: amd64 84s autopkgtest [17:09:14]: testbed apt version: 3.1.12 85s autopkgtest [17:09:15]: @@@@@@@@@@@@@@@@@@@@ test bed setup 85s autopkgtest [17:09:15]: testbed release detected to be: None 85s autopkgtest [17:09:15]: updating testbed package index (apt update) 86s Get:1 http://ftpmaster.internal/ubuntu resolute-proposed InRelease [124 kB] 86s Hit:2 http://ftpmaster.internal/ubuntu resolute InRelease 86s Hit:3 http://ftpmaster.internal/ubuntu resolute-updates InRelease 86s Hit:4 http://ftpmaster.internal/ubuntu resolute-security InRelease 86s Get:5 http://ftpmaster.internal/ubuntu resolute-proposed/restricted Sources [1052 B] 86s Get:6 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse Sources [18.4 kB] 86s Get:7 http://ftpmaster.internal/ubuntu resolute-proposed/main Sources [68.6 kB] 86s Get:8 http://ftpmaster.internal/ubuntu resolute-proposed/universe Sources [995 kB] 86s Get:9 http://ftpmaster.internal/ubuntu resolute-proposed/main i386 Packages [55.6 kB] 86s Get:10 http://ftpmaster.internal/ubuntu resolute-proposed/main amd64 Packages [78.0 kB] 86s Get:11 http://ftpmaster.internal/ubuntu resolute-proposed/main amd64 c-n-f Metadata [2996 B] 86s Get:12 http://ftpmaster.internal/ubuntu resolute-proposed/restricted amd64 Packages [1172 B] 86s Get:13 http://ftpmaster.internal/ubuntu resolute-proposed/restricted amd64 c-n-f Metadata [120 B] 86s Get:14 http://ftpmaster.internal/ubuntu resolute-proposed/universe i386 Packages [280 kB] 86s Get:15 http://ftpmaster.internal/ubuntu resolute-proposed/universe amd64 Packages [704 kB] 86s Get:16 http://ftpmaster.internal/ubuntu resolute-proposed/universe amd64 c-n-f Metadata [18.8 kB] 86s Get:17 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse i386 Packages [3604 B] 86s Get:18 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse amd64 Packages [7308 B] 86s Get:19 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse amd64 c-n-f Metadata [532 B] 87s Fetched 2359 kB in 1s (3306 kB/s) 87s Reading package lists... 88s Hit:1 http://ftpmaster.internal/ubuntu resolute-proposed InRelease 88s Hit:2 http://ftpmaster.internal/ubuntu resolute InRelease 88s Hit:3 http://ftpmaster.internal/ubuntu resolute-updates InRelease 88s Hit:4 http://ftpmaster.internal/ubuntu resolute-security InRelease 89s Reading package lists... 89s Reading package lists... 89s Building dependency tree... 89s Reading state information... 89s Calculating upgrade... 89s The following packages will be upgraded: 89s lxd-agent-loader python3-uc-micro 89s 2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 89s Need to get 10.6 kB of archives. 89s After this operation, 0 B of additional disk space will be used. 89s Get:1 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-uc-micro all 1.0.3-1build1 [5702 B] 89s Get:2 http://ftpmaster.internal/ubuntu resolute/main amd64 lxd-agent-loader all 0.9ubuntu0 [4878 B] 89s dpkg-preconfigure: unable to re-open stdin: No such file or directory 89s Fetched 10.6 kB in 0s (0 B/s) 89s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 84201 files and directories currently installed.) 89s Preparing to unpack .../python3-uc-micro_1.0.3-1build1_all.deb ... 89s Unpacking python3-uc-micro (1.0.3-1build1) over (1.0.3-1) ... 89s Preparing to unpack .../lxd-agent-loader_0.9ubuntu0_all.deb ... 89s Unpacking lxd-agent-loader (0.9ubuntu0) over (0.8build1) ... 89s Setting up lxd-agent-loader (0.9ubuntu0) ... 90s lxd-agent.service is a disabled or a static unit, not starting it. 90s Setting up python3-uc-micro (1.0.3-1build1) ... 90s autopkgtest [17:09:20]: upgrading testbed (apt dist-upgrade and autopurge) 90s Reading package lists... 90s Building dependency tree... 90s Reading state information... 90s Calculating upgrade... 90s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 90s Reading package lists... 90s Building dependency tree... 90s Reading state information... 90s Solving dependencies... 91s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 91s autopkgtest [17:09:21]: rebooting testbed after setup commands that affected boot 120s autopkgtest [17:09:50]: testbed running kernel: Linux 6.18.0-8-generic #8-Ubuntu SMP PREEMPT_DYNAMIC Wed Dec 17 16:14:24 UTC 2025 122s autopkgtest [17:09:52]: @@@@@@@@@@@@@@@@@@@@ apt-source mkdocstrings-python-legacy 123s Get:1 http://ftpmaster.internal/ubuntu resolute/universe mkdocstrings-python-legacy 0.2.7-1 (dsc) [2626 B] 123s Get:2 http://ftpmaster.internal/ubuntu resolute/universe mkdocstrings-python-legacy 0.2.7-1 (tar) [99.5 kB] 123s Get:3 http://ftpmaster.internal/ubuntu resolute/universe mkdocstrings-python-legacy 0.2.7-1 (diff) [4420 B] 123s gpgv: Signature made Sun Jul 13 21:16:29 2025 UTC 123s gpgv: using RSA key B70DFC6F134FECFC011E62AA83016014251D1DB0 123s gpgv: issuer "c.schoenert@t-online.de" 123s gpgv: Can't check signature: No public key 123s dpkg-source: warning: cannot verify inline signature for ./mkdocstrings-python-legacy_0.2.7-1.dsc: no acceptable signature found 123s autopkgtest [17:09:53]: testing package mkdocstrings-python-legacy version 0.2.7-1 123s autopkgtest [17:09:53]: build not needed 124s autopkgtest [17:09:54]: test upstream-tests: preparing testbed 125s Reading package lists... 125s Building dependency tree... 125s Reading state information... 125s Solving dependencies... 125s The following NEW packages will be installed: 125s fonts-font-awesome fonts-lato ghp-import libjs-bootstrap5 libjs-jquery 125s libjs-lunr mkdocs mkdocs-autorefs mkdocs-get-deps mkdocs-material 125s mkdocs-material-extensions mkdocstrings mkdocstrings-python-legacy 125s node-popper2 python3-all python3-click python3-colorama python3-iniconfig 125s python3-joblib python3-livereload python3-lunr python3-markdown 125s python3-mergedeep python3-nltk python3-paginate python3-pathspec 125s python3-platformdirs python3-pluggy python3-pymdownx python3-pytest 125s python3-pytkdocs python3-pyyaml-env-tag python3-regex python3-tornado 125s python3-tqdm python3-watchdog sphinx-rtd-theme-common 125s 0 upgraded, 37 newly installed, 0 to remove and 0 not upgraded. 125s Need to get 15.0 MB of archives. 125s After this operation, 66.9 MB of additional disk space will be used. 125s Get:1 http://ftpmaster.internal/ubuntu resolute/main amd64 fonts-lato all 2.015-1build1 [2779 kB] 125s Get:2 http://ftpmaster.internal/ubuntu resolute/main amd64 fonts-font-awesome all 5.0.10+really4.7.0~dfsg-4.1build1 [531 kB] 125s Get:3 http://ftpmaster.internal/ubuntu resolute/universe amd64 ghp-import all 2.1.0-3build1 [12.5 kB] 125s Get:4 http://ftpmaster.internal/ubuntu resolute/universe amd64 node-popper2 all 2.11.2-9 [106 kB] 125s Get:5 http://ftpmaster.internal/ubuntu resolute/universe amd64 libjs-bootstrap5 all 5.3.8+dfsg-2 [480 kB] 125s Get:6 http://ftpmaster.internal/ubuntu resolute/main amd64 libjs-jquery all 3.7.1+dfsg+~3.5.33-1build1 [321 kB] 125s Get:7 http://ftpmaster.internal/ubuntu resolute/universe amd64 libjs-lunr all 2.3.9~dfsg-2 [66.8 kB] 125s Get:8 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-tornado amd64 6.5.4-0.1 [306 kB] 125s Get:9 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-livereload all 2.7.1-0.1 [22.7 kB] 125s Get:10 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-click all 8.2.0+0.really.8.1.8-1build1 [80.2 kB] 125s Get:11 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-joblib all 1.5.2-1 [210 kB] 125s Get:12 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-regex amd64 0.1.20250918-1 [310 kB] 125s Get:13 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-tqdm all 4.67.1-7 [93.3 kB] 125s Get:14 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-nltk all 3.9.1-2 [1006 kB] 125s Get:15 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-lunr all 0.8.0-1 [28.5 kB] 125s Get:16 http://ftpmaster.internal/ubuntu resolute/main amd64 sphinx-rtd-theme-common all 3.0.2+dfsg-3 [1013 kB] 125s Get:17 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-mergedeep all 1.3.4-4 [7128 B] 125s Get:18 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-platformdirs all 4.5.1-1 [17.1 kB] 125s Get:19 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocs-get-deps all 0.2.0-2 [9274 B] 125s Get:20 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-markdown all 3.10-2 [76.0 kB] 125s Get:21 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pathspec all 0.12.1-1build1 [24.6 kB] 125s Get:22 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pyyaml-env-tag all 1.1-1 [6100 B] 125s Get:23 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-watchdog all 6.0.0-4 [72.0 kB] 125s Get:24 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocs all 1.6.1+dfsg1-2 [2920 kB] 125s Get:25 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocs-autorefs all 1.4.3-1 [22.0 kB] 125s Get:26 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocs-material-extensions all 1.3.1-2 [10.5 kB] 125s Get:27 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-colorama all 0.4.6-4build1 [32.2 kB] 125s Get:28 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-paginate all 0.5.7-3 [13.4 kB] 125s Get:29 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pymdownx all 10.19.1-3 [162 kB] 125s Get:30 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocs-material all 9.6.4-1 [3845 kB] 125s Get:31 http://ftpmaster.internal/ubuntu resolute-proposed/universe amd64 mkdocstrings all 1.0.0-1 [30.2 kB] 125s Get:32 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pytkdocs all 0.16.5-1 [31.2 kB] 125s Get:33 http://ftpmaster.internal/ubuntu resolute/universe amd64 mkdocstrings-python-legacy all 0.2.7-1 [17.5 kB] 125s Get:34 http://ftpmaster.internal/ubuntu resolute/main amd64 python3-all amd64 3.13.7-1 [884 B] 125s Get:35 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-iniconfig all 2.1.0-2 [6962 B] 125s Get:36 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pluggy all 1.6.0-2 [21.1 kB] 125s Get:37 http://ftpmaster.internal/ubuntu resolute/universe amd64 python3-pytest all 9.0.2-2 [277 kB] 125s Fetched 15.0 MB in 1s (21.8 MB/s) 125s Selecting previously unselected package fonts-lato. 125s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 84201 files and directories currently installed.) 125s Preparing to unpack .../00-fonts-lato_2.015-1build1_all.deb ... 125s Unpacking fonts-lato (2.015-1build1) ... 125s Selecting previously unselected package fonts-font-awesome. 125s Preparing to unpack .../01-fonts-font-awesome_5.0.10+really4.7.0~dfsg-4.1build1_all.deb ... 125s Unpacking fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1build1) ... 125s Selecting previously unselected package ghp-import. 125s Preparing to unpack .../02-ghp-import_2.1.0-3build1_all.deb ... 125s Unpacking ghp-import (2.1.0-3build1) ... 125s Selecting previously unselected package node-popper2. 125s Preparing to unpack .../03-node-popper2_2.11.2-9_all.deb ... 125s Unpacking node-popper2 (2.11.2-9) ... 125s Selecting previously unselected package libjs-bootstrap5. 125s Preparing to unpack .../04-libjs-bootstrap5_5.3.8+dfsg-2_all.deb ... 125s Unpacking libjs-bootstrap5 (5.3.8+dfsg-2) ... 125s Selecting previously unselected package libjs-jquery. 125s Preparing to unpack .../05-libjs-jquery_3.7.1+dfsg+~3.5.33-1build1_all.deb ... 125s Unpacking libjs-jquery (3.7.1+dfsg+~3.5.33-1build1) ... 125s Selecting previously unselected package libjs-lunr. 125s Preparing to unpack .../06-libjs-lunr_2.3.9~dfsg-2_all.deb ... 125s Unpacking libjs-lunr (2.3.9~dfsg-2) ... 125s Selecting previously unselected package python3-tornado. 125s Preparing to unpack .../07-python3-tornado_6.5.4-0.1_amd64.deb ... 125s Unpacking python3-tornado (6.5.4-0.1) ... 125s Selecting previously unselected package python3-livereload. 125s Preparing to unpack .../08-python3-livereload_2.7.1-0.1_all.deb ... 125s Unpacking python3-livereload (2.7.1-0.1) ... 125s Selecting previously unselected package python3-click. 125s Preparing to unpack .../09-python3-click_8.2.0+0.really.8.1.8-1build1_all.deb ... 125s Unpacking python3-click (8.2.0+0.really.8.1.8-1build1) ... 125s Selecting previously unselected package python3-joblib. 125s Preparing to unpack .../10-python3-joblib_1.5.2-1_all.deb ... 125s Unpacking python3-joblib (1.5.2-1) ... 125s Selecting previously unselected package python3-regex. 125s Preparing to unpack .../11-python3-regex_0.1.20250918-1_amd64.deb ... 125s Unpacking python3-regex (0.1.20250918-1) ... 125s Selecting previously unselected package python3-tqdm. 125s Preparing to unpack .../12-python3-tqdm_4.67.1-7_all.deb ... 125s Unpacking python3-tqdm (4.67.1-7) ... 125s Selecting previously unselected package python3-nltk. 125s Preparing to unpack .../13-python3-nltk_3.9.1-2_all.deb ... 125s Unpacking python3-nltk (3.9.1-2) ... 125s Selecting previously unselected package python3-lunr. 125s Preparing to unpack .../14-python3-lunr_0.8.0-1_all.deb ... 125s Unpacking python3-lunr (0.8.0-1) ... 125s Selecting previously unselected package sphinx-rtd-theme-common. 125s Preparing to unpack .../15-sphinx-rtd-theme-common_3.0.2+dfsg-3_all.deb ... 125s Unpacking sphinx-rtd-theme-common (3.0.2+dfsg-3) ... 125s Selecting previously unselected package python3-mergedeep. 125s Preparing to unpack .../16-python3-mergedeep_1.3.4-4_all.deb ... 125s Unpacking python3-mergedeep (1.3.4-4) ... 125s Selecting previously unselected package python3-platformdirs. 125s Preparing to unpack .../17-python3-platformdirs_4.5.1-1_all.deb ... 125s Unpacking python3-platformdirs (4.5.1-1) ... 126s Selecting previously unselected package mkdocs-get-deps. 126s Preparing to unpack .../18-mkdocs-get-deps_0.2.0-2_all.deb ... 126s Unpacking mkdocs-get-deps (0.2.0-2) ... 126s Selecting previously unselected package python3-markdown. 126s Preparing to unpack .../19-python3-markdown_3.10-2_all.deb ... 126s Unpacking python3-markdown (3.10-2) ... 126s Selecting previously unselected package python3-pathspec. 126s Preparing to unpack .../20-python3-pathspec_0.12.1-1build1_all.deb ... 126s Unpacking python3-pathspec (0.12.1-1build1) ... 126s Selecting previously unselected package python3-pyyaml-env-tag. 126s Preparing to unpack .../21-python3-pyyaml-env-tag_1.1-1_all.deb ... 126s Unpacking python3-pyyaml-env-tag (1.1-1) ... 126s Selecting previously unselected package python3-watchdog. 126s Preparing to unpack .../22-python3-watchdog_6.0.0-4_all.deb ... 126s Unpacking python3-watchdog (6.0.0-4) ... 126s Selecting previously unselected package mkdocs. 126s Preparing to unpack .../23-mkdocs_1.6.1+dfsg1-2_all.deb ... 126s Unpacking mkdocs (1.6.1+dfsg1-2) ... 126s Selecting previously unselected package mkdocs-autorefs. 126s Preparing to unpack .../24-mkdocs-autorefs_1.4.3-1_all.deb ... 126s Unpacking mkdocs-autorefs (1.4.3-1) ... 126s Selecting previously unselected package mkdocs-material-extensions. 126s Preparing to unpack .../25-mkdocs-material-extensions_1.3.1-2_all.deb ... 126s Unpacking mkdocs-material-extensions (1.3.1-2) ... 126s Selecting previously unselected package python3-colorama. 126s Preparing to unpack .../26-python3-colorama_0.4.6-4build1_all.deb ... 126s Unpacking python3-colorama (0.4.6-4build1) ... 126s Selecting previously unselected package python3-paginate. 126s Preparing to unpack .../27-python3-paginate_0.5.7-3_all.deb ... 126s Unpacking python3-paginate (0.5.7-3) ... 126s Selecting previously unselected package python3-pymdownx. 126s Preparing to unpack .../28-python3-pymdownx_10.19.1-3_all.deb ... 126s Unpacking python3-pymdownx (10.19.1-3) ... 126s Selecting previously unselected package mkdocs-material. 126s Preparing to unpack .../29-mkdocs-material_9.6.4-1_all.deb ... 126s Unpacking mkdocs-material (9.6.4-1) ... 126s Selecting previously unselected package mkdocstrings. 126s Preparing to unpack .../30-mkdocstrings_1.0.0-1_all.deb ... 126s Unpacking mkdocstrings (1.0.0-1) ... 126s Selecting previously unselected package python3-pytkdocs. 126s Preparing to unpack .../31-python3-pytkdocs_0.16.5-1_all.deb ... 126s Unpacking python3-pytkdocs (0.16.5-1) ... 126s Selecting previously unselected package mkdocstrings-python-legacy. 126s Preparing to unpack .../32-mkdocstrings-python-legacy_0.2.7-1_all.deb ... 126s Unpacking mkdocstrings-python-legacy (0.2.7-1) ... 126s Selecting previously unselected package python3-all. 126s Preparing to unpack .../33-python3-all_3.13.7-1_amd64.deb ... 126s Unpacking python3-all (3.13.7-1) ... 126s Selecting previously unselected package python3-iniconfig. 126s Preparing to unpack .../34-python3-iniconfig_2.1.0-2_all.deb ... 126s Unpacking python3-iniconfig (2.1.0-2) ... 126s Selecting previously unselected package python3-pluggy. 126s Preparing to unpack .../35-python3-pluggy_1.6.0-2_all.deb ... 126s Unpacking python3-pluggy (1.6.0-2) ... 126s Selecting previously unselected package python3-pytest. 126s Preparing to unpack .../36-python3-pytest_9.0.2-2_all.deb ... 126s Unpacking python3-pytest (9.0.2-2) ... 126s Setting up python3-iniconfig (2.1.0-2) ... 126s Setting up python3-tornado (6.5.4-0.1) ... 127s Setting up fonts-lato (2.015-1build1) ... 127s Setting up python3-joblib (1.5.2-1) ... 127s Setting up python3-colorama (0.4.6-4build1) ... 127s Setting up python3-watchdog (6.0.0-4) ... 127s Setting up libjs-lunr (2.3.9~dfsg-2) ... 127s Setting up python3-tqdm (4.67.1-7) ... 127s Setting up python3-all (3.13.7-1) ... 127s Setting up python3-click (8.2.0+0.really.8.1.8-1build1) ... 127s Setting up mkdocs-material-extensions (1.3.1-2) ... 127s Setting up python3-platformdirs (4.5.1-1) ... 127s Setting up python3-pyyaml-env-tag (1.1-1) ... 127s Setting up python3-paginate (0.5.7-3) ... 127s Setting up python3-pytkdocs (0.16.5-1) ... 127s Setting up python3-markdown (3.10-2) ... 127s Setting up python3-mergedeep (1.3.4-4) ... 127s Setting up python3-regex (0.1.20250918-1) ... 128s Setting up python3-pluggy (1.6.0-2) ... 128s Setting up ghp-import (2.1.0-3build1) ... 128s Setting up node-popper2 (2.11.2-9) ... 128s Setting up python3-livereload (2.7.1-0.1) ... 128s Setting up libjs-jquery (3.7.1+dfsg+~3.5.33-1build1) ... 128s Setting up python3-pathspec (0.12.1-1build1) ... 128s Setting up libjs-bootstrap5 (5.3.8+dfsg-2) ... 128s Setting up python3-nltk (3.9.1-2) ... 128s Setting up fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1build1) ... 128s Setting up sphinx-rtd-theme-common (3.0.2+dfsg-3) ... 128s Setting up python3-lunr (0.8.0-1) ... 128s Setting up python3-pytest (9.0.2-2) ... 129s Setting up python3-pymdownx (10.19.1-3) ... 129s Setting up mkdocs-get-deps (0.2.0-2) ... 129s Setting up mkdocs (1.6.1+dfsg1-2) ... 129s Setting up mkdocs-autorefs (1.4.3-1) ... 129s Setting up mkdocs-material (9.6.4-1) ... 129s Setting up mkdocstrings (1.0.0-1) ... 129s Setting up mkdocstrings-python-legacy (0.2.7-1) ... 129s Processing triggers for man-db (2.13.1-1) ... 130s autopkgtest [17:10:00]: test upstream-tests: [----------------------- 131s 131s *************************** 131s *** Testing with python3.13 131s *************************** 131s 131s Content of current working folder: 131s 131s total 24 131s drwxr-xr-x 4 ubuntu ubuntu 4096 Jan 13 17:10 . 131s drwxrwxrwx 5 root root 4096 Jan 13 17:10 .. 131s drwxrwxr-x 7 ubuntu ubuntu 4096 May 22 2025 docs 131s -rw-rw-r-- 1 ubuntu ubuntu 4598 May 22 2025 mkdocs.yml 131s drwxrwxr-x 2 ubuntu ubuntu 4096 May 22 2025 tests 131s Running tests... 131s 131s ============================= test session starts ============================== 131s platform linux -- Python 3.13.11, pytest-9.0.2, pluggy-1.6.0 -- /usr/bin/python3.13 131s cachedir: .pytest_cache 131s rootdir: /tmp/autopkgtest.5MrFSN/autopkgtest_tmp 131s plugins: typeguard-4.4.4 131s collecting ... collected 25 items 131s 131s tests/test_collector.py::test_collect_result_error[retval0-error1\nhello] FAILED 131s tests/test_collector.py::test_collect_result_error[retval1-error1] FAILED 131s tests/test_collector.py::test_collect_result_error[retval2-\nhello] FAILED 131s tests/test_renderer.py::test_members_order PASSED 131s tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin0] FAILED 131s tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin1] FAILED 131s tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin2] FAILED 131s tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin0] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin1] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin2] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin0] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin1] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin2] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin0] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin1] FAILED 132s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin2] FAILED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin0] FAILED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin1] FAILED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin2] FAILED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.handler-plugin0] PASSED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.handler-plugin1] PASSED 133s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.handler-plugin2] PASSED 134s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.rendering-plugin0] PASSED 134s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.rendering-plugin1] PASSED 134s tests/test_themes.py::test_render_themes_templates[mkdocstrings_handlers.python.rendering-plugin2] PASSED 134s 134s =================================== FAILURES =================================== 134s _______________ test_collect_result_error[retval0-error1\nhello] _______________ 134s 134s retval = {'error': 'error1', 'traceback': 'hello'}, exp_res = 'error1\nhello' 134s 134s @pytest.mark.parametrize( 134s ("retval", "exp_res"), 134s [ 134s ({"error": "error1", "traceback": "hello"}, "error1\nhello"), 134s ({"error": "error1"}, "error1"), 134s ({"error": "", "traceback": "hello"}, "\nhello"), 134s ], 134s ) 134s def test_collect_result_error(retval: dict, exp_res: str) -> None: 134s """Test handling of errors when collecting an object. 134s 134s Args: 134s retval: Return value to mock `json.loads` with. 134s exp_res: Expected result. 134s """ 134s with mock.patch("mkdocstrings_handlers.python.handler.json.loads") as m_loads: # noqa: SIM117 134s with pytest.raises(CollectionError) as excinfo: # noqa: PT012 134s m_loads.return_value = retval 134s > handler = get_handler({}, _FakeMkDocsConfig, theme="material") # type: ignore[arg-type] 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_collector.py:33: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:368: in get_handler 134s return PythonHandler(config=dict(handler_config), base_dir=base_dir, **kwargs) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s config = {}, base_dir = PosixPath('.'), kwargs = {'theme': 'material'} 134s 134s def __init__(self, config: dict[str, Any], base_dir: Path, **kwargs: Any) -> None: 134s """Initialize the handler. 134s 134s When instantiating a Python handler, we open a `pytkdocs` subprocess in the background with `subprocess.Popen`. 134s It will allow us to feed input to and read output from this subprocess, keeping it alive during 134s the whole documentation generation. Spawning a new Python subprocess for each "autodoc" instruction would be 134s too resource intensive, and would slow down `mkdocstrings` a lot. 134s 134s Parameters: 134s config: The handler configuration. 134s base_dir: The base directory of the project. 134s **kwargs: Arguments passed to the parent constructor. 134s """ 134s > super().__init__(**kwargs) 134s E TypeError: BaseHandler.__init__() missing 3 required keyword-only arguments: 'custom_templates', 'mdx', and 'mdx_config' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:131: TypeError 134s __________________ test_collect_result_error[retval1-error1] ___________________ 134s 134s retval = {'error': 'error1'}, exp_res = 'error1' 134s 134s @pytest.mark.parametrize( 134s ("retval", "exp_res"), 134s [ 134s ({"error": "error1", "traceback": "hello"}, "error1\nhello"), 134s ({"error": "error1"}, "error1"), 134s ({"error": "", "traceback": "hello"}, "\nhello"), 134s ], 134s ) 134s def test_collect_result_error(retval: dict, exp_res: str) -> None: 134s """Test handling of errors when collecting an object. 134s 134s Args: 134s retval: Return value to mock `json.loads` with. 134s exp_res: Expected result. 134s """ 134s with mock.patch("mkdocstrings_handlers.python.handler.json.loads") as m_loads: # noqa: SIM117 134s with pytest.raises(CollectionError) as excinfo: # noqa: PT012 134s m_loads.return_value = retval 134s > handler = get_handler({}, _FakeMkDocsConfig, theme="material") # type: ignore[arg-type] 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_collector.py:33: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:368: in get_handler 134s return PythonHandler(config=dict(handler_config), base_dir=base_dir, **kwargs) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s config = {}, base_dir = PosixPath('.'), kwargs = {'theme': 'material'} 134s 134s def __init__(self, config: dict[str, Any], base_dir: Path, **kwargs: Any) -> None: 134s """Initialize the handler. 134s 134s When instantiating a Python handler, we open a `pytkdocs` subprocess in the background with `subprocess.Popen`. 134s It will allow us to feed input to and read output from this subprocess, keeping it alive during 134s the whole documentation generation. Spawning a new Python subprocess for each "autodoc" instruction would be 134s too resource intensive, and would slow down `mkdocstrings` a lot. 134s 134s Parameters: 134s config: The handler configuration. 134s base_dir: The base directory of the project. 134s **kwargs: Arguments passed to the parent constructor. 134s """ 134s > super().__init__(**kwargs) 134s E TypeError: BaseHandler.__init__() missing 3 required keyword-only arguments: 'custom_templates', 'mdx', and 'mdx_config' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:131: TypeError 134s __________________ test_collect_result_error[retval2-\nhello] __________________ 134s 134s retval = {'error': '', 'traceback': 'hello'}, exp_res = '\nhello' 134s 134s @pytest.mark.parametrize( 134s ("retval", "exp_res"), 134s [ 134s ({"error": "error1", "traceback": "hello"}, "error1\nhello"), 134s ({"error": "error1"}, "error1"), 134s ({"error": "", "traceback": "hello"}, "\nhello"), 134s ], 134s ) 134s def test_collect_result_error(retval: dict, exp_res: str) -> None: 134s """Test handling of errors when collecting an object. 134s 134s Args: 134s retval: Return value to mock `json.loads` with. 134s exp_res: Expected result. 134s """ 134s with mock.patch("mkdocstrings_handlers.python.handler.json.loads") as m_loads: # noqa: SIM117 134s with pytest.raises(CollectionError) as excinfo: # noqa: PT012 134s m_loads.return_value = retval 134s > handler = get_handler({}, _FakeMkDocsConfig, theme="material") # type: ignore[arg-type] 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_collector.py:33: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:368: in get_handler 134s return PythonHandler(config=dict(handler_config), base_dir=base_dir, **kwargs) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s config = {}, base_dir = PosixPath('.'), kwargs = {'theme': 'material'} 134s 134s def __init__(self, config: dict[str, Any], base_dir: Path, **kwargs: Any) -> None: 134s """Initialize the handler. 134s 134s When instantiating a Python handler, we open a `pytkdocs` subprocess in the background with `subprocess.Popen`. 134s It will allow us to feed input to and read output from this subprocess, keeping it alive during 134s the whole documentation generation. Spawning a new Python subprocess for each "autodoc" instruction would be 134s too resource intensive, and would slow down `mkdocstrings` a lot. 134s 134s Parameters: 134s config: The handler configuration. 134s base_dir: The base directory of the project. 134s **kwargs: Arguments passed to the parent constructor. 134s """ 134s > super().__init__(**kwargs) 134s E TypeError: BaseHandler.__init__() missing 3 required keyword-only arguments: 'custom_templates', 'mdx', and 'mdx_config' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:131: TypeError 134s _________ test_render_themes_templates[mkdocstrings.extension-plugin0] _________ 134s 134s module = 'mkdocstrings.extension' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.extension' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'extension' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'extension'. Did you mean: 'makeExtension'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _________ test_render_themes_templates[mkdocstrings.extension-plugin1] _________ 134s 134s module = 'mkdocstrings.extension' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.extension' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'extension' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'extension'. Did you mean: 'makeExtension'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _________ test_render_themes_templates[mkdocstrings.extension-plugin2] _________ 134s 134s module = 'mkdocstrings.extension' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.extension' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'extension' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'extension'. Did you mean: 'makeExtension'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _________ test_render_themes_templates[mkdocstrings.inventory-plugin0] _________ 134s 134s module = 'mkdocstrings.inventory' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.inventory' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'inventory' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'inventory'. Did you mean: 'Inventory'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _________ test_render_themes_templates[mkdocstrings.inventory-plugin1] _________ 134s 134s module = 'mkdocstrings.inventory' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.inventory' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'inventory' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'inventory'. Did you mean: 'Inventory'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _________ test_render_themes_templates[mkdocstrings.inventory-plugin2] _________ 134s 134s module = 'mkdocstrings.inventory' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.inventory' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'inventory' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'inventory'. Did you mean: 'Inventory'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s __________ test_render_themes_templates[mkdocstrings.loggers-plugin0] __________ 134s 134s module = 'mkdocstrings.loggers' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.loggers' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'loggers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'loggers' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s __________ test_render_themes_templates[mkdocstrings.loggers-plugin1] __________ 134s 134s module = 'mkdocstrings.loggers' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.loggers' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'loggers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'loggers' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s __________ test_render_themes_templates[mkdocstrings.loggers-plugin2] __________ 134s 134s module = 'mkdocstrings.loggers' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.loggers' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'loggers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'loggers' 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _______ test_render_themes_templates[mkdocstrings.handlers.base-plugin0] _______ 134s 134s module = 'mkdocstrings.handlers.base' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.base' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _______ test_render_themes_templates[mkdocstrings.handlers.base-plugin1] _______ 134s 134s module = 'mkdocstrings.handlers.base' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.base' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s _______ test_render_themes_templates[mkdocstrings.handlers.base-plugin2] _______ 134s 134s module = 'mkdocstrings.handlers.base' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.base' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s ____ test_render_themes_templates[mkdocstrings.handlers.rendering-plugin0] _____ 134s 134s module = 'mkdocstrings.handlers.rendering' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.rendering' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s ____ test_render_themes_templates[mkdocstrings.handlers.rendering-plugin1] _____ 134s 134s module = 'mkdocstrings.handlers.rendering' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.rendering' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s ____ test_render_themes_templates[mkdocstrings.handlers.rendering-plugin2] _____ 134s 134s module = 'mkdocstrings.handlers.rendering' 134s plugin = 134s 134s @pytest.mark.parametrize( 134s "plugin", 134s [ 134s {"theme": "mkdocs"}, 134s {"theme": "readthedocs"}, 134s {"theme": {"name": "material"}}, 134s ], 134s indirect=["plugin"], 134s ) 134s @pytest.mark.parametrize( 134s "module", 134s [ 134s "mkdocstrings.extension", 134s "mkdocstrings.inventory", 134s "mkdocstrings.loggers", 134s "mkdocstrings.handlers.base", 134s "mkdocstrings.handlers.rendering", 134s "mkdocstrings_handlers.python.handler", 134s "mkdocstrings_handlers.python.rendering", 134s ], 134s ) 134s def test_render_themes_templates(module: str, plugin: MkdocstringsPlugin) -> None: 134s """Test rendering of a given theme's templates. 134s 134s Parameters: 134s module: The module to load and render (parametrized). 134s plugin: The plugin instance (parametrized fixture). 134s """ 134s handler = plugin.handlers.get_handler("python") 134s handler._update_env(plugin.md, config=plugin.handlers._tool_config) # type: ignore[attr-defined] 134s options = handler.get_options({}) 134s > data = handler.collect(module, options) 134s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 134s 134s tests/test_themes.py:44: 134s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 134s 134s self = 134s identifier = 'mkdocstrings.handlers.rendering' 134s options = {'filters': ['!^_[^_]'], 'group_by_category': True, 'heading_level': 2, 'members_order': 'alphabetical', ...} 134s 134s def collect(self, identifier: str, options: MutableMapping[str, Any]) -> CollectorItem: 134s """Collect the documentation tree given an identifier and selection options. 134s 134s In this method, we feed one line of JSON to the standard input of the subprocess that was opened 134s during instantiation of the collector. Then we read one line of JSON on its standard output. 134s 134s We load back the JSON text into a Python dictionary. 134s If there is a decoding error, we log it as error and raise a CollectionError. 134s 134s If the dictionary contains an `error` key, we log it as error (with the optional `traceback` value), 134s and raise a CollectionError. 134s 134s If the dictionary values for keys `loading_errors` and `parsing_errors` are not empty, 134s we log them as warnings. 134s 134s Then we pick up the only object within the `objects` list (there's always only one, because we collect 134s them one by one), rebuild it's categories lists 134s (see [`rebuild_category_lists()`][mkdocstrings_handlers.python.rendering.rebuild_category_lists]), 134s and return it. 134s 134s Arguments: 134s identifier: The dotted-path of a Python object available in the Python path. 134s options: Selection options, used to alter the data collection done by `pytkdocs`. 134s 134s Raises: 134s CollectionError: When there was a problem collecting the object documentation. 134s 134s Returns: 134s The collected object-tree. 134s """ 134s pytkdocs_options = {} 134s for option in ("filters", "members", "docstring_style", "docstring_options"): 134s if option in options: 134s pytkdocs_options[option] = options[option] 134s 134s logger.debug("Preparing input") 134s json_input = json.dumps({"objects": [{"path": identifier, **pytkdocs_options}]}) 134s 134s logger.debug("Writing to process' stdin") 134s self.process.stdin.write(json_input + "\n") # type: ignore[union-attr] 134s self.process.stdin.flush() # type: ignore[union-attr] 134s 134s logger.debug("Reading process' stdout") 134s stdout = self.process.stdout.readline() # type: ignore[union-attr] 134s 134s logger.debug("Loading JSON output as Python object") 134s try: 134s result = json.loads(stdout) 134s except json.decoder.JSONDecodeError as exception: 134s error = "\n".join(("Error while loading JSON:", stdout, traceback.format_exc())) 134s raise CollectionError(error) from exception 134s 134s if "error" in result: 134s error = result["error"] 134s if "traceback" in result: 134s error += f"\n{result['traceback']}" 134s > raise CollectionError(error) 134s E mkdocstrings._internal.handlers.base.CollectionError: module 'mkdocstrings' has no attribute 'handlers' 134s E Traceback (most recent call last): 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 216, in main 134s E output = json.dumps(process_json(line)) 134s E ~~~~~~~~~~~~^^^^^^ 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 128, in process_json 134s E return process_config(json.loads(json_input)) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/cli.py", line 106, in process_config 134s E obj = loader.get_object_documentation(path, members) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 336, in get_object_documentation 134s E leaf = get_object_tree(dotted_path, self.new_path_syntax) 134s E File "/usr/lib/python3/dist-packages/pytkdocs/loader.py", line 265, in get_object_tree 134s E obj = getattr(current_node.obj, obj_name) 134s E AttributeError: module 'mkdocstrings' has no attribute 'handlers'. Did you mean: 'Handlers'? 134s 134s /usr/lib/python3/dist-packages/mkdocstrings_handlers/python/handler.py:293: CollectionError 134s =========================== short test summary info ============================ 134s FAILED tests/test_collector.py::test_collect_result_error[retval0-error1\nhello] 134s FAILED tests/test_collector.py::test_collect_result_error[retval1-error1] - T... 134s FAILED tests/test_collector.py::test_collect_result_error[retval2-\nhello] - ... 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin0] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin1] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.extension-plugin2] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin0] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin1] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.inventory-plugin2] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin0] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin1] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.loggers-plugin2] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin0] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin1] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.base-plugin2] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin0] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin1] 134s FAILED tests/test_themes.py::test_render_themes_templates[mkdocstrings.handlers.rendering-plugin2] 134s ========================= 18 failed, 7 passed in 3.13s ========================= 134s autopkgtest [17:10:04]: test upstream-tests: -----------------------] 135s autopkgtest [17:10:05]: test upstream-tests: - - - - - - - - - - results - - - - - - - - - - 135s upstream-tests FAIL non-zero exit status 1 135s autopkgtest [17:10:05]: @@@@@@@@@@@@@@@@@@@@ summary 135s upstream-tests FAIL non-zero exit status 1