0s autopkgtest [11:22:47]: starting date and time: 2024-11-13 11:22:47+0000 0s autopkgtest [11:22:47]: git checkout: 0acbae0a WIP show VirtSubproc stderr in real-time 0s autopkgtest [11:22:47]: host juju-7f2275-prod-proposed-migration-environment-2; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.o_2ng0yl/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 --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-2@lcy02-4.secgroup --name adt-plucky-amd64-sqlalchemy-i18n-20241113-112247-juju-7f2275-prod-proposed-migration-environment-2-1313d24d-24b5-48f5-bc8f-ff6ddc19888f --image adt/ubuntu-plucky-amd64-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-2 --net-id=net_prod-proposed-migration -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/ 96s autopkgtest [11:24:23]: testbed dpkg architecture: amd64 96s autopkgtest [11:24:23]: testbed apt version: 2.9.8 96s autopkgtest [11:24:23]: @@@@@@@@@@@@@@@@@@@@ test bed setup 97s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [73.9 kB] 97s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [849 kB] 97s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [15.3 kB] 97s Get:4 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [76.4 kB] 97s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/restricted Sources [7016 B] 97s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main i386 Packages [65.2 kB] 97s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/main amd64 Packages [111 kB] 97s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/restricted amd64 Packages [32.6 kB] 97s Get:9 http://ftpmaster.internal/ubuntu plucky-proposed/universe amd64 Packages [639 kB] 97s Get:10 http://ftpmaster.internal/ubuntu plucky-proposed/universe i386 Packages [255 kB] 97s Get:11 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse i386 Packages [13.0 kB] 97s Get:12 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse amd64 Packages [37.7 kB] 97s Fetched 2175 kB in 0s (6940 kB/s) 97s Reading package lists... 100s Reading package lists... 100s Building dependency tree... 100s Reading state information... 101s Calculating upgrade... 101s The following NEW packages will be installed: 101s python3.13-gdbm 101s The following packages will be upgraded: 101s libgpgme11t64 libpython3-stdlib python3 python3-gdbm python3-minimal 101s 5 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 101s Need to get 253 kB of archives. 101s After this operation, 147 kB of additional disk space will be used. 101s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main amd64 python3-minimal amd64 3.12.7-1 [27.4 kB] 101s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main amd64 python3 amd64 3.12.7-1 [24.0 kB] 101s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main amd64 libpython3-stdlib amd64 3.12.7-1 [10.0 kB] 101s Get:4 http://ftpmaster.internal/ubuntu plucky/main amd64 python3.13-gdbm amd64 3.13.0-2 [31.3 kB] 101s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/main amd64 python3-gdbm amd64 3.12.7-1 [8642 B] 101s Get:6 http://ftpmaster.internal/ubuntu plucky/main amd64 libgpgme11t64 amd64 1.23.2-5ubuntu4 [152 kB] 102s Fetched 253 kB in 0s (7982 kB/s) 102s (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 ... 75541 files and directories currently installed.) 102s Preparing to unpack .../python3-minimal_3.12.7-1_amd64.deb ... 102s Unpacking python3-minimal (3.12.7-1) over (3.12.6-0ubuntu1) ... 102s Setting up python3-minimal (3.12.7-1) ... 102s (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 ... 75541 files and directories currently installed.) 102s Preparing to unpack .../python3_3.12.7-1_amd64.deb ... 102s Unpacking python3 (3.12.7-1) over (3.12.6-0ubuntu1) ... 102s Preparing to unpack .../libpython3-stdlib_3.12.7-1_amd64.deb ... 102s Unpacking libpython3-stdlib:amd64 (3.12.7-1) over (3.12.6-0ubuntu1) ... 102s Selecting previously unselected package python3.13-gdbm. 102s Preparing to unpack .../python3.13-gdbm_3.13.0-2_amd64.deb ... 102s Unpacking python3.13-gdbm (3.13.0-2) ... 102s Preparing to unpack .../python3-gdbm_3.12.7-1_amd64.deb ... 102s Unpacking python3-gdbm:amd64 (3.12.7-1) over (3.12.6-1ubuntu1) ... 102s Preparing to unpack .../libgpgme11t64_1.23.2-5ubuntu4_amd64.deb ... 102s Unpacking libgpgme11t64:amd64 (1.23.2-5ubuntu4) over (1.18.0-4.1ubuntu4) ... 102s Setting up libgpgme11t64:amd64 (1.23.2-5ubuntu4) ... 102s Setting up python3.13-gdbm (3.13.0-2) ... 102s Setting up libpython3-stdlib:amd64 (3.12.7-1) ... 102s Setting up python3 (3.12.7-1) ... 103s Setting up python3-gdbm:amd64 (3.12.7-1) ... 103s Processing triggers for man-db (2.12.1-3) ... 103s Processing triggers for libc-bin (2.40-1ubuntu3) ... 103s Reading package lists... 104s Building dependency tree... 104s Reading state information... 104s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 104s Hit:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease 104s Hit:2 http://ftpmaster.internal/ubuntu plucky InRelease 104s Hit:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease 104s Hit:4 http://ftpmaster.internal/ubuntu plucky-security InRelease 105s Reading package lists... 105s Reading package lists... 106s Building dependency tree... 106s Reading state information... 106s Calculating upgrade... 106s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 106s Reading package lists... 107s Building dependency tree... 107s Reading state information... 107s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 108s autopkgtest [11:24:35]: testbed running kernel: Linux 6.11.0-8-generic #8-Ubuntu SMP PREEMPT_DYNAMIC Mon Sep 16 13:41:20 UTC 2024 108s autopkgtest [11:24:35]: @@@@@@@@@@@@@@@@@@@@ apt-source sqlalchemy-i18n 109s Get:1 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (dsc) [2462 B] 109s Get:2 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (tar) [28.2 kB] 109s Get:3 http://ftpmaster.internal/ubuntu plucky/universe sqlalchemy-i18n 1.1.0-1build1 (diff) [4212 B] 109s gpgv: Signature made Wed Jan 18 23:54:36 2023 UTC 109s gpgv: using RSA key 439884E6862A429C290DF63B033C4CA276024834 109s gpgv: issuer "athos.ribeiro@canonical.com" 109s gpgv: Can't check signature: No public key 109s dpkg-source: warning: cannot verify inline signature for ./sqlalchemy-i18n_1.1.0-1build1.dsc: no acceptable signature found 109s autopkgtest [11:24:36]: testing package sqlalchemy-i18n version 1.1.0-1build1 109s autopkgtest [11:24:36]: build not needed 109s autopkgtest [11:24:36]: test setup-db-and-run-tests.py: preparing testbed 110s Reading package lists... 110s Building dependency tree... 110s Reading state information... 111s Starting pkgProblemResolver with broken count: 0 111s Starting 2 pkgProblemResolver with broken count: 0 111s Done 111s The following additional packages will be installed: 111s libjs-jquery libjs-sphinxdoc libjs-underscore libjson-perl libpq5 libxslt1.1 111s postgresql postgresql-16 postgresql-client-16 postgresql-client-common 111s postgresql-common python3-arrow python3-dateutil python3-greenlet 111s python3-iniconfig python3-packaging python3-pluggy python3-psycopg2 111s python3-pytest python3-six python3-sqlalchemy python3-sqlalchemy-i18n 111s python3-sqlalchemy-utils ssl-cert 111s Suggested packages: 111s postgresql-doc postgresql-doc-16 python-arrow-doc python-greenlet-dev 111s python-greenlet-doc python-psycopg2-doc python-sqlalchemy-doc 111s python3-asyncpg python3-pg8000 python3-psycopg2cffi python3-aiosqlite 111s python3-mariadb-connector python3-mysqldb python3-mysql.connector 111s python3-pyodbc python3-pymssql python3-cx-oracle python3-oracledb 111s python-sqlalchemy-utils-doc python3-infinity python3-intervals 111s Recommended packages: 111s javascript-common libjson-xs-perl python3-sqlalchemy-ext 111s The following NEW packages will be installed: 111s autopkgtest-satdep libjs-jquery libjs-sphinxdoc libjs-underscore 111s libjson-perl libpq5 libxslt1.1 postgresql postgresql-16 postgresql-client-16 111s postgresql-client-common postgresql-common python3-arrow python3-dateutil 111s python3-greenlet python3-iniconfig python3-packaging python3-pluggy 111s python3-psycopg2 python3-pytest python3-six python3-sqlalchemy 111s python3-sqlalchemy-i18n python3-sqlalchemy-utils ssl-cert 111s 0 upgraded, 25 newly installed, 0 to remove and 0 not upgraded. 111s Need to get 19.8 MB/19.8 MB of archives. 111s After this operation, 65.0 MB of additional disk space will be used. 111s Get:1 /tmp/autopkgtest.RA2Dgm/1-autopkgtest-satdep.deb autopkgtest-satdep amd64 0 [744 B] 111s Get:2 http://ftpmaster.internal/ubuntu plucky/main amd64 libjson-perl all 4.10000-1 [81.9 kB] 111s Get:3 http://ftpmaster.internal/ubuntu plucky/main amd64 postgresql-client-common all 262 [36.7 kB] 111s Get:4 http://ftpmaster.internal/ubuntu plucky/main amd64 ssl-cert all 1.1.2ubuntu2 [18.0 kB] 111s Get:5 http://ftpmaster.internal/ubuntu plucky/main amd64 postgresql-common all 262 [162 kB] 111s Get:6 http://ftpmaster.internal/ubuntu plucky/main amd64 libjs-jquery all 3.6.1+dfsg+~3.5.14-1 [328 kB] 111s Get:7 http://ftpmaster.internal/ubuntu plucky/main amd64 libjs-underscore all 1.13.4~dfsg+~1.11.4-3 [118 kB] 111s Get:8 http://ftpmaster.internal/ubuntu plucky/main amd64 libjs-sphinxdoc all 7.4.7-4 [158 kB] 111s Get:9 http://ftpmaster.internal/ubuntu plucky/main amd64 libpq5 amd64 17.0-1 [249 kB] 111s Get:10 http://ftpmaster.internal/ubuntu plucky/main amd64 libxslt1.1 amd64 1.1.39-0exp1ubuntu1 [169 kB] 111s Get:11 http://ftpmaster.internal/ubuntu plucky/main amd64 postgresql-client-16 amd64 16.4-3 [1278 kB] 111s Get:12 http://ftpmaster.internal/ubuntu plucky/main amd64 postgresql-16 amd64 16.4-3 [15.2 MB] 112s Get:13 http://ftpmaster.internal/ubuntu plucky/main amd64 postgresql all 16+262 [11.8 kB] 112s Get:14 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-six all 1.16.0-7 [13.1 kB] 112s Get:15 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-dateutil all 2.9.0-2 [80.3 kB] 112s Get:16 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-arrow all 1.3.0-1.1ubuntu1 [56.1 kB] 112s Get:17 http://ftpmaster.internal/ubuntu plucky/universe amd64 python3-iniconfig all 1.1.1-2 [6024 B] 112s Get:18 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-packaging all 24.1-1 [41.4 kB] 112s Get:19 http://ftpmaster.internal/ubuntu plucky/universe amd64 python3-pluggy all 1.5.0-1 [21.0 kB] 112s Get:20 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-psycopg2 amd64 2.9.9-2 [132 kB] 112s Get:21 http://ftpmaster.internal/ubuntu plucky/universe amd64 python3-pytest all 8.3.3-1 [251 kB] 112s Get:22 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-greenlet amd64 3.0.3-0ubuntu6 [155 kB] 112s Get:23 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-sqlalchemy all 2.0.32+ds1-1ubuntu1 [1206 kB] 112s Get:24 http://ftpmaster.internal/ubuntu plucky/main amd64 python3-sqlalchemy-utils all 0.41.1-0ubuntu1 [59.4 kB] 112s Get:25 http://ftpmaster.internal/ubuntu plucky/universe amd64 python3-sqlalchemy-i18n all 1.1.0-1build1 [26.7 kB] 112s Preconfiguring packages ... 112s Fetched 19.8 MB in 1s (37.0 MB/s) 112s Selecting previously unselected package libjson-perl. 112s (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 ... 75548 files and directories currently installed.) 112s Preparing to unpack .../00-libjson-perl_4.10000-1_all.deb ... 112s Unpacking libjson-perl (4.10000-1) ... 112s Selecting previously unselected package postgresql-client-common. 112s Preparing to unpack .../01-postgresql-client-common_262_all.deb ... 112s Unpacking postgresql-client-common (262) ... 112s Selecting previously unselected package ssl-cert. 112s Preparing to unpack .../02-ssl-cert_1.1.2ubuntu2_all.deb ... 112s Unpacking ssl-cert (1.1.2ubuntu2) ... 112s Selecting previously unselected package postgresql-common. 112s Preparing to unpack .../03-postgresql-common_262_all.deb ... 112s Adding 'diversion of /usr/bin/pg_config to /usr/bin/pg_config.libpq-dev by postgresql-common' 112s Unpacking postgresql-common (262) ... 112s Selecting previously unselected package libjs-jquery. 112s Preparing to unpack .../04-libjs-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... 112s Unpacking libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 112s Selecting previously unselected package libjs-underscore. 112s Preparing to unpack .../05-libjs-underscore_1.13.4~dfsg+~1.11.4-3_all.deb ... 112s Unpacking libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... 112s Selecting previously unselected package libjs-sphinxdoc. 112s Preparing to unpack .../06-libjs-sphinxdoc_7.4.7-4_all.deb ... 112s Unpacking libjs-sphinxdoc (7.4.7-4) ... 112s Selecting previously unselected package libpq5:amd64. 112s Preparing to unpack .../07-libpq5_17.0-1_amd64.deb ... 112s Unpacking libpq5:amd64 (17.0-1) ... 112s Selecting previously unselected package libxslt1.1:amd64. 112s Preparing to unpack .../08-libxslt1.1_1.1.39-0exp1ubuntu1_amd64.deb ... 112s Unpacking libxslt1.1:amd64 (1.1.39-0exp1ubuntu1) ... 112s Selecting previously unselected package postgresql-client-16. 112s Preparing to unpack .../09-postgresql-client-16_16.4-3_amd64.deb ... 112s Unpacking postgresql-client-16 (16.4-3) ... 112s Selecting previously unselected package postgresql-16. 113s Preparing to unpack .../10-postgresql-16_16.4-3_amd64.deb ... 113s Unpacking postgresql-16 (16.4-3) ... 113s Selecting previously unselected package postgresql. 113s Preparing to unpack .../11-postgresql_16+262_all.deb ... 113s Unpacking postgresql (16+262) ... 113s Selecting previously unselected package python3-six. 113s Preparing to unpack .../12-python3-six_1.16.0-7_all.deb ... 113s Unpacking python3-six (1.16.0-7) ... 113s Selecting previously unselected package python3-dateutil. 113s Preparing to unpack .../13-python3-dateutil_2.9.0-2_all.deb ... 113s Unpacking python3-dateutil (2.9.0-2) ... 113s Selecting previously unselected package python3-arrow. 113s Preparing to unpack .../14-python3-arrow_1.3.0-1.1ubuntu1_all.deb ... 113s Unpacking python3-arrow (1.3.0-1.1ubuntu1) ... 113s Selecting previously unselected package python3-iniconfig. 113s Preparing to unpack .../15-python3-iniconfig_1.1.1-2_all.deb ... 113s Unpacking python3-iniconfig (1.1.1-2) ... 113s Selecting previously unselected package python3-packaging. 113s Preparing to unpack .../16-python3-packaging_24.1-1_all.deb ... 113s Unpacking python3-packaging (24.1-1) ... 113s Selecting previously unselected package python3-pluggy. 113s Preparing to unpack .../17-python3-pluggy_1.5.0-1_all.deb ... 113s Unpacking python3-pluggy (1.5.0-1) ... 113s Selecting previously unselected package python3-psycopg2. 113s Preparing to unpack .../18-python3-psycopg2_2.9.9-2_amd64.deb ... 113s Unpacking python3-psycopg2 (2.9.9-2) ... 113s Selecting previously unselected package python3-pytest. 113s Preparing to unpack .../19-python3-pytest_8.3.3-1_all.deb ... 113s Unpacking python3-pytest (8.3.3-1) ... 113s Selecting previously unselected package python3-greenlet. 113s Preparing to unpack .../20-python3-greenlet_3.0.3-0ubuntu6_amd64.deb ... 113s Unpacking python3-greenlet (3.0.3-0ubuntu6) ... 113s Selecting previously unselected package python3-sqlalchemy. 113s Preparing to unpack .../21-python3-sqlalchemy_2.0.32+ds1-1ubuntu1_all.deb ... 113s Unpacking python3-sqlalchemy (2.0.32+ds1-1ubuntu1) ... 113s Selecting previously unselected package python3-sqlalchemy-utils. 113s Preparing to unpack .../22-python3-sqlalchemy-utils_0.41.1-0ubuntu1_all.deb ... 113s Unpacking python3-sqlalchemy-utils (0.41.1-0ubuntu1) ... 113s Selecting previously unselected package python3-sqlalchemy-i18n. 113s Preparing to unpack .../23-python3-sqlalchemy-i18n_1.1.0-1build1_all.deb ... 113s Unpacking python3-sqlalchemy-i18n (1.1.0-1build1) ... 113s Selecting previously unselected package autopkgtest-satdep. 113s Preparing to unpack .../24-1-autopkgtest-satdep.deb ... 113s Unpacking autopkgtest-satdep (0) ... 113s Setting up postgresql-client-common (262) ... 113s Setting up python3-iniconfig (1.1.1-2) ... 113s Setting up libpq5:amd64 (17.0-1) ... 113s Setting up python3-six (1.16.0-7) ... 114s Setting up python3-packaging (24.1-1) ... 114s Setting up ssl-cert (1.1.2ubuntu2) ... 114s Created symlink '/etc/systemd/system/multi-user.target.wants/ssl-cert.service' → '/usr/lib/systemd/system/ssl-cert.service'. 114s Setting up python3-greenlet (3.0.3-0ubuntu6) ... 114s Setting up python3-psycopg2 (2.9.9-2) ... 115s Setting up python3-pluggy (1.5.0-1) ... 115s Setting up libjson-perl (4.10000-1) ... 115s Setting up libxslt1.1:amd64 (1.1.39-0exp1ubuntu1) ... 115s Setting up python3-dateutil (2.9.0-2) ... 115s Setting up libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 115s Setting up libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... 115s Setting up python3-arrow (1.3.0-1.1ubuntu1) ... 115s Setting up python3-pytest (8.3.3-1) ... 115s Setting up postgresql-client-16 (16.4-3) ... 116s 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 116s Setting up python3-sqlalchemy (2.0.32+ds1-1ubuntu1) ... 117s Setting up postgresql-common (262) ... 118s 118s Creating config file /etc/postgresql-common/createcluster.conf with new version 118s Building PostgreSQL dictionaries from installed myspell/hunspell packages... 118s Removing obsolete dictionary files: 118s Created symlink '/etc/systemd/system/multi-user.target.wants/postgresql.service' → '/usr/lib/systemd/system/postgresql.service'. 119s Setting up libjs-sphinxdoc (7.4.7-4) ... 119s Setting up python3-sqlalchemy-utils (0.41.1-0ubuntu1) ... 119s Setting up python3-sqlalchemy-i18n (1.1.0-1build1) ... 119s Setting up postgresql-16 (16.4-3) ... 119s Creating new PostgreSQL cluster 16/main ... 119s /usr/lib/postgresql/16/bin/initdb -D /var/lib/postgresql/16/main --auth-local peer --auth-host scram-sha-256 --no-instructions 119s The files belonging to this database system will be owned by user "postgres". 119s This user must also own the server process. 119s 119s The database cluster will be initialized with locale "C.UTF-8". 119s The default database encoding has accordingly been set to "UTF8". 119s The default text search configuration will be set to "english". 119s 119s Data page checksums are disabled. 119s 119s fixing permissions on existing directory /var/lib/postgresql/16/main ... ok 119s creating subdirectories ... ok 119s selecting dynamic shared memory implementation ... posix 119s selecting default max_connections ... 100 119s selecting default shared_buffers ... 128MB 119s selecting default time zone ... Etc/UTC 119s creating configuration files ... ok 120s running bootstrap script ... ok 120s performing post-bootstrap initialization ... ok 120s syncing data to disk ... ok 123s Setting up postgresql (16+262) ... 123s Setting up autopkgtest-satdep (0) ... 123s Processing triggers for man-db (2.12.1-3) ... 124s Processing triggers for libc-bin (2.40-1ubuntu3) ... 127s (Reading database ... 78332 files and directories currently installed.) 127s Removing autopkgtest-satdep (0) ... 127s autopkgtest [11:24:54]: test setup-db-and-run-tests.py: [----------------------- 127s The files belonging to this database system will be owned by user "ubuntu". 127s This user must also own the server process. 127s 127s The database cluster will be initialized with this locale configuration: 127s provider: libc 127s LC_COLLATE: C.UTF-8 127s LC_CTYPE: C.UTF-8 127s LC_MESSAGES: C 127s LC_MONETARY: C.UTF-8 127s LC_NUMERIC: C.UTF-8 127s LC_TIME: C.UTF-8 127s The default database encoding has accordingly been set to "UTF8". 127s The default text search configuration will be set to "english". 127s 127s Data page checksums are disabled. 127s 127s creating directory /tmp/tmppqf1mp26/data ... ok 127s creating subdirectories ... ok 127s selecting dynamic shared memory implementation ... posix 127s selecting default max_connections ... 100 127s selecting default shared_buffers ... 128MB 127s selecting default time zone ... Etc/UTC 127s creating configuration files ... ok 127s running bootstrap script ... ok 128s performing post-bootstrap initialization ... ok 128s syncing data to disk ... ok 128s 128s Success. You can now start the database server using: 128s 128s /usr/lib/postgresql/16/bin/pg_ctl -D /tmp/tmppqf1mp26/data -l logfile start 128s 128s 2024-11-13 11:24:55.258 UTC [4456] LOG: starting PostgreSQL 16.4 (Ubuntu 16.4-3) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 14.2.0-7ubuntu1) 14.2.0, 64-bit 128s 2024-11-13 11:24:55.258 UTC [4456] LOG: listening on IPv6 address "::1", port 46443 128s 2024-11-13 11:24:55.258 UTC [4456] LOG: listening on IPv4 address "127.0.0.1", port 46443 128s 2024-11-13 11:24:55.258 UTC [4456] LOG: listening on Unix socket "/tmp/tmppqf1mp26/tmp/.s.PGSQL.46443" 128s 2024-11-13 11:24:55.261 UTC [4459] LOG: database system was shut down at 2024-11-13 11:24:55 UTC 128s 2024-11-13 11:24:55.266 UTC [4456] LOG: database system is ready to accept connections 128s running initdb 128s starting server 128s ============================= test session starts ============================== 128s platform linux -- Python 3.12.7, pytest-8.3.3, pluggy-1.5.0 128s rootdir: /tmp/autopkgtest.RA2Dgm/build.4wu/src 128s plugins: typeguard-4.4.1 128s collected 119 items 128s 129s tests/test_common_base_class.py EE [ 1%] 129s tests/test_comparator.py EEEE [ 5%] 130s tests/test_composite_primary_key.py EE [ 6%] 130s tests/test_configuration.py EE [ 8%] 131s tests/test_current_translation_property.py EEEEEE [ 13%] 131s tests/test_current_translation_property_with_locale.py EE [ 15%] 132s tests/test_custom_base_class.py E [ 15%] 132s tests/test_expressions.py . [ 16%] 132s tests/test_fallback_locale_as_callable.py EEEE [ 20%] 133s tests/test_fallback_locale_without_class_default.py EEEE [ 23%] 134s tests/test_fallback_translation.py EEEEEE [ 28%] 134s tests/test_find_translations.py EEEE [ 31%] 134s tests/test_hybrid_property_as_dynamic_source_locale.py EE [ 33%] 135s tests/test_hybrid_property_exclusion.py FE [ 35%] 136s tests/test_join_expressions.py EEEEEEEE [ 42%] 137s tests/test_joined_loading.py EEEEEEEEEE [ 50%] 140s tests/test_joined_table_inheritance.py EEEEEEEEEEEEEEEE [ 63%] 140s tests/test_property_collision.py . [ 64%] 140s tests/test_relationships.py EE [ 66%] 143s tests/test_translatable.py EEEEEEEEEEEEEEEE [ 79%] 143s tests/test_translation_auto_creation.py EE [ 81%] 143s tests/test_translation_auto_creation_with_non_nullables.py EE [ 83%] 144s tests/test_translation_mapping.py EEEE2024-11-13 11:25:11.692 UTC [4569] FATAL: sorry, too many clients already 144s E2024-11-13 11:25:11.990 UTC [4570] FATAL: sorry, too many clients already 145s E2024-11-13 11:25:12.295 UTC [4571] FATAL: sorry, too many clients already 145s E2024-11-13 11:25:12.593 UTC [4572] FATAL: sorry, too many clients already 145s E2024-11-13 11:25:12.898 UTC [4573] FATAL: sorry, too many clients already 146s E2024-11-13 11:25:13.187 UTC [4574] FATAL: sorry, too many clients already 146s E2024-11-13 11:25:13.483 UTC [4575] FATAL: sorry, too many clients already 146s E2024-11-13 11:25:13.786 UTC [4576] FATAL: sorry, too many clients already 147s E2024-11-13 11:25:14.092 UTC [4577] FATAL: sorry, too many clients already 147s E2024-11-13 11:25:14.394 UTC [4578] FATAL: sorry, too many clients already 147s E2024-11-13 11:25:14.690 UTC [4579] FATAL: sorry, too many clients already 148s E2024-11-13 11:25:15.064 UTC [4580] FATAL: sorry, too many clients already 148s E2024-11-13 11:25:15.362 UTC [4581] FATAL: sorry, too many clients already 148s E2024-11-13 11:25:15.654 UTC [4582] FATAL: sorry, too many clients already 148s E2024-11-13 11:25:15.947 UTC [4583] FATAL: sorry, too many clients already 149s E2024-11-13 11:25:16.231 UTC [4584] FATAL: sorry, too many clients already 149s E [100%] 149s 149s ==================================== ERRORS ==================================== 149s _ ERROR at setup of TestDeclarative.test_translatable_dict_copied_to_each_child_class _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'TextItem' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestClassic.test_translatable_dict_copied_to_each_child_class _ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.textitems) 149s 149s tests/test_common_base_class.py:105: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('textitems', MetaData(), Column('id', Integer(), table=, primary_key=True, nullable=False), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestDeclarative.test_attribute_accessor_for_unknown_locale _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_attribute_accessors __________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___ ERROR at setup of TestClassic.test_attribute_accessor_for_unknown_locale ___ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestClassic.test_attribute_accessors ____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _____________ ERROR at setup of TestDeclarative.test_relationships _____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _______________ ERROR at setup of TestClassic.test_relationships _______________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), C...y_key=True, nullable=False), Column('id2', Integer(), table=
, primary_key=True, nullable=False), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestTranslationBaseCustomization.test_customize_foreign_key_args _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestTranslationBaseCustomization.test_customize_relationships_args _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_as_object_property ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['fi', 'en'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___________ ERROR at setup of TestDeclarative.test_as_class_property ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________________ ERROR at setup of TestDeclarative.test_setter _________________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____________ ERROR at setup of TestClassic.test_as_object_property _____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _____________ ERROR at setup of TestClassic.test_as_class_property _____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________________ ERROR at setup of TestClassic.test_setter ___________________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___ ERROR at setup of TestDeclarative.test_converts_locale_object_to_unicode ___ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____ ERROR at setup of TestClassic.test_converts_locale_object_to_unicode _____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('arti...able=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestDeclarative.test_translatable_dict_copied_to_each_child_class _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestDeclarative.test_hybrid_properties_support_callable_fallback_locales _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____________ ERROR at setup of TestDeclarative.test_locale_fallback ____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestClassic.test_hybrid_properties_support_callable_fallback_locales _ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaDat...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ______________ ERROR at setup of TestClassic.test_locale_fallback ______________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaDat...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestDeclarative.test_hybrid_properties_support_callable_fallback_locales _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____________ ERROR at setup of TestDeclarative.test_locale_fallback ____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestClassic.test_hybrid_properties_support_callable_fallback_locales _ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ______________ ERROR at setup of TestClassic.test_locale_fallback ______________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article...able=False), Column('locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestDeclarative.test_as_object_property_with_force_locale __ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___________ ERROR at setup of TestDeclarative.test_as_class_property ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________________ ERROR at setup of TestDeclarative.test_setter _________________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___ ERROR at setup of TestClassic.test_as_object_property_with_force_locale ____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _____________ ERROR at setup of TestClassic.test_as_class_property _____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________________ ERROR at setup of TestClassic.test_setter ___________________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _________ ERROR at setup of TestDeclarative.test_with_full_confidence __________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________ ERROR at setup of TestDeclarative.test_with_varying_confidence ________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi', 'sv'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___________ ERROR at setup of TestClassic.test_with_full_confidence ____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________ ERROR at setup of TestClassic.test_with_varying_confidence __________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __ ERROR at setup of TestDeclarative.test_joinedload_for_current_translation ___ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_hybrid_property_as_dynamic_source_locale.py:25: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi', 'sv'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____ ERROR at setup of TestClassic.test_joinedload_for_current_translation _____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_hybrid_property_as_dynamic_source_locale.py:61: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('arti...
), Column('_locale', CHAR(length=2), table=
, default=ScalarElementColumnDefault('en')), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____ ERROR at setup of TestClassic.test_does_not_generate_hybrid_properties ____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(...e=
, default=ScalarElementColumnDefault('en')), Column('word_count', Integer(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___ ERROR at setup of TestDeclarative.test_current_translation_as_expression ___ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _________ ERROR at setup of TestDeclarative.test_order_by_translation __________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____ ERROR at setup of TestDeclarative.test_fallback_locale_as_expression _____ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _______________ ERROR at setup of TestDeclarative.test_querying ________________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____ ERROR at setup of TestClassic.test_current_translation_as_expression _____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___________ ERROR at setup of TestClassic.test_order_by_translation ____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _______ ERROR at setup of TestClassic.test_fallback_locale_as_expression _______ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _________________ ERROR at setup of TestClassic.test_querying __________________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __ ERROR at setup of TestDeclarative.test_joinedload_for_current_translation ___ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:59: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestDeclarative.test_contains_eager_for_current_translation _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:59: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___ ERROR at setup of TestDeclarative.test_joinedload_for_single_translation ___ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:59: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____ ERROR at setup of TestDeclarative.test_joinedload_for_attr_accessor ______ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:59: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____ ERROR at setup of TestDeclarative.test_joinedload_for_all_translations ____ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:59: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____ ERROR at setup of TestClassic.test_joinedload_for_current_translation _____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:71: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __ ERROR at setup of TestClassic.test_contains_eager_for_current_translation ___ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:71: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _____ ERROR at setup of TestClassic.test_joinedload_for_single_translation _____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:71: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _______ ERROR at setup of TestClassic.test_joinedload_for_attr_accessor ________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:71: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ______ ERROR at setup of TestClassic.test_joinedload_for_all_translations ______ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_joined_loading.py:71: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ________ ERROR at setup of TestDeclarative.test_auto_creates_relations _________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___ ERROR at setup of TestDeclarative.test_auto_creates_current_translation ____ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________ ERROR at setup of TestDeclarative.test_translatable_attributes ________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _______ ERROR at setup of TestDeclarative.test_inherits_child_properties _______ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_translated_columns ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_property_delegators __________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ______________ ERROR at setup of TestDeclarative.test_table_name _______________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _________ ERROR at setup of TestDeclarative.test_inherits_parent_table _________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestClassic.test_auto_creates_relations ___________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _____ ERROR at setup of TestClassic.test_auto_creates_current_translation ______ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________ ERROR at setup of TestClassic.test_translatable_attributes __________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _________ ERROR at setup of TestClassic.test_inherits_child_properties _________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestClassic.test_translated_columns _____________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestClassic.test_property_delegators ____________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ________________ ERROR at setup of TestClassic.test_table_name _________________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___________ ERROR at setup of TestClassic.test_inherits_parent_table ___________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.TextItem, self.text_item, 149s polymorphic_on=self.text_item.c.discriminator) 149s 149s tests/test_joined_table_inheritance.py:155: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.TextItem'>, Table('text_item', MetaDat...ion', UnicodeText(), table=), Column('discriminator', Unicode(length=255), table=), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___________ ERROR at setup of TestDeclarative.test_nullify_relation ____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Category' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____________ ERROR at setup of TestClassic.test_nullify_relation ______________ 149s 149s self = 149s 149s def create_mappers(self): 149s > sa.orm.mapper(self.Article, self.article) 149s 149s tests/test_relationships.py:101: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('i...), table=
, primary_key=True, nullable=False), Column('content', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ________ ERROR at setup of TestDeclarative.test_auto_creates_relations _________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________ ERROR at setup of TestDeclarative.test_translatable_attributes ________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _______ ERROR at setup of TestDeclarative.test_relationship_consistency ________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_property_delegators __________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ____________ ERROR at setup of TestDeclarative.test_commit_session _____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ________________ ERROR at setup of TestDeclarative.test_delete _________________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_translated_columns ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestDeclarative.test_appends_locale_column_to_translation_table _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestClassic.test_auto_creates_relations ___________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________ ERROR at setup of TestClassic.test_translatable_attributes __________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _________ ERROR at setup of TestClassic.test_relationship_consistency __________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestClassic.test_property_delegators ____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ______________ ERROR at setup of TestClassic.test_commit_session _______________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s __________________ ERROR at setup of TestClassic.test_delete ___________________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestClassic.test_translated_columns _____________ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestClassic.test_appends_locale_column_to_translation_table _ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s 149s self.create_tables() 149s self.create_models() 149s > self.create_mappers() 149s 149s tests/__init__.py:140: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ___ ERROR at setup of TestDeclarative.test_auto_creates_translation_objects ____ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_translation_auto_creation.py:21: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _____ ERROR at setup of TestClassic.test_auto_creates_translation_objects ______ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_translation_auto_creation.py:31: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/__init__.py:213: in create_mappers 149s sa.orm.mapper(self.Article, self.article) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('article', MetaData(), Column('id', Integer(), table=
, primary_key=True, nullable=False), Column('description', UnicodeText(), table=
), schema=None)) 149s kw = {} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s _ ERROR at setup of TestDeclarative.test_auto_sets_nullables_as_empty_strings __ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'ExtendedArticle' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > DeclarativeTestCase.setup_method(self, method) 149s 149s tests/test_translation_auto_creation_with_non_nullables.py:26: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:57: in setup_method 149s sa.orm.configure_mappers() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2235: in _configure_property 149s mapper._adapt_inherited_property(key, prop, init) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2051: in _adapt_inherited_property 149s self._configure_property(key, prop, init=False, setparent=False) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2232: in _configure_property 149s prop.instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/relationships.py:523: in instrument_class 149s attributes.register_descriptor( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2646: in register_descriptor 149s descriptor = InstrumentedAttribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:231: in __init__ 149s self.dispatch._update(base[key].dispatch) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s ___ ERROR at setup of TestClassic.test_auto_sets_nullables_as_empty_strings ____ 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s > ClassicTestCase.setup_method(self, method) 149s 149s tests/test_translation_auto_creation_with_non_nullables.py:75: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s tests/__init__.py:140: in setup_method 149s self.create_mappers() 149s tests/test_translation_auto_creation_with_non_nullables.py:135: in create_mappers 149s sa.orm.mapper(self.Article, self.article, 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s arg = (.Article'>, Table('...ription', UnicodeText(), table=
), Column('discriminator', Unicode(length=255), table=
), schema=None)) 149s kw = {'polymorphic_on': Column('discriminator', Unicode(length=255), table=
)} 149s 149s def _mapper_fn(*arg: Any, **kw: Any) -> NoReturn: 149s """Placeholder for the now-removed ``mapper()`` function. 149s 149s Classical mappings should be performed using the 149s :meth:`_orm.registry.map_imperatively` method. 149s 149s This symbol remains in SQLAlchemy 2.0 to suit the deprecated use case 149s of using the ``mapper()`` function as a target for ORM event listeners, 149s which failed to be marked as deprecated in the 1.4 series. 149s 149s Global ORM mapper listeners should instead use the :class:`_orm.Mapper` 149s class as the target. 149s 149s .. versionchanged:: 2.0 The ``mapper()`` function was removed; the 149s symbol remains temporarily as a placeholder for the event listening 149s use case. 149s 149s """ 149s > raise InvalidRequestError( 149s "The 'sqlalchemy.orm.mapper()' function is removed as of " 149s "SQLAlchemy 2.0. Use the " 149s "'sqlalchemy.orm.registry.map_imperatively()` " 149s "method of the ``sqlalchemy.orm.registry`` class to perform " 149s "classical mapping." 149s ) 149s 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. 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/_orm_constructors.py:2007: InvalidRequestError 149s ____________ ERROR at setup of TestDeclarative.test_proxy_contains _____________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestDeclarative.test_translation_mapping_attribute_getter __ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _ ERROR at setup of TestDeclarative.test_attribute_accessor_for_unknown_locale _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s __________ ERROR at setup of TestDeclarative.test_proxy_not_contains ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s self.connection = self.engine.connect() 149s self.connection.query_count = 0 149s self.Model = declarative_base() 149s 149s self.create_models() 149s 149s if self.configure_mappers: 149s > sa.orm.configure_mappers() 149s 149s tests/__init__.py:57: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4173: in configure_mappers 149s _configure_registries(_all_registries(), cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s _________________ ERROR at setup of TestDeclarative.test_items _________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _______________ ERROR at setup of TestDeclarative.test_iteritems _______________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _______________ ERROR at setup of TestDeclarative.test_set_item ________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _________________ ERROR at setup of TestDeclarative.test_repr __________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _________________ ERROR at setup of TestDeclarative.test_iter __________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ________________ ERROR at setup of TestDeclarative.test_values _________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.engine = create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:50: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ______________ ERROR at setup of TestClassic.test_proxy_contains _______________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ___ ERROR at setup of TestClassic.test_translation_mapping_attribute_getter ____ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ___ ERROR at setup of TestClassic.test_attribute_accessor_for_unknown_locale ___ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ____________ ERROR at setup of TestClassic.test_proxy_not_contains _____________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ___________________ ERROR at setup of TestClassic.test_items ___________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _________________ ERROR at setup of TestClassic.test_iteritems _________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s _________________ ERROR at setup of TestClassic.test_set_item __________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ___________________ ERROR at setup of TestClassic.test_repr ____________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s ___________________ ERROR at setup of TestClassic.test_iter ____________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s __________________ ERROR at setup of TestClassic.test_values ___________________ 149s 149s self = 149s engine = Engine(postgresql://postgres@localhost/sqlalchemy_i18n_test) 149s connection = None, _has_events = None, _allow_revalidate = True 149s _allow_autobegin = True 149s 149s def __init__( 149s self, 149s engine: Engine, 149s connection: Optional[PoolProxiedConnection] = None, 149s _has_events: Optional[bool] = None, 149s _allow_revalidate: bool = True, 149s _allow_autobegin: bool = True, 149s ): 149s """Construct a new Connection.""" 149s self.engine = engine 149s self.dialect = dialect = engine.dialect 149s 149s if connection is None: 149s try: 149s > self._dbapi_connection = engine.raw_connection() 149s 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E psycopg2.OperationalError: connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s 149s The above exception was the direct cause of the following exception: 149s 149s self = 149s method = > 149s 149s def setup_method(self, method): 149s self.metadata = sa.MetaData() 149s 149s self.engine = sa.create_engine(self.engine_uri) 149s # self.engine.echo = True 149s > self.connection = self.engine.connect() 149s 149s tests/__init__.py:135: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3278: in connect 149s return self._connection_cls(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:148: in __init__ 149s Connection._handle_dbapi_exception_noconnection( 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:2442: in _handle_dbapi_exception_noconnection 149s raise sqlalchemy_exception.with_traceback(exc_info[2]) from e 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:146: in __init__ 149s self._dbapi_connection = engine.raw_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/base.py:3302: in raw_connection 149s return self.pool.connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:449: in connect 149s return _ConnectionFairy._checkout(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:1263: in _checkout 149s fairy = _ConnectionRecord.checkout(pool) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:712: in checkout 149s rec = pool._do_get() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:179: in _do_get 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/impl.py:177: in _do_get 149s return self._create_connection() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:390: in _create_connection 149s return _ConnectionRecord(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:674: in __init__ 149s self.__connect() 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:900: in __connect 149s with util.safe_reraise(): 149s /usr/lib/python3/dist-packages/sqlalchemy/util/langhelpers.py:146: in __exit__ 149s raise exc_value.with_traceback(exc_tb) 149s /usr/lib/python3/dist-packages/sqlalchemy/pool/base.py:896: in __connect 149s self.dbapi_connection = connection = pool._invoke_creator(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/create.py:643: in connect 149s return dialect.connect(*cargs, **cparams) 149s /usr/lib/python3/dist-packages/sqlalchemy/engine/default.py:621: in connect 149s return self.loaded_dbapi.connect(*cargs, **cparams) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s dsn = 'host=localhost dbname=sqlalchemy_i18n_test user=postgres' 149s connection_factory = None, cursor_factory = None 149s kwargs = {'dbname': 'sqlalchemy_i18n_test', 'host': 'localhost', 'user': 'postgres'} 149s kwasync = {} 149s 149s def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs): 149s """ 149s Create a new database connection. 149s 149s The connection parameters can be specified as a string: 149s 149s conn = psycopg2.connect("dbname=test user=postgres password=secret") 149s 149s or using a set of keyword arguments: 149s 149s conn = psycopg2.connect(database="test", user="postgres", password="secret") 149s 149s Or as a mix of both. The basic connection parameters are: 149s 149s - *dbname*: the database name 149s - *database*: the database name (only as keyword argument) 149s - *user*: user name used to authenticate 149s - *password*: password used to authenticate 149s - *host*: database host address (defaults to UNIX socket if not provided) 149s - *port*: connection port number (defaults to 5432 if not provided) 149s 149s Using the *connection_factory* parameter a different class or connections 149s factory can be specified. It should be a callable object taking a dsn 149s argument. 149s 149s Using the *cursor_factory* parameter, a new default cursor factory will be 149s used by cursor(). 149s 149s Using *async*=True an asynchronous connection will be created. *async_* is 149s a valid alias (for Python versions where ``async`` is a keyword). 149s 149s Any other keyword parameter will be passed to the underlying client 149s library: the list of supported parameters depends on the library version. 149s 149s """ 149s kwasync = {} 149s if 'async' in kwargs: 149s kwasync['async'] = kwargs.pop('async') 149s if 'async_' in kwargs: 149s kwasync['async_'] = kwargs.pop('async_') 149s 149s dsn = _ext.make_dsn(dsn, **kwargs) 149s > conn = _connect(dsn, connection_factory=connection_factory, **kwasync) 149s E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "localhost" (::1), port 46443 failed: FATAL: sorry, too many clients already 149s E 149s E (Background on this error at: https://sqlalche.me/e/20/e3q8) 149s 149s /usr/lib/python3/dist-packages/psycopg2/__init__.py:122: OperationalError 149s =================================== FAILURES =================================== 149s ___________ TestDeclarative.test_does_not_generate_hybrid_properties ___________ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s > return getattr(class_, '_translation_%s' % locale) 149s E AttributeError: type object 'Article' has no attribute '_translation__slots_dispatch' 149s 149s sqlalchemy_i18n/comparators.py:13: AttributeError 149s 149s During handling of the above exception, another exception occurred: 149s 149s self = 149s 149s def test_does_not_generate_hybrid_properties(self): 149s > self.Article() 149s 149s tests/test_hybrid_property_exclusion.py:15: 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s :4: in __init__ 149s ??? 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/state.py:566: in _initialize_instance 149s manager.dispatch.init(self, args, kwargs) 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:497: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4396: in _event_on_init 149s instrumenting_mapper._check_configure() 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2388: in _check_configure 149s _configure_registries({self.registry}, cascade=True) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:4207: in _configure_registries 149s Mapper.dispatch._for_class(Mapper).after_configured() # type: ignore 149s /usr/lib/python3/dist-packages/sqlalchemy/event/attr.py:378: in __call__ 149s fn(*args, **kw) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/events.py:891: in wrap 149s fn(*arg, **kw) 149s sqlalchemy_i18n/manager.py:110: in configure_translatable_classes 149s RelationshipBuilder(self, cls)() 149s sqlalchemy_i18n/builders.py:228: in __call__ 149s self.assign_translations() 149s sqlalchemy_i18n/builders.py:186: in assign_translations 149s mapper.add_property('_translations', sa.orm.relationship( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2432: in add_property 149s prop = self._configure_property( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/mapper.py:2239: in _configure_property 149s prop.post_instrument_class(self) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/interfaces.py:1092: in post_instrument_class 149s self.strategy.init_class_attribute(mapper) 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:788: in init_class_attribute 149s _register_attribute( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/strategies.py:122: in _register_attribute 149s desc = attributes.register_attribute_impl( 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:2605: in register_attribute_impl 149s "_Dispatch[QueryableAttribute[Any]]", manager[key].dispatch 149s /usr/lib/python3/dist-packages/sqlalchemy/event/base.py:465: in __get__ 149s if hasattr(obj, "_slots_dispatch"): 149s /usr/lib/python3/dist-packages/sqlalchemy/orm/attributes.py:472: in __getattr__ 149s return getattr(self.comparator, key) 149s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 149s 149s self = 149s locale = '_slots_dispatch' 149s 149s def __getattr__(self, locale): 149s class_ = self._parentmapper.class_ 149s try: 149s return getattr(class_, '_translation_%s' % locale) 149s except AttributeError: 149s > raise UnknownLocaleError(locale, class_) 149s E sqlalchemy_i18n.exc.UnknownLocaleError: Unknown locale _slots_dispatch given for instance of class . Locale is not one of ['en', 'fi'] 149s 149s sqlalchemy_i18n/comparators.py:15: UnknownLocaleError 149s =============================== warnings summary =============================== 149s sqlalchemy_i18n/translatable.py:62 149s /tmp/autopkgtest.RA2Dgm/build.4wu/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. 149s @sa.event.listens_for(sa.orm.mapper, 'expire') 149s 149s sqlalchemy_i18n/__init__.py:41 149s /tmp/autopkgtest.RA2Dgm/build.4wu/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. 149s sa.event.listen( 149s 149s sqlalchemy_i18n/__init__.py:44 149s /tmp/autopkgtest.RA2Dgm/build.4wu/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. 149s sa.event.listen( 149s 149s tests/test_common_base_class.py: 1 warning 149s tests/test_comparator.py: 2 warnings 149s tests/test_composite_primary_key.py: 1 warning 149s tests/test_configuration.py: 2 warnings 149s tests/test_current_translation_property.py: 3 warnings 149s tests/test_current_translation_property_with_locale.py: 1 warning 149s tests/test_custom_base_class.py: 1 warning 149s tests/test_fallback_locale_as_callable.py: 2 warnings 149s tests/test_fallback_locale_without_class_default.py: 2 warnings 149s tests/test_fallback_translation.py: 3 warnings 149s tests/test_find_translations.py: 2 warnings 149s tests/test_hybrid_property_as_dynamic_source_locale.py: 1 warning 149s tests/test_hybrid_property_exclusion.py: 1 warning 149s tests/test_join_expressions.py: 4 warnings 149s tests/test_joined_loading.py: 5 warnings 149s tests/test_joined_table_inheritance.py: 8 warnings 149s tests/test_property_collision.py: 1 warning 149s tests/test_relationships.py: 1 warning 149s tests/test_translatable.py: 8 warnings 149s tests/test_translation_auto_creation.py: 1 warning 149s tests/test_translation_auto_creation_with_non_nullables.py: 1 warning 149s tests/test_translation_mapping.py: 4 warnings 149s /tmp/autopkgtest.RA2Dgm/build.4wu/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) 149s self.Model = declarative_base() 149s 149s tests/test_common_base_class.py: 2 warnings 149s tests/test_comparator.py: 2 warnings 149s tests/test_composite_primary_key.py: 1 warning 149s tests/test_configuration.py: 2 warnings 149s tests/test_current_translation_property.py: 3 warnings 149s tests/test_current_translation_property_with_locale.py: 1 warning 149s tests/test_custom_base_class.py: 1 warning 149s tests/test_fallback_locale_as_callable.py: 2 warnings 149s tests/test_fallback_locale_without_class_default.py: 2 warnings 149s tests/test_fallback_translation.py: 3 warnings 149s tests/test_find_translations.py: 2 warnings 149s tests/test_hybrid_property_as_dynamic_source_locale.py: 1 warning 149s tests/test_hybrid_property_exclusion.py: 1 warning 149s tests/test_join_expressions.py: 4 warnings 149s tests/test_joined_loading.py: 5 warnings 149s tests/test_joined_table_inheritance.py: 8 warnings 149s tests/test_property_collision.py: 1 warning 149s tests/test_relationships.py: 1 warning 149s tests/test_translatable.py: 8 warnings 149s tests/test_translation_auto_creation.py: 1 warning 149s tests/test_translation_auto_creation_with_non_nullables.py: 1 warning 149s tests/test_translation_mapping.py: 4 warnings 149s /tmp/autopkgtest.RA2Dgm/build.4wu/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) 149s if has_inherited_table(cls): 149s 149s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 149s =========================== short test summary info ============================ 149s FAILED tests/test_hybrid_property_exclusion.py::TestDeclarative::test_does_not_generate_hybrid_properties 149s ERROR tests/test_common_base_class.py::TestDeclarative::test_translatable_dict_copied_to_each_child_class 149s ERROR tests/test_common_base_class.py::TestClassic::test_translatable_dict_copied_to_each_child_class 149s ERROR tests/test_comparator.py::TestDeclarative::test_attribute_accessor_for_unknown_locale 149s ERROR tests/test_comparator.py::TestDeclarative::test_attribute_accessors - s... 149s ERROR tests/test_comparator.py::TestClassic::test_attribute_accessor_for_unknown_locale 149s ERROR tests/test_comparator.py::TestClassic::test_attribute_accessors - sqlal... 149s ERROR tests/test_composite_primary_key.py::TestDeclarative::test_relationships 149s ERROR tests/test_composite_primary_key.py::TestClassic::test_relationships - ... 149s ERROR tests/test_configuration.py::TestTranslationBaseCustomization::test_customize_foreign_key_args 149s ERROR tests/test_configuration.py::TestTranslationBaseCustomization::test_customize_relationships_args 149s ERROR tests/test_current_translation_property.py::TestDeclarative::test_as_object_property 149s ERROR tests/test_current_translation_property.py::TestDeclarative::test_as_class_property 149s ERROR tests/test_current_translation_property.py::TestDeclarative::test_setter 149s ERROR tests/test_current_translation_property.py::TestClassic::test_as_object_property 149s ERROR tests/test_current_translation_property.py::TestClassic::test_as_class_property 149s ERROR tests/test_current_translation_property.py::TestClassic::test_setter - ... 149s ERROR tests/test_current_translation_property_with_locale.py::TestDeclarative::test_converts_locale_object_to_unicode 149s ERROR tests/test_current_translation_property_with_locale.py::TestClassic::test_converts_locale_object_to_unicode 149s ERROR tests/test_custom_base_class.py::TestDeclarative::test_translatable_dict_copied_to_each_child_class 149s ERROR tests/test_fallback_locale_as_callable.py::TestDeclarative::test_hybrid_properties_support_callable_fallback_locales 149s ERROR tests/test_fallback_locale_as_callable.py::TestDeclarative::test_locale_fallback 149s ERROR tests/test_fallback_locale_as_callable.py::TestClassic::test_hybrid_properties_support_callable_fallback_locales 149s ERROR tests/test_fallback_locale_as_callable.py::TestClassic::test_locale_fallback 149s ERROR tests/test_fallback_locale_without_class_default.py::TestDeclarative::test_hybrid_properties_support_callable_fallback_locales 149s ERROR tests/test_fallback_locale_without_class_default.py::TestDeclarative::test_locale_fallback 149s ERROR tests/test_fallback_locale_without_class_default.py::TestClassic::test_hybrid_properties_support_callable_fallback_locales 149s ERROR tests/test_fallback_locale_without_class_default.py::TestClassic::test_locale_fallback 149s ERROR tests/test_fallback_translation.py::TestDeclarative::test_as_object_property_with_force_locale 149s ERROR tests/test_fallback_translation.py::TestDeclarative::test_as_class_property 149s ERROR tests/test_fallback_translation.py::TestDeclarative::test_setter - sqla... 149s ERROR tests/test_fallback_translation.py::TestClassic::test_as_object_property_with_force_locale 149s ERROR tests/test_fallback_translation.py::TestClassic::test_as_class_property 149s ERROR tests/test_fallback_translation.py::TestClassic::test_setter - sqlalche... 149s ERROR tests/test_find_translations.py::TestDeclarative::test_with_full_confidence 149s ERROR tests/test_find_translations.py::TestDeclarative::test_with_varying_confidence 149s ERROR tests/test_find_translations.py::TestClassic::test_with_full_confidence 149s ERROR tests/test_find_translations.py::TestClassic::test_with_varying_confidence 149s ERROR tests/test_hybrid_property_as_dynamic_source_locale.py::TestDeclarative::test_joinedload_for_current_translation 149s ERROR tests/test_hybrid_property_as_dynamic_source_locale.py::TestClassic::test_joinedload_for_current_translation 149s ERROR tests/test_hybrid_property_exclusion.py::TestClassic::test_does_not_generate_hybrid_properties 149s ERROR tests/test_join_expressions.py::TestDeclarative::test_current_translation_as_expression 149s ERROR tests/test_join_expressions.py::TestDeclarative::test_order_by_translation 149s ERROR tests/test_join_expressions.py::TestDeclarative::test_fallback_locale_as_expression 149s ERROR tests/test_join_expressions.py::TestDeclarative::test_querying - sqlalc... 149s ERROR tests/test_join_expressions.py::TestClassic::test_current_translation_as_expression 149s ERROR tests/test_join_expressions.py::TestClassic::test_order_by_translation 149s ERROR tests/test_join_expressions.py::TestClassic::test_fallback_locale_as_expression 149s ERROR tests/test_join_expressions.py::TestClassic::test_querying - sqlalchemy... 149s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_current_translation 149s ERROR tests/test_joined_loading.py::TestDeclarative::test_contains_eager_for_current_translation 149s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_single_translation 149s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_attr_accessor 149s ERROR tests/test_joined_loading.py::TestDeclarative::test_joinedload_for_all_translations 149s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_current_translation 149s ERROR tests/test_joined_loading.py::TestClassic::test_contains_eager_for_current_translation 149s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_single_translation 149s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_attr_accessor 149s ERROR tests/test_joined_loading.py::TestClassic::test_joinedload_for_all_translations 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_auto_creates_relations 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_auto_creates_current_translation 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_translatable_attributes 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_inherits_child_properties 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_translated_columns 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_property_delegators 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_table_name 149s ERROR tests/test_joined_table_inheritance.py::TestDeclarative::test_inherits_parent_table 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_auto_creates_relations 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_auto_creates_current_translation 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_translatable_attributes 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_inherits_child_properties 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_translated_columns 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_property_delegators 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_table_name - ... 149s ERROR tests/test_joined_table_inheritance.py::TestClassic::test_inherits_parent_table 149s ERROR tests/test_relationships.py::TestDeclarative::test_nullify_relation - s... 149s ERROR tests/test_relationships.py::TestClassic::test_nullify_relation - sqlal... 149s ERROR tests/test_translatable.py::TestDeclarative::test_auto_creates_relations 149s ERROR tests/test_translatable.py::TestDeclarative::test_translatable_attributes 149s ERROR tests/test_translatable.py::TestDeclarative::test_relationship_consistency 149s ERROR tests/test_translatable.py::TestDeclarative::test_property_delegators 149s ERROR tests/test_translatable.py::TestDeclarative::test_commit_session - sqla... 149s ERROR tests/test_translatable.py::TestDeclarative::test_delete - sqlalchemy_i... 149s ERROR tests/test_translatable.py::TestDeclarative::test_translated_columns - ... 149s ERROR tests/test_translatable.py::TestDeclarative::test_appends_locale_column_to_translation_table 149s ERROR tests/test_translatable.py::TestClassic::test_auto_creates_relations - ... 149s ERROR tests/test_translatable.py::TestClassic::test_translatable_attributes 149s ERROR tests/test_translatable.py::TestClassic::test_relationship_consistency 149s ERROR tests/test_translatable.py::TestClassic::test_property_delegators - sql... 149s ERROR tests/test_translatable.py::TestClassic::test_commit_session - sqlalche... 149s ERROR tests/test_translatable.py::TestClassic::test_delete - sqlalchemy.exc.I... 149s ERROR tests/test_translatable.py::TestClassic::test_translated_columns - sqla... 149s ERROR tests/test_translatable.py::TestClassic::test_appends_locale_column_to_translation_table 149s ERROR tests/test_translation_auto_creation.py::TestDeclarative::test_auto_creates_translation_objects 149s ERROR tests/test_translation_auto_creation.py::TestClassic::test_auto_creates_translation_objects 149s ERROR tests/test_translation_auto_creation_with_non_nullables.py::TestDeclarative::test_auto_sets_nullables_as_empty_strings 149s ERROR tests/test_translation_auto_creation_with_non_nullables.py::TestClassic::test_auto_sets_nullables_as_empty_strings 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_proxy_contains 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_translation_mapping_attribute_getter 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_attribute_accessor_for_unknown_locale 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_proxy_not_contains 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_items - sqlalc... 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_iteritems - sq... 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_set_item - sql... 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_repr - sqlalch... 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_iter - sqlalch... 149s ERROR tests/test_translation_mapping.py::TestDeclarative::test_values - sqlal... 149s ERROR tests/test_translation_mapping.py::TestClassic::test_proxy_contains - s... 149s ERROR tests/test_translation_mapping.py::TestClassic::test_translation_mapping_attribute_getter 149s ERROR tests/test_translation_mapping.py::TestClassic::test_attribute_accessor_for_unknown_locale 149s ERROR tests/test_translation_mapping.py::TestClassic::test_proxy_not_contains 149s ERROR tests/test_translation_mapping.py::TestClassic::test_items - sqlalchemy... 149s ERROR tests/test_translation_mapping.py::TestClassic::test_iteritems - sqlalc...2024-11-13 11:25:16.562 UTC [4456] LOG: received smart shutdown request 154s 2024-11-13 11:25:21.573 UTC [4474] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.573 UTC [4477] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.575 UTC [4480] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.577 UTC [4481] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.578 UTC [4466] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.579 UTC [4473] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.581 UTC [4472] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.581 UTC [4465] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.583 UTC [4548] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.583 UTC [4471] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.584 UTC [4470] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.585 UTC [4547] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.586 UTC [4469] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.587 UTC [4546] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.588 UTC [4468] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.589 UTC [4545] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.590 UTC [4467] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.591 UTC [4544] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.592 UTC [4464] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.593 UTC [4549] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.596 UTC [4568] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.597 UTC [4516] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.598 UTC [4567] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.599 UTC [4515] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.600 UTC [4566] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.601 UTC [4514] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.602 UTC [4565] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.603 UTC [4513] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.604 UTC [4564] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.605 UTC [4512] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.606 UTC [4563] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.607 UTC [4511] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.608 UTC [4562] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.609 UTC [4510] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.610 UTC [4561] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.611 UTC [4509] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.612 UTC [4560] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.613 UTC [4483] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.614 UTC [4559] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.615 UTC [4482] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.616 UTC [4558] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.617 UTC [4479] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.618 UTC [4557] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.619 UTC [4478] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.620 UTC [4556] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.621 UTC [4476] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.622 UTC [4508] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.623 UTC [4475] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.625 UTC [4507] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.627 UTC [4505] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.627 UTC [4555] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.629 UTC [4504] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.629 UTC [4554] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.631 UTC [4503] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.631 UTC [4553] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.633 UTC [4502] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.633 UTC [4552] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.635 UTC [4551] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.635 UTC [4498] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.637 UTC [4497] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.637 UTC [4550] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.639 UTC [4543] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.639 UTC [4496] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.641 UTC [4541] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.641 UTC [4495] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.643 UTC [4540] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.643 UTC [4494] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.645 UTC [4539] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.645 UTC [4493] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.647 UTC [4538] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.648 UTC [4492] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.649 UTC [4537] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.650 UTC [4491] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.651 UTC [4536] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.652 UTC [4490] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.653 UTC [4535] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.654 UTC [4489] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.655 UTC [4534] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.656 UTC [4488] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.657 UTC [4533] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.658 UTC [4487] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.659 UTC [4532] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.660 UTC [4486] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.661 UTC [4531] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.662 UTC [4485] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.663 UTC [4530] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.664 UTC [4484] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.665 UTC [4529] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.667 UTC [4528] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.669 UTC [4527] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.670 UTC [4526] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.673 UTC [4525] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.675 UTC [4524] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.677 UTC [4523] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.679 UTC [4522] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.681 UTC [4521] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.682 UTC [4517] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.683 UTC [4520] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.685 UTC [4518] FATAL: terminating connection due to unexpected postmaster exit 154s 2024-11-13 11:25:21.687 UTC [4519] FATAL: terminating connection due to unexpected postmaster exit 154s 154s ERROR tests/test_translation_mapping.py::TestClassic::test_set_item - sqlalch... 154s ERROR tests/test_translation_mapping.py::TestClassic::test_repr - sqlalchemy.... 154s ERROR tests/test_translation_mapping.py::TestClassic::test_iter - sqlalchemy.... 154s ERROR tests/test_translation_mapping.py::TestClassic::test_values - sqlalchem... 154s ============ 1 failed, 2 passed, 114 warnings, 116 errors in 21.07s ============ 154s stopping server 154s clean up 155s autopkgtest [11:25:22]: test setup-db-and-run-tests.py: -----------------------] 155s autopkgtest [11:25:22]: test setup-db-and-run-tests.py: - - - - - - - - - - results - - - - - - - - - - 155s setup-db-and-run-tests.py PASS 155s autopkgtest [11:25:22]: @@@@@@@@@@@@@@@@@@@@ summary 155s setup-db-and-run-tests.py PASS 167s virt: nova [W] Skipping flock for amd64 167s virt: Creating nova instance adt-plucky-amd64-sqlalchemy-i18n-20241113-112247-juju-7f2275-prod-proposed-migration-environment-2-1313d24d-24b5-48f5-bc8f-ff6ddc19888f from image adt/ubuntu-plucky-amd64-server-20241113.img (UUID 76b850f9-98f4-4b79-af06-fa11000b95b2)...