0s autopkgtest [16:30:27]: starting date and time: 2024-11-13 16:30:27+0000 0s autopkgtest [16:30:27]: git checkout: 6f3be7a8 Fix armhf LXD image generation for plucky 0s autopkgtest [16:30:27]: host juju-7f2275-prod-proposed-migration-environment-20; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.c3lg990w/out --timeout-copy=6000 --setup-commands /home/ubuntu/autopkgtest-cloud/worker-config-production/setup-canonical.sh --apt-pocket=proposed=src:python3-defaults,src:python3-stdlib-extensions --apt-upgrade sqlalchemy-i18n --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 '--env=ADT_TEST_TRIGGERS=python3-defaults/3.12.7-1 python3-stdlib-extensions/3.12.7-1' -- ssh -s /home/ubuntu/autopkgtest/ssh-setup/nova -- --flavor autopkgtest-s390x --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-20@bos03-s390x-13.secgroup --name adt-plucky-s390x-sqlalchemy-i18n-20241113-163027-juju-7f2275-prod-proposed-migration-environment-20-d79e11fc-4cda-4528-9d60-85d21924a664 --image adt/ubuntu-plucky-s390x-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-20 --net-id=net_prod-proposed-migration-s390x -e TERM=linux -e ''"'"'http_proxy=http://squid.internal:3128'"'"'' -e ''"'"'https_proxy=http://squid.internal:3128'"'"'' -e ''"'"'no_proxy=127.0.0.1,127.0.1.1,login.ubuntu.com,localhost,localdomain,novalocal,internal,archive.ubuntu.com,ports.ubuntu.com,security.ubuntu.com,ddebs.ubuntu.com,changelogs.ubuntu.com,keyserver.ubuntu.com,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,10.24.0.0/24,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com'"'"'' --mirror=http://ftpmaster.internal/ubuntu/ 118s autopkgtest [16:32:25]: testbed dpkg architecture: s390x 118s autopkgtest [16:32:25]: testbed apt version: 2.9.8 118s autopkgtest [16:32:25]: @@@@@@@@@@@@@@@@@@@@ test bed setup 119s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [73.9 kB] 119s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/restricted Sources [7016 B] 119s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [104 kB] 120s Get:4 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [950 kB] 120s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [17.2 kB] 120s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x Packages [110 kB] 120s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/universe s390x Packages [636 kB] 120s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse s390x Packages [17.8 kB] 120s Fetched 1916 kB in 1s (2322 kB/s) 120s Reading package lists... 122s Reading package lists... 122s Building dependency tree... 122s Reading state information... 122s Calculating upgrade... 122s The following NEW packages will be installed: 122s python3.13-gdbm 122s The following packages will be upgraded: 122s libgnutls30t64 libgpgme11t64 libjson-glib-1.0-0 libjson-glib-1.0-common 122s libpython3-stdlib libutempter0 python3 python3-gdbm python3-minimal 122s 9 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 122s Need to get 1285 kB of archives. 122s After this operation, 103 kB of additional disk space will be used. 122s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x python3-minimal s390x 3.12.7-1 [27.4 kB] 123s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x python3 s390x 3.12.7-1 [24.0 kB] 123s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x libpython3-stdlib s390x 3.12.7-1 [10.0 kB] 123s Get:4 http://ftpmaster.internal/ubuntu plucky/main s390x libgnutls30t64 s390x 3.8.8-2ubuntu1 [950 kB] 123s Get:5 http://ftpmaster.internal/ubuntu plucky/main s390x python3.13-gdbm s390x 3.13.0-2 [31.0 kB] 123s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x python3-gdbm s390x 3.12.7-1 [8642 B] 123s Get:7 http://ftpmaster.internal/ubuntu plucky/main s390x libgpgme11t64 s390x 1.23.2-5ubuntu4 [151 kB] 123s Get:8 http://ftpmaster.internal/ubuntu plucky/main s390x libjson-glib-1.0-common all 1.10.0+ds-3 [5586 B] 123s Get:9 http://ftpmaster.internal/ubuntu plucky/main s390x libjson-glib-1.0-0 s390x 1.10.0+ds-3 [67.5 kB] 123s Get:10 http://ftpmaster.internal/ubuntu plucky/main s390x libutempter0 s390x 1.2.1-4 [9708 B] 123s Fetched 1285 kB in 1s (2362 kB/s) 123s (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 ... 55510 files and directories currently installed.) 123s Preparing to unpack .../python3-minimal_3.12.7-1_s390x.deb ... 123s Unpacking python3-minimal (3.12.7-1) over (3.12.6-0ubuntu1) ... 123s Setting up python3-minimal (3.12.7-1) ... 123s (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 ... 55510 files and directories currently installed.) 123s Preparing to unpack .../python3_3.12.7-1_s390x.deb ... 123s Unpacking python3 (3.12.7-1) over (3.12.6-0ubuntu1) ... 123s Preparing to unpack .../libpython3-stdlib_3.12.7-1_s390x.deb ... 123s Unpacking libpython3-stdlib:s390x (3.12.7-1) over (3.12.6-0ubuntu1) ... 123s Preparing to unpack .../libgnutls30t64_3.8.8-2ubuntu1_s390x.deb ... 123s Unpacking libgnutls30t64:s390x (3.8.8-2ubuntu1) over (3.8.6-2ubuntu1) ... 123s Setting up libgnutls30t64:s390x (3.8.8-2ubuntu1) ... 123s Selecting previously unselected package python3.13-gdbm. 123s (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 ... 55510 files and directories currently installed.) 123s Preparing to unpack .../0-python3.13-gdbm_3.13.0-2_s390x.deb ... 123s Unpacking python3.13-gdbm (3.13.0-2) ... 123s Preparing to unpack .../1-python3-gdbm_3.12.7-1_s390x.deb ... 123s Unpacking python3-gdbm:s390x (3.12.7-1) over (3.12.6-1ubuntu1) ... 124s Preparing to unpack .../2-libgpgme11t64_1.23.2-5ubuntu4_s390x.deb ... 124s Unpacking libgpgme11t64:s390x (1.23.2-5ubuntu4) over (1.18.0-4.1ubuntu4) ... 124s Preparing to unpack .../3-libjson-glib-1.0-common_1.10.0+ds-3_all.deb ... 124s Unpacking libjson-glib-1.0-common (1.10.0+ds-3) over (1.10.0+ds-2) ... 124s Preparing to unpack .../4-libjson-glib-1.0-0_1.10.0+ds-3_s390x.deb ... 124s Unpacking libjson-glib-1.0-0:s390x (1.10.0+ds-3) over (1.10.0+ds-2) ... 124s Preparing to unpack .../5-libutempter0_1.2.1-4_s390x.deb ... 124s Unpacking libutempter0:s390x (1.2.1-4) over (1.2.1-3build1) ... 124s Setting up libutempter0:s390x (1.2.1-4) ... 124s Setting up libjson-glib-1.0-common (1.10.0+ds-3) ... 124s Setting up libgpgme11t64:s390x (1.23.2-5ubuntu4) ... 124s Setting up python3.13-gdbm (3.13.0-2) ... 124s Setting up libpython3-stdlib:s390x (3.12.7-1) ... 124s Setting up python3 (3.12.7-1) ... 124s Setting up libjson-glib-1.0-0:s390x (1.10.0+ds-3) ... 124s Setting up python3-gdbm:s390x (3.12.7-1) ... 124s Processing triggers for man-db (2.12.1-3) ... 124s Processing triggers for libc-bin (2.40-1ubuntu3) ... 124s Reading package lists... 124s Building dependency tree... 124s Reading state information... 125s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 125s Hit:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease 125s Hit:2 http://ftpmaster.internal/ubuntu plucky InRelease 125s Hit:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease 125s Hit:4 http://ftpmaster.internal/ubuntu plucky-security InRelease 126s Reading package lists... 126s Reading package lists... 126s Building dependency tree... 126s Reading state information... 126s Calculating upgrade... 126s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 126s Reading package lists... 126s Building dependency tree... 126s Reading state information... 126s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 129s autopkgtest [16:32:36]: testbed running kernel: Linux 6.11.0-8-generic #8-Ubuntu SMP Mon Sep 16 12:49:35 UTC 2024 129s autopkgtest [16:32:36]: @@@@@@@@@@@@@@@@@@@@ apt-source sqlalchemy-i18n 130s Get:1 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (dsc) [2462 B] 130s Get:2 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (tar) [28.2 kB] 130s Get:3 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (diff) [4212 B] 130s gpgv: Signature made Wed Jan 18 23:54:36 2023 UTC 130s gpgv: using RSA key 439884E6862A429C290DF63B033C4CA276024834 130s gpgv: issuer "athos.ribeiro@canonical.com" 130s gpgv: Can't check signature: No public key 130s dpkg-source: warning: cannot verify inline signature for ./sqlalchemy-i18n_1.1.0-1build1.dsc: no acceptable signature found 130s autopkgtest [16:32:37]: testing package sqlalchemy-i18n version 1.1.0-1build1 131s autopkgtest [16:32:38]: build not needed 131s autopkgtest [16:32:38]: test setup-db-and-run-tests.py: preparing testbed 132s Reading package lists... 132s Building dependency tree... 132s Reading state information... 132s Starting pkgProblemResolver with broken count: 0 132s Starting 2 pkgProblemResolver with broken count: 0 132s Done 132s The following additional packages will be installed: 132s libjs-jquery libjs-sphinxdoc libjs-underscore libjson-perl libpq5 libxslt1.1 132s postgresql postgresql-16 postgresql-client-16 postgresql-client-common 132s postgresql-common python3-arrow python3-dateutil python3-greenlet 132s python3-iniconfig python3-packaging python3-pluggy python3-psycopg2 132s python3-pytest python3-six python3-sqlalchemy python3-sqlalchemy-i18n 132s python3-sqlalchemy-utils ssl-cert 132s Suggested packages: 132s postgresql-doc postgresql-doc-16 python-arrow-doc python-greenlet-dev 132s python-greenlet-doc python-psycopg2-doc python-sqlalchemy-doc 132s python3-asyncpg python3-pg8000 python3-psycopg2cffi python3-aiosqlite 132s python3-mariadb-connector python3-mysqldb python3-mysql.connector 132s python3-pyodbc python3-pymssql python3-cx-oracle python3-oracledb 132s python-sqlalchemy-utils-doc python3-infinity python3-intervals 132s Recommended packages: 132s javascript-common libjson-xs-perl python3-sqlalchemy-ext 132s The following NEW packages will be installed: 132s autopkgtest-satdep libjs-jquery libjs-sphinxdoc libjs-underscore 132s libjson-perl libpq5 libxslt1.1 postgresql postgresql-16 postgresql-client-16 132s postgresql-client-common postgresql-common python3-arrow python3-dateutil 132s python3-greenlet python3-iniconfig python3-packaging python3-pluggy 132s python3-psycopg2 python3-pytest python3-six python3-sqlalchemy 132s python3-sqlalchemy-i18n python3-sqlalchemy-utils ssl-cert 132s 0 upgraded, 25 newly installed, 0 to remove and 0 not upgraded. 132s Need to get 21.0 MB/21.0 MB of archives. 132s After this operation, 66.8 MB of additional disk space will be used. 132s Get:1 /tmp/autopkgtest.ucoxiZ/1-autopkgtest-satdep.deb autopkgtest-satdep s390x 0 [744 B] 133s Get:2 http://ftpmaster.internal/ubuntu plucky/main s390x libjson-perl all 4.10000-1 [81.9 kB] 133s Get:3 http://ftpmaster.internal/ubuntu plucky/main s390x postgresql-client-common all 262 [36.7 kB] 133s Get:4 http://ftpmaster.internal/ubuntu plucky/main s390x ssl-cert all 1.1.2ubuntu2 [18.0 kB] 133s Get:5 http://ftpmaster.internal/ubuntu plucky/main s390x postgresql-common all 262 [162 kB] 133s Get:6 http://ftpmaster.internal/ubuntu plucky/main s390x libjs-jquery all 3.6.1+dfsg+~3.5.14-1 [328 kB] 133s Get:7 http://ftpmaster.internal/ubuntu plucky/main s390x libjs-underscore all 1.13.4~dfsg+~1.11.4-3 [118 kB] 133s Get:8 http://ftpmaster.internal/ubuntu plucky/main s390x libjs-sphinxdoc all 7.4.7-4 [158 kB] 133s Get:9 http://ftpmaster.internal/ubuntu plucky/main s390x libpq5 s390x 17.0-1 [252 kB] 133s Get:10 http://ftpmaster.internal/ubuntu plucky/main s390x libxslt1.1 s390x 1.1.39-0exp1ubuntu1 [169 kB] 133s Get:11 http://ftpmaster.internal/ubuntu plucky/main s390x postgresql-client-16 s390x 16.4-3 [1294 kB] 133s Get:12 http://ftpmaster.internal/ubuntu plucky/main s390x postgresql-16 s390x 16.4-3 [16.3 MB] 134s Get:13 http://ftpmaster.internal/ubuntu plucky/main s390x postgresql all 16+262 [11.8 kB] 134s Get:14 http://ftpmaster.internal/ubuntu plucky/main s390x python3-six all 1.16.0-7 [13.1 kB] 134s Get:15 http://ftpmaster.internal/ubuntu plucky/main s390x python3-dateutil all 2.9.0-2 [80.3 kB] 134s Get:16 http://ftpmaster.internal/ubuntu plucky/main s390x python3-arrow all 1.3.0-1.1ubuntu1 [56.1 kB] 134s Get:17 http://ftpmaster.internal/ubuntu plucky/universe s390x python3-iniconfig all 1.1.1-2 [6024 B] 134s Get:18 http://ftpmaster.internal/ubuntu plucky/main s390x python3-packaging all 24.1-1 [41.4 kB] 134s Get:19 http://ftpmaster.internal/ubuntu plucky/universe s390x python3-pluggy all 1.5.0-1 [21.0 kB] 134s Get:20 http://ftpmaster.internal/ubuntu plucky/main s390x python3-psycopg2 s390x 2.9.9-2 [132 kB] 134s Get:21 http://ftpmaster.internal/ubuntu plucky/universe s390x python3-pytest all 8.3.3-1 [251 kB] 134s Get:22 http://ftpmaster.internal/ubuntu plucky/main s390x python3-greenlet s390x 3.0.3-0ubuntu6 [156 kB] 134s Get:23 http://ftpmaster.internal/ubuntu plucky/main s390x python3-sqlalchemy all 2.0.32+ds1-1ubuntu1 [1206 kB] 134s Get:24 http://ftpmaster.internal/ubuntu plucky/main s390x python3-sqlalchemy-utils all 0.41.1-0ubuntu1 [59.4 kB] 134s Get:25 http://ftpmaster.internal/ubuntu plucky/universe s390x python3-sqlalchemy-i18n all 1.1.0-1build1 [26.7 kB] 134s Preconfiguring packages ... 134s Fetched 21.0 MB in 1s (14.7 MB/s) 134s Selecting previously unselected package libjson-perl. 134s (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 ... 55517 files and directories currently installed.) 134s Preparing to unpack .../00-libjson-perl_4.10000-1_all.deb ... 134s Unpacking libjson-perl (4.10000-1) ... 134s Selecting previously unselected package postgresql-client-common. 134s Preparing to unpack .../01-postgresql-client-common_262_all.deb ... 134s Unpacking postgresql-client-common (262) ... 134s Selecting previously unselected package ssl-cert. 134s Preparing to unpack .../02-ssl-cert_1.1.2ubuntu2_all.deb ... 134s Unpacking ssl-cert (1.1.2ubuntu2) ... 134s Selecting previously unselected package postgresql-common. 134s Preparing to unpack .../03-postgresql-common_262_all.deb ... 134s Adding 'diversion of /usr/bin/pg_config to /usr/bin/pg_config.libpq-dev by postgresql-common' 134s Unpacking postgresql-common (262) ... 134s Selecting previously unselected package libjs-jquery. 134s Preparing to unpack .../04-libjs-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... 134s Unpacking libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 134s Selecting previously unselected package libjs-underscore. 134s Preparing to unpack .../05-libjs-underscore_1.13.4~dfsg+~1.11.4-3_all.deb ... 134s Unpacking libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... 134s Selecting previously unselected package libjs-sphinxdoc. 134s Preparing to unpack .../06-libjs-sphinxdoc_7.4.7-4_all.deb ... 134s Unpacking libjs-sphinxdoc (7.4.7-4) ... 134s Selecting previously unselected package libpq5:s390x. 134s Preparing to unpack .../07-libpq5_17.0-1_s390x.deb ... 134s Unpacking libpq5:s390x (17.0-1) ... 134s Selecting previously unselected package libxslt1.1:s390x. 134s Preparing to unpack .../08-libxslt1.1_1.1.39-0exp1ubuntu1_s390x.deb ... 134s Unpacking libxslt1.1:s390x (1.1.39-0exp1ubuntu1) ... 134s Selecting previously unselected package postgresql-client-16. 134s Preparing to unpack .../09-postgresql-client-16_16.4-3_s390x.deb ... 134s Unpacking postgresql-client-16 (16.4-3) ... 134s Selecting previously unselected package postgresql-16. 134s Preparing to unpack .../10-postgresql-16_16.4-3_s390x.deb ... 134s Unpacking postgresql-16 (16.4-3) ... 135s Selecting previously unselected package postgresql. 135s Preparing to unpack .../11-postgresql_16+262_all.deb ... 135s Unpacking postgresql (16+262) ... 135s Selecting previously unselected package python3-six. 135s Preparing to unpack .../12-python3-six_1.16.0-7_all.deb ... 135s Unpacking python3-six (1.16.0-7) ... 135s Selecting previously unselected package python3-dateutil. 135s Preparing to unpack .../13-python3-dateutil_2.9.0-2_all.deb ... 135s Unpacking python3-dateutil (2.9.0-2) ... 135s Selecting previously unselected package python3-arrow. 135s Preparing to unpack .../14-python3-arrow_1.3.0-1.1ubuntu1_all.deb ... 135s Unpacking python3-arrow (1.3.0-1.1ubuntu1) ... 135s Selecting previously unselected package python3-iniconfig. 135s Preparing to unpack .../15-python3-iniconfig_1.1.1-2_all.deb ... 135s Unpacking python3-iniconfig (1.1.1-2) ... 135s Selecting previously unselected package python3-packaging. 135s Preparing to unpack .../16-python3-packaging_24.1-1_all.deb ... 135s Unpacking python3-packaging (24.1-1) ... 135s Selecting previously unselected package python3-pluggy. 135s Preparing to unpack .../17-python3-pluggy_1.5.0-1_all.deb ... 135s Unpacking python3-pluggy (1.5.0-1) ... 135s Selecting previously unselected package python3-psycopg2. 135s Preparing to unpack .../18-python3-psycopg2_2.9.9-2_s390x.deb ... 135s Unpacking python3-psycopg2 (2.9.9-2) ... 135s Selecting previously unselected package python3-pytest. 135s Preparing to unpack .../19-python3-pytest_8.3.3-1_all.deb ... 135s Unpacking python3-pytest (8.3.3-1) ... 135s Selecting previously unselected package python3-greenlet. 135s Preparing to unpack .../20-python3-greenlet_3.0.3-0ubuntu6_s390x.deb ... 135s Unpacking python3-greenlet (3.0.3-0ubuntu6) ... 135s Selecting previously unselected package python3-sqlalchemy. 135s Preparing to unpack .../21-python3-sqlalchemy_2.0.32+ds1-1ubuntu1_all.deb ... 135s Unpacking python3-sqlalchemy (2.0.32+ds1-1ubuntu1) ... 135s Selecting previously unselected package python3-sqlalchemy-utils. 135s Preparing to unpack .../22-python3-sqlalchemy-utils_0.41.1-0ubuntu1_all.deb ... 135s Unpacking python3-sqlalchemy-utils (0.41.1-0ubuntu1) ... 135s Selecting previously unselected package python3-sqlalchemy-i18n. 135s Preparing to unpack .../23-python3-sqlalchemy-i18n_1.1.0-1build1_all.deb ... 135s Unpacking python3-sqlalchemy-i18n (1.1.0-1build1) ... 135s Selecting previously unselected package autopkgtest-satdep. 135s Preparing to unpack .../24-1-autopkgtest-satdep.deb ... 135s Unpacking autopkgtest-satdep (0) ... 135s Setting up postgresql-client-common (262) ... 135s Setting up python3-iniconfig (1.1.1-2) ... 135s Setting up libpq5:s390x (17.0-1) ... 135s Setting up python3-six (1.16.0-7) ... 135s Setting up python3-packaging (24.1-1) ... 135s Setting up ssl-cert (1.1.2ubuntu2) ... 135s Created symlink '/etc/systemd/system/multi-user.target.wants/ssl-cert.service' → '/usr/lib/systemd/system/ssl-cert.service'. 136s Setting up python3-greenlet (3.0.3-0ubuntu6) ... 136s Setting up python3-psycopg2 (2.9.9-2) ... 136s Setting up python3-pluggy (1.5.0-1) ... 136s Setting up libjson-perl (4.10000-1) ... 136s Setting up libxslt1.1:s390x (1.1.39-0exp1ubuntu1) ... 136s Setting up python3-dateutil (2.9.0-2) ... 136s Setting up libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 136s Setting up libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... 136s Setting up python3-arrow (1.3.0-1.1ubuntu1) ... 136s Setting up python3-pytest (8.3.3-1) ... 137s Setting up postgresql-client-16 (16.4-3) ... 137s update-alternatives: using /usr/share/postgresql/16/man/man1/psql.1.gz to provide /usr/share/man/man1/psql.1.gz (psql.1.gz) in auto mode 137s Setting up python3-sqlalchemy (2.0.32+ds1-1ubuntu1) ... 138s Setting up postgresql-common (262) ... 138s 138s Creating config file /etc/postgresql-common/createcluster.conf with new version 138s Building PostgreSQL dictionaries from installed myspell/hunspell packages... 138s Removing obsolete dictionary files: 139s Created symlink '/etc/systemd/system/multi-user.target.wants/postgresql.service' → '/usr/lib/systemd/system/postgresql.service'. 139s Setting up libjs-sphinxdoc (7.4.7-4) ... 139s Setting up python3-sqlalchemy-utils (0.41.1-0ubuntu1) ... 139s Setting up python3-sqlalchemy-i18n (1.1.0-1build1) ... 139s Setting up postgresql-16 (16.4-3) ... 140s Creating new PostgreSQL cluster 16/main ... 140s /usr/lib/postgresql/16/bin/initdb -D /var/lib/postgresql/16/main --auth-local peer --auth-host scram-sha-256 --no-instructions 140s The files belonging to this database system will be owned by user "postgres". 140s This user must also own the server process. 140s 140s The database cluster will be initialized with locale "C.UTF-8". 140s The default database encoding has accordingly been set to "UTF8". 140s The default text search configuration will be set to "english". 140s 140s Data page checksums are disabled. 140s 140s fixing permissions on existing directory /var/lib/postgresql/16/main ... ok 140s creating subdirectories ... ok 140s selecting dynamic shared memory implementation ... posix 140s selecting default max_connections ... 100 140s selecting default shared_buffers ... 128MB 140s selecting default time zone ... Etc/UTC 140s creating configuration files ... ok 140s running bootstrap script ... ok 140s performing post-bootstrap initialization ... ok 140s syncing data to disk ... ok 143s Setting up postgresql (16+262) ... 143s Setting up autopkgtest-satdep (0) ... 143s Processing triggers for man-db (2.12.1-3) ... 144s Processing triggers for libc-bin (2.40-1ubuntu3) ... 146s (Reading database ... 58301 files and directories currently installed.) 146s Removing autopkgtest-satdep (0) ... 146s autopkgtest [16:32:53]: test setup-db-and-run-tests.py: [----------------------- 146s The files belonging to this database system will be owned by user "ubuntu". 146s This user must also own the server process. 146s 146s The database cluster will be initialized with this locale configuration: 146s provider: libc 146s LC_COLLATE: C.UTF-8 146s LC_CTYPE: C.UTF-8 146s LC_MESSAGES: C 146s LC_MONETARY: C.UTF-8 146s LC_NUMERIC: C.UTF-8 146s LC_TIME: C.UTF-8 146s The default database encoding has accordingly been set to "UTF8". 146s The default text search configuration will be set to "english". 146s 146s Data page checksums are disabled. 146s 146s creating directory /tmp/tmpg1radjtp/data ... ok 146s creating subdirectories ... ok 146s selecting dynamic shared memory implementation ... posix 146s selecting default max_connections ... 100 146s selecting default shared_buffers ... 128MB 146s selecting default time zone ... Etc/UTC 146s creating configuration files ... ok 147s running bootstrap script ... ok 147s performing post-bootstrap initialization ... ok 147s syncing data to disk ... ok 147s 147s Success. You can now start the database server using: 147s 147s /usr/lib/postgresql/16/bin/pg_ctl -D /tmp/tmpg1radjtp/data -l logfile start 147s 147s 2024-11-13 16:32:54.316 UTC [4477] LOG: starting PostgreSQL 16.4 (Ubuntu 16.4-3) on s390x-ibm-linux-gnu, compiled by gcc (Ubuntu 14.2.0-7ubuntu1) 14.2.0, 64-bit 147s 2024-11-13 16:32:54.316 UTC [4477] LOG: listening on IPv6 address "::1", port 46021 147s 2024-11-13 16:32:54.316 UTC [4477] LOG: listening on IPv4 address "127.0.0.1", port 46021 147s 2024-11-13 16:32:54.316 UTC [4477] LOG: listening on Unix socket "/tmp/tmpg1radjtp/tmp/.s.PGSQL.46021" 147s 2024-11-13 16:32:54.318 UTC [4480] LOG: database system was shut down at 2024-11-13 16:32:54 UTC 147s 2024-11-13 16:32:54.320 UTC [4477] LOG: database system is ready to accept connections 147s running initdb 147s starting server 147s ============================= test session starts ============================== 147s platform linux -- Python 3.12.7, pytest-8.3.3, pluggy-1.5.0 147s rootdir: /tmp/autopkgtest.ucoxiZ/build.ReG/src 147s plugins: typeguard-4.4.1 147s collected 119 items 147s 148s tests/test_common_base_class.py EE [ 1%] 148s tests/test_comparator.py EEEE [ 5%] 148s tests/test_composite_primary_key.py EE [ 6%] 149s tests/test_configuration.py EE [ 8%] 150s tests/test_current_translation_property.py EEEEEE [ 13%] 150s tests/test_current_translation_property_with_locale.py EE [ 15%] 150s tests/test_custom_base_class.py E [ 15%] 150s tests/test_expressions.py . [ 16%] 150s tests/test_fallback_locale_as_callable.py EEEE [ 20%] 151s tests/test_fallback_locale_without_class_default.py EEEE [ 23%] 152s tests/test_fallback_translation.py EEEEEE [ 28%] 152s tests/test_find_translations.py EEEE [ 31%] 152s tests/test_hybrid_property_as_dynamic_source_locale.py EE [ 33%] 153s tests/test_hybrid_property_exclusion.py FE [ 35%] 153s tests/test_join_expressions.py EEEEEEEE [ 42%] 155s tests/test_joined_loading.py EEEEEEEEEE [ 50%] 157s tests/test_joined_table_inheritance.py EEEEEEEEEEEEEEEE [ 63%] 157s tests/test_property_collision.py . [ 64%] 157s tests/test_relationships.py EE [ 66%] 159s tests/test_translatable.py EEEEEEEEEEEEEEEE [ 79%] 159s tests/test_translation_auto_creation.py EE [ 81%] 159s tests/test_translation_auto_creation_with_non_nullables.py EE [ 83%] 160s tests/test_translation_mapping.py EEEE2024-11-13 16:33:07.757 UTC [4587] FATAL: sorry, too many clients already 161s E2024-11-13 16:33:08.012 UTC [4588] FATAL: sorry, too many clients already 161s E2024-11-13 16:33:08.276 UTC [4589] FATAL: sorry, too many clients already 161s E2024-11-13 16:33:08.524 UTC [4590] FATAL: sorry, too many clients already 161s E2024-11-13 16:33:08.777 UTC [4591] FATAL: sorry, too many clients already 162s E2024-11-13 16:33:09.016 UTC [4592] FATAL: sorry, too many clients already 162s E2024-11-13 16:33:09.259 UTC [4593] FATAL: sorry, too many clients already 162s E2024-11-13 16:33:09.506 UTC [4594] FATAL: sorry, too many clients already 162s E2024-11-13 16:33:09.751 UTC [4595] FATAL: sorry, too many clients already 163s E2024-11-13 16:33:10.004 UTC [4596] FATAL: sorry, too many clients already 163s E2024-11-13 16:33:10.258 UTC [4597] FATAL: sorry, too many clients already 163s E2024-11-13 16:33:10.577 UTC [4598] FATAL: sorry, too many clients already 163s E2024-11-13 16:33:10.822 UTC [4599] FATAL: sorry, too many clients already 164s E2024-11-13 16:33:11.073 UTC [4600] FATAL: sorry, too many clients already 164s E2024-11-13 16:33:11.310 UTC [4601] FATAL: sorry, too many clients already 164s E2024-11-13 16:33:11.556 UTC [4602] FATAL: sorry, too many clients already 164s E [100%] 164s 164s ==================================== ERRORS ==================================== 164s _ ERROR at setup of TestDeclarative.test_translatable_dict_copied_to_each_child_class _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'TextItem' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _ ERROR at setup of TestClassic.test_translatable_dict_copied_to_each_child_class _ 164s 164s self = 164s 164s def create_mappers(self): 164s > sa.orm.mapper(self.TextItem, self.textitems) 164s 164s tests/test_common_base_class.py:105: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.TextItem'>, Table('textitems', MetaData(), Column('id', Integer(), table=, primary_key=True, nullable=False), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _ ERROR at setup of TestDeclarative.test_attribute_accessor_for_unknown_locale _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s __________ ERROR at setup of TestDeclarative.test_attribute_accessors __________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ___ ERROR at setup of TestClassic.test_attribute_accessor_for_unknown_locale ___ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s ____________ ERROR at setup of TestClassic.test_attribute_accessors ____________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _____________ ERROR at setup of TestDeclarative.test_relationships _____________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _______________ ERROR at setup of TestClassic.test_relationships _______________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), C...y_key=True, nullable=False), Column('id2', Integer(), table=
, primary_key=True, nullable=False), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _ ERROR at setup of TestTranslationBaseCustomization.test_customize_foreign_key_args _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _ ERROR at setup of TestTranslationBaseCustomization.test_customize_relationships_args _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s __________ ERROR at setup of TestDeclarative.test_as_object_property ___________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ___________ ERROR at setup of TestDeclarative.test_as_class_property ___________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ________________ ERROR at setup of TestDeclarative.test_setter _________________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ____________ ERROR at setup of TestClassic.test_as_object_property _____________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _____________ ERROR at setup of TestClassic.test_as_class_property _____________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s __________________ ERROR at setup of TestClassic.test_setter ___________________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s ___ ERROR at setup of TestDeclarative.test_converts_locale_object_to_unicode ___ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _____ ERROR at setup of TestClassic.test_converts_locale_object_to_unicode _____ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('arti...able=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _ ERROR at setup of TestDeclarative.test_translatable_dict_copied_to_each_child_class _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _ ERROR at setup of TestDeclarative.test_hybrid_properties_support_callable_fallback_locales _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ____________ ERROR at setup of TestDeclarative.test_locale_fallback ____________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _ ERROR at setup of TestClassic.test_hybrid_properties_support_callable_fallback_locales _ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaDat...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s ______________ ERROR at setup of TestClassic.test_locale_fallback ______________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article', MetaDat...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _ ERROR at setup of TestDeclarative.test_hybrid_properties_support_callable_fallback_locales _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s ____________ ERROR at setup of TestDeclarative.test_locale_fallback ____________ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 164s > raise UnknownLocaleError(locale, class_) 164s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 164s 164s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 164s _ ERROR at setup of TestClassic.test_hybrid_properties_support_callable_fallback_locales _ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s ______________ ERROR at setup of TestClassic.test_locale_fallback ______________ 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.metadata = sa.MetaData() 164s 164s self.engine = sa.create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s 164s self.create_tables() 164s self.create_models() 164s > self.create_mappers() 164s 164s tests/__init__.py:140: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s tests/__init__.py:213: in create_mappers 164s sa.orm.mapper(self.Article, self.article) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s arg = (.Article'>, Table('article...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 164s kw = {} 164s 164s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 164s """Placeholder for the now-removed ``mapper()`` function. 164s 164s Classical mappings should be performed using the 164s :meth:`_orm.registry.map_imperatively` method. 164s 164s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 164s of using the ``mapper()`` function as a target for ORM event listeners, 164s which failed to be marked as deprecated in the 1.4 series. 164s 164s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 164s class as the target. 164s 164s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 164s symbol remains temporarily as a placeholder for the event listening 164s use case. 164s 164s """ 164s > raise InvalidRequestError( 164s "The 'sqlalchemy.orm.mapper()' function is removed as of " 164s "SQLAlchemy 2.0. Use the " 164s "'sqlalchemy.orm.registry.map_imperatively()` " 164s "method of the ``sqlalchemy.orm.registry`` class to perform " 164s "classical mapping." 164s ) 164s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 164s 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 164s _ ERROR at setup of TestDeclarative.test_as_object_property_with_force_locale __ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s > return getattr(class_, '_translation_%s' % locale) 164s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 164s 164s sqlalchemy_i18n/comparators.py:13: AttributeError 164s 164s During handling of the above exception, another exception occurred: 164s 164s self = 164s method = > 164s 164s def setup_method(self, method): 164s self.engine = create_engine(self.engine_uri) 164s # self.engine.echo = True 164s self.connection = self.engine.connect() 164s self.connection.query_count = 0 164s self.Model = declarative_base() 164s 164s self.create_models() 164s 164s if self.configure_mappers: 164s > sa.orm.configure_mappers() 164s 164s tests/__init__.py:57: 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 164s _configure_registries(_all_registries(), cascade=True) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 164s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 164s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 164s fn(*args, **kw) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 164s fn(*arg, **kw) 164s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 164s RelationshipBuilder(self, cls)() 164s sqlalchemy_i18n/builders.py:228: in __call__ 164s self.assign_translations() 164s sqlalchemy_i18n/builders.py:186: in assign_translations 164s mapper.add_property('_translations', sa.orm.relationship( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 164s prop = self._configure_property( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 164s prop.post_instrument_class(self) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 164s self.strategy.init_class_attribute(mapper) 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 164s _register_attribute( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 164s desc = attributes.register_attribute_impl( 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 164s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 164s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 164s if hasattr(obj, "_slots_dispatch"): 164s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 164s return getattr(self.comparator, key) 164s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 164s 164s self = 164s locale = '_slots_dispatch' 164s 164s def __getattr__(self, locale): 164s class_ = self._parentmapper.class_ 164s try: 164s return getattr(class_, '_translation_%s' % locale) 164s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___________ ERROR at setup of TestDeclarative.test_as_class_property ___________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ________________ ERROR at setup of TestDeclarative.test_setter _________________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___ ERROR at setup of TestClassic.test_as_object_property_with_force_locale ____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _____________ ERROR at setup of TestClassic.test_as_class_property _____________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __________________ ERROR at setup of TestClassic.test_setter ___________________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _________ ERROR at setup of TestDeclarative.test_with_full_confidence __________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ________ ERROR at setup of TestDeclarative.test_with_varying_confidence ________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi', 'sv'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___________ ERROR at setup of TestClassic.test_with_full_confidence ____________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __________ ERROR at setup of TestClassic.test_with_varying_confidence __________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __ ERROR at setup of TestDeclarative.test_joinedload_for_current_translation ___ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_hybrid_property_as_dynamic_source_locale.py:25: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi', 'sv'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ____ ERROR at setup of TestClassic.test_joinedload_for_current_translation _____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_hybrid_property_as_dynamic_source_locale.py:61: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('arti...
), Column('_locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____ ERROR at setup of TestClassic.test_does_not_generate_hybrid_properties ____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(...e=
, default=ScalarElementColumnDefault('en')), Column('word_count', Integer(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ___ ERROR at setup of TestDeclarative.test_current_translation_as_expression ___ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _________ ERROR at setup of TestDeclarative.test_order_by_translation __________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _____ ERROR at setup of TestDeclarative.test_fallback_locale_as_expression _____ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _______________ ERROR at setup of TestDeclarative.test_querying ________________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _____ ERROR at setup of TestClassic.test_current_translation_as_expression _____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ___________ ERROR at setup of TestClassic.test_order_by_translation ____________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _______ ERROR at setup of TestClassic.test_fallback_locale_as_expression _______ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _________________ ERROR at setup of TestClassic.test_querying __________________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __ ERROR at setup of TestDeclarative.test_joinedload_for_current_translation ___ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:59: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _ ERROR at setup of TestDeclarative.test_contains_eager_for_current_translation _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:59: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___ ERROR at setup of TestDeclarative.test_joinedload_for_single_translation ___ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:59: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _____ ERROR at setup of TestDeclarative.test_joinedload_for_attr_accessor ______ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:59: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ____ ERROR at setup of TestDeclarative.test_joinedload_for_all_translations ____ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:59: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ____ ERROR at setup of TestClassic.test_joinedload_for_current_translation _____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:71: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __ ERROR at setup of TestClassic.test_contains_eager_for_current_translation ___ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:71: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _____ ERROR at setup of TestClassic.test_joinedload_for_single_translation _____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:71: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _______ ERROR at setup of TestClassic.test_joinedload_for_attr_accessor ________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:71: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ______ ERROR at setup of TestClassic.test_joinedload_for_all_translations ______ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_joined_loading.py:71: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ________ ERROR at setup of TestDeclarative.test_auto_creates_relations _________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___ ERROR at setup of TestDeclarative.test_auto_creates_current_translation ____ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ________ ERROR at setup of TestDeclarative.test_translatable_attributes ________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _______ ERROR at setup of TestDeclarative.test_inherits_child_properties _______ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestDeclarative.test_translated_columns ___________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestDeclarative.test_property_delegators __________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ______________ ERROR at setup of TestDeclarative.test_table_name _______________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _________ ERROR at setup of TestDeclarative.test_inherits_parent_table _________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestClassic.test_auto_creates_relations ___________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _____ ERROR at setup of TestClassic.test_auto_creates_current_translation ______ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __________ ERROR at setup of TestClassic.test_translatable_attributes __________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _________ ERROR at setup of TestClassic.test_inherits_child_properties _________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____________ ERROR at setup of TestClassic.test_translated_columns _____________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____________ ERROR at setup of TestClassic.test_property_delegators ____________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ________________ ERROR at setup of TestClassic.test_table_name _________________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ___________ ERROR at setup of TestClassic.test_inherits_parent_table ___________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.TextItem, self.text_item, 165s polymorphic_on=self.text_item.c.discriminator) 165s 165s tests/test_joined_table_inheritance.py:155: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ___________ ERROR at setup of TestDeclarative.test_nullify_relation ____________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Category' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _____________ ERROR at setup of TestClassic.test_nullify_relation ______________ 165s 165s self = 165s 165s def create_mappers(self): 165s > sa.orm.mapper(self.Article, self.article) 165s 165s tests/test_relationships.py:101: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('i...), table=
, primary_key=True, nullable=False), Column('content', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ________ ERROR at setup of TestDeclarative.test_auto_creates_relations _________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ________ ERROR at setup of TestDeclarative.test_translatable_attributes ________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _______ ERROR at setup of TestDeclarative.test_relationship_consistency ________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestDeclarative.test_property_delegators __________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ____________ ERROR at setup of TestDeclarative.test_commit_session _____________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ________________ ERROR at setup of TestDeclarative.test_delete _________________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestDeclarative.test_translated_columns ___________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _ ERROR at setup of TestDeclarative.test_appends_locale_column_to_translation_table _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestClassic.test_auto_creates_relations ___________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __________ ERROR at setup of TestClassic.test_translatable_attributes __________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _________ ERROR at setup of TestClassic.test_relationship_consistency __________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____________ ERROR at setup of TestClassic.test_property_delegators ____________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ______________ ERROR at setup of TestClassic.test_commit_session _______________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s __________________ ERROR at setup of TestClassic.test_delete ___________________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____________ ERROR at setup of TestClassic.test_translated_columns _____________ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _ ERROR at setup of TestClassic.test_appends_locale_column_to_translation_table _ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s 165s self.create_tables() 165s self.create_models() 165s > self.create_mappers() 165s 165s tests/__init__.py:140: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ___ ERROR at setup of TestDeclarative.test_auto_creates_translation_objects ____ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_translation_auto_creation.py:21: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _____ ERROR at setup of TestClassic.test_auto_creates_translation_objects ______ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_translation_auto_creation.py:31: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/__init__.py:213: in create_mappers 165s sa.orm.mapper(self.Article, self.article) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 165s kw = {} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s _ ERROR at setup of TestDeclarative.test_auto_sets_nullables_as_empty_strings __ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'ExtendedArticle' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > DeclarativeTestCase.setup_method(self, method) 165s 165s tests/test_translation_auto_creation_with_non_nullables.py:26: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:57: in setup_method 165s sa.orm.configure_mappers() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 165s mapper._adapt_inherited_property(key, prop, init) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 165s self._configure_property(key, prop, init=False, setparent=False) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 165s prop.instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 165s attributes.register_descriptor( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 165s descriptor = InstrumentedAttribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 165s self.dispatch._update(base[key].dispatch) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s ___ ERROR at setup of TestClassic.test_auto_sets_nullables_as_empty_strings ____ 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s > ClassicTestCase.setup_method(self, method) 165s 165s tests/test_translation_auto_creation_with_non_nullables.py:75: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s tests/__init__.py:140: in setup_method 165s self.create_mappers() 165s tests/test_translation_auto_creation_with_non_nullables.py:135: in create_mappers 165s sa.orm.mapper(self.Article, self.article, 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s arg = (.Article'>, Table('...ription', UnicodeText(), table=
), Column('discriminator', Unicode(length=255), table=
), schema=None)) 165s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=
)} 165s 165s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 165s """Placeholder for the now-removed ``mapper()`` function. 165s 165s Classical mappings should be performed using the 165s :meth:`_orm.registry.map_imperatively` method. 165s 165s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 165s of using the ``mapper()`` function as a target for ORM event listeners, 165s which failed to be marked as deprecated in the 1.4 series. 165s 165s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 165s class as the target. 165s 165s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 165s symbol remains temporarily as a placeholder for the event listening 165s use case. 165s 165s """ 165s > raise InvalidRequestError( 165s "The 'sqlalchemy.orm.mapper()' function is removed as of " 165s "SQLAlchemy 2.0. Use the " 165s "'sqlalchemy.orm.registry.map_imperatively()` " 165s "method of the ``sqlalchemy.orm.registry`` class to perform " 165s "classical mapping." 165s ) 165s E sqlalchemy.exc.InvalidRequestError: The 'sqlalchemy.orm.mapper()' function is removed as of SQLAlchemy 2.0. Use the 'sqlalchemy.orm.registry.map_imperatively()` method of the ``sqlalchemy.orm.registry`` class to perform classical mapping. 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 165s ____________ ERROR at setup of TestDeclarative.test_proxy_contains _____________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _ ERROR at setup of TestDeclarative.test_translation_mapping_attribute_getter __ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _ ERROR at setup of TestDeclarative.test_attribute_accessor_for_unknown_locale _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s __________ ERROR at setup of TestDeclarative.test_proxy_not_contains ___________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s self.connection = self.engine.connect() 165s self.connection.query_count = 0 165s self.Model = declarative_base() 165s 165s self.create_models() 165s 165s if self.configure_mappers: 165s > sa.orm.configure_mappers() 165s 165s tests/__init__.py:57: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 165s _configure_registries(_all_registries(), cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s _________________ ERROR at setup of TestDeclarative.test_items _________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _______________ ERROR at setup of TestDeclarative.test_iteritems _______________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _______________ ERROR at setup of TestDeclarative.test_set_item ________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _________________ ERROR at setup of TestDeclarative.test_repr __________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _________________ ERROR at setup of TestDeclarative.test_iter __________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ________________ ERROR at setup of TestDeclarative.test_values _________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.engine = create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:50: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ______________ ERROR at setup of TestClassic.test_proxy_contains _______________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ___ ERROR at setup of TestClassic.test_translation_mapping_attribute_getter ____ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ___ ERROR at setup of TestClassic.test_attribute_accessor_for_unknown_locale ___ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ____________ ERROR at setup of TestClassic.test_proxy_not_contains _____________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ___________________ ERROR at setup of TestClassic.test_items ___________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _________________ ERROR at setup of TestClassic.test_iteritems _________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s _________________ ERROR at setup of TestClassic.test_set_item __________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ___________________ ERROR at setup of TestClassic.test_repr ____________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s ___________________ ERROR at setup of TestClassic.test_iter ____________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s __________________ ERROR at setup of TestClassic.test_values ___________________ 165s 165s self = 165s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 165s connection = None, _has_events = None, _allow_revalidate = True 165s _allow_autobegin = True 165s 165s def __init__( 165s self, 165s engine: Engine, 165s connection: Optional[PoolProxiedConnection] = None, 165s _has_events: Optional[bool] = None, 165s _allow_revalidate: bool = True, 165s _allow_autobegin: bool = True, 165s ): 165s """Construct a new Connection.""" 165s self.engine = engine 165s self.dialect = dialect = engine.dialect 165s 165s if connection is None: 165s try: 165s > self._dbapi_connection = engine.raw_connection() 165s 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s 165s The above exception was the direct cause of the following exception: 165s 165s self = 165s method = > 165s 165s def setup_method(self, method): 165s self.metadata = sa.MetaData() 165s 165s self.engine = sa.create_engine(self.engine_uri) 165s # self.engine.echo = True 165s > self.connection = self.engine.connect() 165s 165s tests/__init__.py:135: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 165s return self._connection_cls(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 165s Connection._handle_dbapi_exception_noconnection( 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 165s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 165s self._dbapi_connection = engine.raw_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 165s return self.pool.connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 165s return _ConnectionFairy._checkout(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 165s fairy = _ConnectionRecord.checkout(pool) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 165s rec = pool._do_get() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 165s return self._create_connection() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 165s return _ConnectionRecord(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 165s self.__connect() 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 165s with util.safe_reraise(): 165s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 165s raise exc_value.with_traceback(exc_tb) 165s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 165s self.dbapi_connection = connection = pool._invoke_creator(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 165s return dialect.connect(*cargs, **cparams) 165s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 165s return self.loaded_dbapi.connect(*cargs, **cparams) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 165s connection_factory = None, cursor_factory = None 165s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 165s kwasync = {} 165s 165s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 165s """ 165s Create a new database connection. 165s 165s The connection parameters can be specified as a string: 165s 165s conn = psycopg2.connect("dbname=test user=postgres password=secret") 165s 165s or using a set of keyword arguments: 165s 165s conn = psycopg2.connect(database="test", user="postgres", password="secret") 165s 165s Or as a mix of both. The basic connection parameters are: 165s 165s - *dbname*: the database name 165s - *database*: the database name (only as keyword argument) 165s - *user*: user name used to authenticate 165s - *password*: password used to authenticate 165s - *host*: database host address (defaults to UNIX socket if not provided) 165s - *port*: connection port number (defaults to 5432 if not provided) 165s 165s Using the *connection_factory* parameter a different class or connections 165s factory can be specified. It should be a callable object taking a dsn 165s argument. 165s 165s Using the *cursor_factory* parameter, a new default cursor factory will be 165s used by cursor(). 165s 165s Using *async*=True an asynchronous connection will be created. *async_* is 165s a valid alias (for Python versions where ``async`` is a keyword). 165s 165s Any other keyword parameter will be passed to the underlying client 165s library: the list of supported parameters depends on the library version. 165s 165s """ 165s kwasync = {} 165s if 'async' in kwargs: 165s kwasync['async'] = kwargs.pop('async') 165s if 'async_' in kwargs: 165s kwasync['async_'] = kwargs.pop('async_') 165s 165s dsn = _ext.make_dsn(dsn, **kwargs) 165s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 165s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46021 failed: FATAL: sorry, too many clients already 165s E 165s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 165s 165s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 165s =================================== FAILURES =================================== 165s ___________ TestDeclarative.test_does_not_generate_hybrid_properties ___________ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s > return getattr(class_, '_translation_%s' % locale) 165s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 165s 165s sqlalchemy_i18n/comparators.py:13: AttributeError 165s 165s During handling of the above exception, another exception occurred: 165s 165s self = 165s 165s def test_does_not_generate_hybrid_properties(self): 165s > self.Article() 165s 165s tests/test_hybrid_property_exclusion.py:15: 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s :4: in __init__ 165s ??? 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/state.py:566: in _initialize_instance 165s manager.dispatch.init(self, args, kwargs) 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:497: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4396: in _event_on_init 165s instrumenting_mapper._check_configure() 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2388: in _check_configure 165s _configure_registries({self.registry}, cascade=True) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 165s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 165s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 165s fn(*args, **kw) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 165s fn(*arg, **kw) 165s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 165s RelationshipBuilder(self, cls)() 165s sqlalchemy_i18n/builders.py:228: in __call__ 165s self.assign_translations() 165s sqlalchemy_i18n/builders.py:186: in assign_translations 165s mapper.add_property('_translations', sa.orm.relationship( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 165s prop = self._configure_property( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 165s prop.post_instrument_class(self) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 165s self.strategy.init_class_attribute(mapper) 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 165s _register_attribute( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 165s desc = attributes.register_attribute_impl( 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 165s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 165s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 165s if hasattr(obj, "_slots_dispatch"): 165s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 165s return getattr(self.comparator, key) 165s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 165s 165s self = 165s locale = '_slots_dispatch' 165s 165s def __getattr__(self, locale): 165s class_ = self._parentmapper.class_ 165s try: 165s return getattr(class_, '_translation_%s' % locale) 165s except AttributeError: 165s > raise UnknownLocaleError(locale, class_) 165s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 165s 165s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 165s =============================== warnings summary =============================== 165s sqlalchemy_i18n/translatable.py:62 165s /tmp/autopkgtest.ucoxiZ/build.ReG/src/sqlalchemy_i18n/translatable.py:62: SADeprecationWarning: The `sqlalchemy.orm.mapper()` symbol is deprecated and will be removed in a future release. For the mapper-wide event target, use the 'sqlalchemy.orm.Mapper' class. 165s @sa.event.listens_for(sa.orm.mapper, 'expire') 165s 165s sqlalchemy_i18n/__init__.py:41 165s /tmp/autopkgtest.ucoxiZ/build.ReG/src/sqlalchemy_i18n/__init__.py:41: SADeprecationWarning: The `sqlalchemy.orm.mapper()` symbol is deprecated and will be removed in a future release. For the mapper-wide event target, use the 'sqlalchemy.orm.Mapper' class. 165s sa.event.listen( 165s 165s sqlalchemy_i18n/__init__.py:44 165s /tmp/autopkgtest.ucoxiZ/build.ReG/src/sqlalchemy_i18n/__init__.py:44: SADeprecationWarning: The `sqlalchemy.orm.mapper()` symbol is deprecated and will be removed in a future release. For the mapper-wide event target, use the 'sqlalchemy.orm.Mapper' class. 165s sa.event.listen( 165s 165s tests/test_common_base_class.py: 1 warning 165s tests/test_comparator.py: 2 warnings 165s tests/test_composite_primary_key.py: 1 warning 165s tests/test_configuration.py: 2 warnings 165s tests/test_current_translation_property.py: 3 warnings 165s tests/test_current_translation_property_with_locale.py: 1 warning 165s tests/test_custom_base_class.py: 1 warning 165s tests/test_fallback_locale_as_callable.py: 2 warnings 165s tests/test_fallback_locale_without_class_default.py: 2 warnings 165s tests/test_fallback_translation.py: 3 warnings 165s tests/test_find_translations.py: 2 warnings 165s tests/test_hybrid_property_as_dynamic_source_locale.py: 1 warning 165s tests/test_hybrid_property_exclusion.py: 1 warning 165s tests/test_join_expressions.py: 4 warnings 165s tests/test_joined_loading.py: 5 warnings 165s tests/test_joined_table_inheritance.py: 8 warnings 165s tests/test_property_collision.py: 1 warning 165s tests/test_relationships.py: 1 warning 165s tests/test_translatable.py: 8 warnings 165s tests/test_translation_auto_creation.py: 1 warning 165s tests/test_translation_auto_creation_with_non_nullables.py: 1 warning 165s tests/test_translation_mapping.py: 4 warnings 165s /tmp/autopkgtest.ucoxiZ/build.ReG/src/tests/__init__.py:52: MovedIn20Warning: The ``declarative_base()`` function is now available as sqlalchemy.orm.declarative_base(). (deprecated since: 2.0) (Background on SQLAlchemy 2.0 at: https://sqlalche.me/e/b8d9) 165s self.Model = declarative_base() 165s 165s tests/test_common_base_class.py: 2 warnings 165s tests/test_comparator.py: 2 warnings 165s tests/test_composite_primary_key.py: 1 warning 165s tests/test_configuration.py: 2 warnings 165s tests/test_current_translation_property.py: 3 warnings 165s tests/test_current_translation_property_with_locale.py: 1 warning 165s tests/test_custom_base_class.py: 1 warning 165s tests/test_fallback_locale_as_callable.py: 2 warnings 165s tests/test_fallback_locale_without_class_default.py: 2 warnings 165s tests/test_fallback_translation.py: 3 warnings 165s tests/test_find_translations.py: 2 warnings 165s tests/test_hybrid_property_as_dynamic_source_locale.py: 1 warning 165s tests/test_hybrid_property_exclusion.py: 1 warning 165s tests/test_join_expressions.py: 4 warnings 165s tests/test_joined_loading.py: 5 warnings 165s tests/test_joined_table_inheritance.py: 8 warnings 165s tests/test_property_collision.py: 1 warning 165s tests/test_relationships.py: 1 warning 165s tests/test_translatable.py: 8 warnings 165s tests/test_translation_auto_creation.py: 1 warning 165s tests/test_translation_auto_creation_with_non_nullables.py: 1 warning 165s tests/test_translation_mapping.py: 4 warnings 165s /tmp/autopkgtest.ucoxiZ/build.ReG/src/sqlalchemy_i18n/manager.py:36: MovedIn20Warning: The ``has_inherited_table()`` function is now available as sqlalchemy.orm.has_inherited_table(). (deprecated since: 2.0) (Background on SQLAlchemy 2.0 at: https://sqlalche.me/e/b8d9) 165s if has_inherited_table(cls): 165s 165s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 165s =========================== short test summary info ============================ 165s FAILED tests/test_hybrid_property_exclusion.py::TestDeclarative::test_does_not_generate_hybrid_properties 165s ERROR tests/test_common_base_class.py::TestDeclarative::test_translatable_dict_copied_to_each_child_class 165s ERROR tests/test_common_base_class.py::TestClassic::test_translatable_dict_copied_to_each_child_class 165s ERROR tests/test_comparator.py::TestDeclarative::test_attribute_accessor_for_unknown_locale 165s ERROR tests/test_comparator.py::TestDeclarative::test_attribute_accessors - s... 165s ERROR tests/test_comparator.py::TestClassic::test_attribute_accessor_for_unknown_locale 165s ERROR tests/test_comparator.py::TestClassic::test_attribute_accessors - sqlal... 165s ERROR tests/test_composite_primary_key.py::TestDeclarative::test_relationships 165s ERROR tests/test_composite_primary_key.py::TestClassic::test_relationships - ... 165s ERROR tests/test_configuration.py::TestTranslationBaseCustomization::test_customize_foreign_key_args 165s ERROR tests/test_configuration.py::TestTranslationBaseCustomization::test_customize_relationships_args 165s ERROR tests/test_current_translation_property.py::TestDeclarative::test_as_object_property 165s ERROR tests/test_current_translation_property.py::TestDeclarative::test_as_class_property 165s ERROR tests/test_current_translation_property.py::TestDeclarative::test_setter 165s ERROR tests/test_current_translation_property.py::TestClassic::test_as_object_property 165s ERROR tests/test_current_translation_property.py::TestClassic::test_as_class_property 165s ERROR tests/test_current_translation_property.py::TestClassic::test_setter - ... 165s ERROR tests/test_current_translation_property_with_locale.py::TestDeclarative::test_converts_locale_object_to_unicode 165s ERROR tests/test_current_translation_property_with_locale.py::TestClassic::test_converts_locale_object_to_unicode 165s ERROR tests/test_custom_base_class.py::TestDeclarative::test_translatable_dict_copied_to_each_child_class 165s ERROR tests/test_fallback_locale_as_callable.py::TestDeclarative::test_hybrid_properties_support_callable_fallback_locales 165s ERROR tests/test_fallback_locale_as_callable.py::TestDeclarative::test_locale_fallback 165s ERROR tests/test_fallback_locale_as_callable.py::TestClassic::test_hybrid_properties_support_callable_fallback_locales 165s ERROR tests/test_fallback_locale_as_callable.py::TestClassic::test_locale_fallback 165s ERROR tests/test_fallback_locale_without_class_default.py::TestDeclarative::test_hybrid_properties_support_callable_fallback_locales 165s ERROR tests/test_fallback_locale_without_class_default.py::TestDeclarative::test_locale_fallback 165s ERROR tests/test_fallback_locale_without_class_default.py::TestClassic::test_hybrid_properties_support_callable_fallback_locales 165s ERROR tests/test_fallback_locale_without_class_default.py::TestClassic::test_locale_fallback 165s ERROR tests/test_fallback_translation.py::TestDeclarative::test_as_object_property_with_force_locale 165s ERROR tests/test_fallback_translation.py::TestDeclarative::test_as_class_property 165s ERROR tests/test_fallback_translation.py::TestDeclarative::test_setter - sqla... 165s ERROR tests/test_fallback_translation.py::TestClassic::test_as_object_property_with_force_locale 165s ERROR tests/test_fallback_translation.py::TestClassic::test_as_class_property 165s ERROR tests/test_fallback_translation.py::TestClassic::test_setter - sqlalche... 165s ERROR tests/test_find_translations.py::TestDeclarative::test_with_full_confidence 165s ERROR tests/test_find_translations.py::TestDeclarative::test_with_varying_confidence 165s ERROR tests/test_find_translations.py::TestClassic::test_with_full_confidence 165s ERROR tests/test_find_translations.py::TestClassic::test_with_varying_confidence 165s ERROR tests/test_hybrid_property_as_dynamic_source_locale.py::TestDeclarative::test_joinedload_for_current_translation 165s ERROR tests/test_hybrid_property_as_dynamic_source_locale.py::TestClassic::test_joinedload_for_current_translation 165s ERROR tests/test_hybrid_property_exclusion.py::TestClassic::test_does_not_generate_hybrid_properties 165s ERROR tests/test_join_expressions.py::TestDeclarative::test_current_translation_as_expression 165s ERROR tests/test_join_expressions.py::TestDeclarative::test_order_by_translation 165s ERROR tests/test_join_expressions.py::TestDeclarative::test_fallback_locale_as_expression 165s ERROR tests/test_join_expressions.py::TestDeclarative::test_querying - sqlalc... 165s ERROR tests/test_join_expressions.py::TestClassic::test_current_translation_as_expression 165s ERROR tests/test_join_expressions.py::TestClassic::test_order_by_translation 165s ERROR tests/test_join_expressions.py::TestClassic::test_fallback_locale_as_expression 165s ERROR tests/test_join_expressions.py::TestClassic::test_querying - sqlalchemy... 165s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_current_translation 165s ERROR tests/test_joined_loading.py::TestDeclarative::test_contains_eager_for_current_translation 165s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_single_translation 165s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_attr_accessor 165s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_all_translations 165s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_current_translation 165s ERROR tests/test_joined_loading.py::TestClassic::test_contains_eager_for_current_translation 165s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_single_translation 165s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_attr_accessor 165s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_all_translations 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_auto_creates_relations 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_auto_creates_current_translation 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_translatable_attributes 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_inherits_child_properties 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_translated_columns 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_property_delegators 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_table_name 165s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_inherits_parent_table 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_auto_creates_relations 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_auto_creates_current_translation 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_translatable_attributes 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_inherits_child_properties 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_translated_columns 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_property_delegators 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_table_name - ... 165s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_inherits_parent_table 165s ERROR tests/test_relationships.py::TestDeclarative::test_nullify_relation - s... 165s ERROR tests/test_relationships.py::TestClassic::test_nullify_relation - sqlal... 165s ERROR tests/test_translatable.py::TestDeclarative::test_auto_creates_relations 165s ERROR tests/test_translatable.py::TestDeclarative::test_translatable_attributes 165s ERROR tests/test_translatable.py::TestDeclarative::test_relationship_consistency 165s ERROR tests/test_translatable.py::TestDeclarative::test_property_delegators 165s ERROR tests/test_translatable.py::TestDeclarative::test_commit_session - sqla... 165s ERROR tests/test_translatable.py::TestDeclarative::test_delete - sqlalchemy_i... 165s ERROR tests/test_translatable.py::TestDeclarative::test_translated_columns - ... 165s ERROR tests/test_translatable.py::TestDeclarative::test_appends_locale_column_to_translation_table 165s ERROR tests/test_translatable.py::TestClassic::test_auto_creates_relations - ... 165s ERROR tests/test_translatable.py::TestClassic::test_translatable_attributes 165s ERROR tests/test_translatable.py::TestClassic::test_relationship_consistency 165s ERROR tests/test_translatable.py::TestClassic::test_property_delegators - sql... 165s ERROR tests/test_translatable.py::TestClassic::test_commit_session - sqlalche... 165s ERROR tests/test_translatable.py::TestClassic::test_delete - sqlalchemy.exc.I... 165s ERROR tests/test_translatable.py::TestClassic::test_translated_columns - sqla... 165s ERROR tests/test_translatable.py::TestClassic::test_appends_locale_column_to_translation_table 165s ERROR tests/test_translation_auto_creation.py::TestDeclarative::test_auto_creates_translation_objects 165s ERROR tests/test_translation_auto_creation.py::TestClassic::test_auto_creates_translation_objects 165s ERROR tests/test_translation_auto_creation_with_non_nullables.py::TestDeclarative::test_auto_sets_nullables_as_empty_strings 165s ERROR tests/test_translation_auto_creation_with_non_nullables.py::TestClassic::test_auto_sets_nullables_as_empty_strings 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_proxy_contains 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_translation_mapping_attribute_getter 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_attribute_accessor_for_unknown_locale 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_proxy_not_contains 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_items - sqlalc... 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_iteritems - sq... 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_set_item - sql... 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_repr - sqlalch... 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_iter - sqlalch... 165s ERROR tests/test_translation_mapping.py::TestDeclarative::test_values - sqlal... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_proxy_contains - s... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_translation_mapping_attribute_getter 165s ERROR tests/test_translation_mapping.py::TestClassic::test_attribute_accessor_for_unknown_locale 165s ERROR tests/test_translation_mapping.py::TestClassic::test_proxy_not_contains 165s ERROR tests/test_translation_mapping.py::TestClassic::test_items - sqlalchemy... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_iteritems - sqlalc... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_set_item - sqlalch... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_repr - sqlalchemy.... 165s ERROR tests/test_translation_mapping.py::TestClassic::test_iter - sqlalchemy....2024-11-13 16:33:11.837 UTC [4477] LOG: received smart shutdown request 169s 2024-11-13 16:33:16.845 UTC [4586] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.845 UTC [4522] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.847 UTC [4585] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.847 UTC [4523] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.849 UTC [4584] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.849 UTC [4521] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.850 UTC [4583] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.851 UTC [4582] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.853 UTC [4581] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.854 UTC [4580] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.854 UTC [4517] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.855 UTC [4579] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.856 UTC [4520] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.857 UTC [4578] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.857 UTC [4519] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.858 UTC [4577] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.858 UTC [4515] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.860 UTC [4576] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.860 UTC [4492] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.861 UTC [4575] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.861 UTC [4561] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.863 UTC [4574] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.863 UTC [4573] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.864 UTC [4570] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.864 UTC [4572] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.865 UTC [4569] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.866 UTC [4571] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.867 UTC [4568] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.867 UTC [4558] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.868 UTC [4567] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.870 UTC [4566] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.870 UTC [4540] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.871 UTC [4565] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.871 UTC [4539] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.872 UTC [4564] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.872 UTC [4538] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.874 UTC [4563] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.875 UTC [4562] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.875 UTC [4559] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.876 UTC [4500] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.876 UTC [4557] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.878 UTC [4499] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.878 UTC [4556] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.878 UTC [4498] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.879 UTC [4555] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.879 UTC [4497] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.880 UTC [4496] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.880 UTC [4554] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.881 UTC [4495] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.882 UTC [4553] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.882 UTC [4494] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.883 UTC [4552] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.884 UTC [4551] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.884 UTC [4493] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.886 UTC [4550] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.886 UTC [4491] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.887 UTC [4549] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.888 UTC [4490] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.888 UTC [4548] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.890 UTC [4547] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.890 UTC [4489] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.891 UTC [4546] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.891 UTC [4488] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.893 UTC [4545] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.893 UTC [4487] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.894 UTC [4544] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.895 UTC [4486] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.895 UTC [4543] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.896 UTC [4485] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.897 UTC [4542] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.898 UTC [4541] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.900 UTC [4537] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.901 UTC [4501] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.902 UTC [4502] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.902 UTC [4525] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.903 UTC [4503] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.903 UTC [4526] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.905 UTC [4504] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.905 UTC [4527] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.906 UTC [4505] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.906 UTC [4528] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.908 UTC [4506] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.908 UTC [4529] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.909 UTC [4507] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.909 UTC [4530] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.910 UTC [4536] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.911 UTC [4531] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.911 UTC [4508] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.913 UTC [4509] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.913 UTC [4532] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.914 UTC [4510] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.914 UTC [4533] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.916 UTC [4511] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.916 UTC [4534] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.917 UTC [4512] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.917 UTC [4535] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.919 UTC [4513] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.919 UTC [4514] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.920 UTC [4516] FATAL: terminating connection due to unexpected postmaster exit 169s 2024-11-13 16:33:16.921 UTC [4518] FATAL: terminating connection due to unexpected postmaster exit 169s 169s ERROR tests/test_translation_mapping.py::TestClassic::test_values - sqlalchem... 169s ============ 1 failed, 2 passed, 114 warnings, 116 errors in 17.33s ============ 169s stopping server 169s clean up 170s autopkgtest [16:33:17]: test setup-db-and-run-tests.py: -----------------------] 171s setup-db-and-run-tests.py PASS 171s autopkgtest [16:33:18]: test setup-db-and-run-tests.py: - - - - - - - - - - results - - - - - - - - - - 171s autopkgtest [16:33:18]: @@@@@@@@@@@@@@@@@@@@ summary 171s setup-db-and-run-tests.py PASS 183s nova [W] Using flock in prodstack6-s390x 183s Creating nova instance adt-plucky-s390x-sqlalchemy-i18n-20241113-163027-juju-7f2275-prod-proposed-migration-environment-20-d79e11fc-4cda-4528-9d60-85d21924a664 from image adt/ubuntu-plucky-s390x-server-20241113.img (UUID e740277e-1f72-40ae-bfbe-46030537c71c)...