]> git.ipfire.org Git - thirdparty/psycopg.git/log
thirdparty/psycopg.git
2 years agoperf(c): only use __cinit__ in adaptation classes
Daniele Varrazzo [Tue, 25 Oct 2022 23:25:34 +0000 (01:25 +0200)] 
perf(c): only use __cinit__ in adaptation classes

There is less overhead creating the objects.

2 years agoperf: avoid lookups of Wait and Ready enum values
Daniele Varrazzo [Wed, 19 Oct 2022 15:55:33 +0000 (16:55 +0100)] 
perf: avoid lookups of Wait and Ready enum values

2 years agodocs: document how to unbreak editable mode in the readme
Daniele Varrazzo [Wed, 26 Oct 2022 01:07:28 +0000 (03:07 +0200)] 
docs: document how to unbreak editable mode in the readme

2 years agochore: bump to next dev version
Daniele Varrazzo [Thu, 27 Oct 2022 00:08:28 +0000 (02:08 +0200)] 
chore: bump to next dev version

2 years agodocs: typographic love to the 2to3 page
Daniele Varrazzo [Wed, 26 Oct 2022 23:59:24 +0000 (01:59 +0200)] 
docs: typographic love to the 2to3 page

2 years agodocs: add section about returning multiple results
Daniele Varrazzo [Wed, 26 Oct 2022 23:58:04 +0000 (01:58 +0200)] 
docs: add section about returning multiple results

Close #417.

2 years agoMerge branch 'build-macos-py311'
Daniele Varrazzo [Wed, 26 Oct 2022 23:01:10 +0000 (01:01 +0200)] 
Merge branch 'build-macos-py311'

2 years agoci: re-enable suspended job after building the missing image
Daniele Varrazzo [Wed, 26 Oct 2022 23:00:38 +0000 (01:00 +0200)] 
ci: re-enable suspended job after building the missing image

2 years agoci: configure in order to build only Python 3.11 packages for macOS x86_64
Daniele Varrazzo [Wed, 26 Oct 2022 22:49:04 +0000 (00:49 +0200)] 
ci: configure in order to build only Python 3.11 packages for macOS x86_64

The required image was not available at the time of building other
packages. See #424.

2 years agochore: bump psycopg-pool version to 3.1.3 pool-3.1.3
Daniele Varrazzo [Tue, 25 Oct 2022 18:02:28 +0000 (20:02 +0200)] 
chore: bump psycopg-pool version to 3.1.3

2 years agochore: bump to version number 3.1.4 3.1.4
Daniele Varrazzo [Tue, 25 Oct 2022 17:50:20 +0000 (19:50 +0200)] 
chore: bump to version number 3.1.4

2 years agochore: upgrade binary dependencies to libpq 15.0, openssl 1.1.1r
Daniele Varrazzo [Tue, 25 Oct 2022 14:58:23 +0000 (16:58 +0200)] 
chore: upgrade binary dependencies to libpq 15.0, openssl 1.1.1r

2 years agoMerge branch 'py311'
Daniele Varrazzo [Tue, 25 Oct 2022 17:43:18 +0000 (19:43 +0200)] 
Merge branch 'py311'

2 years agoci: build Python 3.11 macOS arm64 packages
Daniele Varrazzo [Tue, 25 Oct 2022 14:55:24 +0000 (16:55 +0200)] 
ci: build Python 3.11 macOS arm64 packages

2 years agoci: skip test/build on macOS x86_64 for Python 3.11
Daniele Varrazzo [Tue, 25 Oct 2022 14:39:06 +0000 (16:39 +0200)] 
ci: skip test/build on macOS x86_64 for Python 3.11

Package not available yet. See #424

2 years agodocs: mention Python 3.11 support in news
Daniele Varrazzo [Thu, 8 Sep 2022 13:34:45 +0000 (14:34 +0100)] 
docs: mention Python 3.11 support in news

2 years agoci: build packages for Python 3.11 too
Daniele Varrazzo [Thu, 8 Sep 2022 13:00:59 +0000 (14:00 +0100)] 
ci: build packages for Python 3.11 too

2 years agochore: add Python 3.11 support metadata
Daniele Varrazzo [Sun, 15 May 2022 17:05:20 +0000 (19:05 +0200)] 
chore: add Python 3.11 support metadata

2 years agochore: test with Python 3.11 rc1
Daniele Varrazzo [Sun, 15 May 2022 16:10:24 +0000 (18:10 +0200)] 
chore: test with Python 3.11 rc1

2 years agochore: upgrade Cython to 3.0a11 to support Python 3.11
Daniele Varrazzo [Sun, 15 May 2022 17:05:39 +0000 (19:05 +0200)] 
chore: upgrade Cython to 3.0a11 to support Python 3.11

2 years agochore: upgrade actions/upload-artifact version
Daniele Varrazzo [Tue, 25 Oct 2022 12:29:59 +0000 (14:29 +0200)] 
chore: upgrade actions/upload-artifact version

2 years agotest: print out the file to delete in order to clear the segfault indicator
Daniele Varrazzo [Thu, 20 Oct 2022 21:45:48 +0000 (23:45 +0200)] 
test: print out the file to delete in order to clear the segfault indicator

2 years agotest: terminate the session early if connection to the test db fails
Daniele Varrazzo [Thu, 20 Oct 2022 21:04:18 +0000 (23:04 +0200)] 
test: terminate the session early if connection to the test db fails

The error might be masked by other failures. It's also not useful to
receive the same message hundreds of times.

2 years agoMerge branch 'pg15'
Daniele Varrazzo [Thu, 20 Oct 2022 19:21:51 +0000 (21:21 +0200)] 
Merge branch 'pg15'

2 years agoci: Use Postgres 15 images and packages after official release
Daniele Varrazzo [Thu, 20 Oct 2022 02:31:03 +0000 (04:31 +0200)] 
ci: Use Postgres 15 images and packages after official release

2 years agodocs: declare PostgreSQL 15 supported
Daniele Varrazzo [Thu, 6 Oct 2022 01:55:24 +0000 (02:55 +0100)] 
docs: declare PostgreSQL 15 supported

2 years agochore: add errors defined in PostgreSQL 15
Daniele Varrazzo [Thu, 6 Oct 2022 01:47:46 +0000 (02:47 +0100)] 
chore: add errors defined in PostgreSQL 15

2 years agotest: include PostgreSQL RC 1 and libpq 15 in the tests
Daniele Varrazzo [Mon, 22 Aug 2022 10:25:47 +0000 (12:25 +0200)] 
test: include PostgreSQL RC 1 and libpq 15 in the tests

2 years agochore: upgrade github actions
Daniele Varrazzo [Thu, 20 Oct 2022 02:24:18 +0000 (04:24 +0200)] 
chore: upgrade github actions

The currently used ones raise deprecation warnings.

2 years agotest: document --pq-trace and --pq-debug pytest option
Denis Laxalde [Mon, 10 Oct 2022 15:26:38 +0000 (17:26 +0200)] 
test: document --pq-trace and --pq-debug pytest option

2 years agotest: add --pq-debug pytest option to use PGconnDebug
Denis Laxalde [Thu, 6 Oct 2022 19:14:47 +0000 (21:14 +0200)] 
test: add --pq-debug pytest option to use PGconnDebug

2 years agofix: lock the connection during all stream() lifetime
Denis Laxalde [Thu, 6 Oct 2022 14:41:05 +0000 (16:41 +0200)] 
fix: lock the connection during all stream() lifetime

Namely, also lock the connection when closing the generator, in the
finally clause, where we are fetching results.

2 years agorefactor: handle exit exception in BasePipeline._exit()
Denis Laxalde [Tue, 4 Oct 2022 19:41:22 +0000 (21:41 +0200)] 
refactor: handle exit exception in BasePipeline._exit()

We remove repeated code in __(a)exit__() method of (Async)Pipeline by
passing the exception value to _exit() method of BasePipeline.

2 years agochore: bump version number to next dev release
Daniele Varrazzo [Wed, 5 Oct 2022 11:09:02 +0000 (12:09 +0100)] 
chore: bump version number to next dev release

2 years agoMerge pull request #401 from dlax/pipeline-no-extra-begin 3.1.3
Daniele Varrazzo [Tue, 4 Oct 2022 18:11:16 +0000 (19:11 +0100)] 
Merge pull request #401 from dlax/pipeline-no-extra-begin

fix: sync pipeline after implicit BEGIN

2 years agofix: sync pipeline after implicit BEGIN 401/head
Denis Laxalde [Tue, 4 Oct 2022 15:53:26 +0000 (17:53 +0200)] 
fix: sync pipeline after implicit BEGIN

Prior to this change, the following code:

    with conn.pipeline():
       conn.execute("select 'x'").fetchone()
       conn.execute("select 'y'")

would produce the following libpq trace:

    F 13 Parse  "" "BEGIN" 0
    F 14 Bind  "" "" 0 0 1 0
    F 6 Describe  P ""
    F 9 Execute  "" 0
    F 18 Parse  "" "select 'x'" 0
    F 14 Bind  "" "" 0 0 1 0
    F 6 Describe  P ""
    F 9 Execute  "" 0
    F 4 Flush
    B 4 ParseComplete
    B 4 BindComplete
    B 4 NoData
    B 10 CommandComplete  "BEGIN"
    B 4 ParseComplete
    B 4 BindComplete
    B 33 RowDescription  1 "?column?" NNNN 0 NNNN 65535 -1 0
    B 11 DataRow  1 1 'x'
    B 13 CommandComplete  "SELECT 1"
    F 13 Parse  "" "BEGIN" 0
    F 14 Bind  "" "" 0 0 1 0
    F 6 Describe  P ""
    F 9 Execute  "" 0
    F 18 Parse  "" "select 'y'" 0
    F 14 Bind  "" "" 0 0 1 0
    F 6 Describe  P ""
    F 9 Execute  "" 0
    B 4 ParseComplete
    B 4 BindComplete
    B 4 NoData
    B NN NoticeResponse  S "WARNING" V "WARNING" C "25001" M "there is already a transaction in progress" F "SSSS" L "SSSS" R "SSSS" \x00
    F 4 Sync
    B 10 CommandComplete  "BEGIN"
    B 4 ParseComplete
    B 4 BindComplete
    B 33 RowDescription  1 "?column?" NNNN 0 NNNN 65535 -1 0
    B 11 DataRow  1 1 'y'
    B 13 CommandComplete  "SELECT 1"
    B 5 ReadyForQuery  T

where we can see that the BEGIN statement (due to the connection being
in non-autocommit mode) is emitted twice, as notified by the server.

This is because the transaction state after the implicit BEGIN is not
"correct" (i.e. should be INTRANS, but is IDLE) since the result from
respective statement has not been received yet.

By syncing after the BEGIN, we fetch result from this command thus get
the transaction state INTRANS for following queries. This is similar to
what happens with explicit transaction, by using nested pipelines.

2 years agochore: bump to version number 3.1.3
Daniele Varrazzo [Tue, 4 Oct 2022 16:43:27 +0000 (17:43 +0100)] 
chore: bump to version number 3.1.3

2 years agoMerge branch 'fix-399'
Daniele Varrazzo [Tue, 4 Oct 2022 16:23:17 +0000 (17:23 +0100)] 
Merge branch 'fix-399'

2 years agofix: fix handling of queries with %% in ClientCursor
Daniele Varrazzo [Mon, 3 Oct 2022 23:28:07 +0000 (00:28 +0100)] 
fix: fix handling of queries with %% in ClientCursor

Close #399.

2 years ago#397: Fix typo in install.rst
Darren Ho [Sat, 1 Oct 2022 17:33:59 +0000 (18:33 +0100)] 
#397: Fix typo in install.rst

2 years agoRemove warning about missing binary package for M1
Magnus Watn [Fri, 30 Sep 2022 13:44:28 +0000 (15:44 +0200)] 
Remove warning about missing binary package for M1

Binary packages for Apple M1 was added in #162.

2 years agoMerge branch 'stream-close'
Daniele Varrazzo [Wed, 28 Sep 2022 18:25:08 +0000 (19:25 +0100)] 
Merge branch 'stream-close'

2 years agofix: make sure to terminate query on gen.close() from Cursor.stream()
Daniele Varrazzo [Wed, 21 Sep 2022 10:40:25 +0000 (11:40 +0100)] 
fix: make sure to terminate query on gen.close() from Cursor.stream()

Fix #382

2 years agoperf: use functools.cache where available
Daniele Varrazzo [Wed, 28 Sep 2022 01:01:52 +0000 (02:01 +0100)] 
perf: use functools.cache where available

Faster than lru_cache; use it when we don't suppose we will ever evict
values.

2 years agoMerge branch 'fix-escape-nametuple-field'
Daniele Varrazzo [Wed, 28 Sep 2022 00:46:48 +0000 (01:46 +0100)] 
Merge branch 'fix-escape-nametuple-field'

2 years agodocs: mention named tuples regression fix in change log 388/head
Daniele Varrazzo [Tue, 27 Sep 2022 08:54:49 +0000 (09:54 +0100)] 
docs: mention named tuples regression fix in change log

2 years agotest: more exhaustive test of difficult names/attrs in composites
Daniele Varrazzo [Tue, 27 Sep 2022 08:51:11 +0000 (09:51 +0100)] 
test: more exhaustive test of difficult names/attrs in composites

2 years agofix: restore pre-3.1 behaviour converting fields to named tuples attributes
Jolbas [Sun, 25 Sep 2022 14:11:36 +0000 (16:11 +0200)] 
fix: restore pre-3.1 behaviour converting fields to named tuples attributes

Let more valid identifiers through _as_python_identifier(). Also 2.5x faster if no change is needed

Close #386

2 years agotest: check unusual column names and namedtuple
Jolbas [Sun, 25 Sep 2022 12:32:42 +0000 (14:32 +0200)] 
test: check unusual column names and namedtuple

2 years agofix: avoid using type variables in typevar bounds
Daniele Varrazzo [Tue, 27 Sep 2022 08:15:21 +0000 (09:15 +0100)] 
fix: avoid using type variables in typevar bounds

It is not allowed by the specs. Mypy tolerates it, replacing the
argument with Any, according to @erictraut. Pyright reports it as an
error instead.

See #365, microsoft/pyright#3984

2 years agochore: upgrade mypy to 0.981
Daniele Varrazzo [Wed, 28 Sep 2022 00:28:41 +0000 (01:28 +0100)] 
chore: upgrade mypy to 0.981

Most changes needed by https://github.com/python/typeshed/pull/8446.

2 years agodocs: fix plural
Daniele Varrazzo [Sun, 25 Sep 2022 01:41:52 +0000 (02:41 +0100)] 
docs: fix plural

2 years agodocs: mention macOS arm64 packages distribution
Daniele Varrazzo [Sun, 25 Sep 2022 01:39:29 +0000 (02:39 +0100)] 
docs: mention macOS arm64 packages distribution

2 years agobuild: fix starting Postgres in macOS build script
Daniele Varrazzo [Sun, 25 Sep 2022 01:31:22 +0000 (02:31 +0100)] 
build: fix starting Postgres in macOS build script

The brew command fails with:

    Could not enable service: 125: Domain does not support specified action
    Error: Failure while executing; `/bin/launchctl enable gui/501/homebrew.mxcl.postgresql@14` exited with 125.

2 years agodocs: typo messge -> message
Daniele Varrazzo [Wed, 21 Sep 2022 11:49:25 +0000 (12:49 +0100)] 
docs: typo messge -> message

Thank you, codespell ðŸ’€ðŸ’€ðŸ’€

2 years agodocs: add link to document how to recover the stream from ACTIVE state
Daniele Varrazzo [Wed, 21 Sep 2022 11:46:07 +0000 (12:46 +0100)] 
docs: add link to document how to recover the stream from ACTIVE state

See #382.

2 years agochore: bump to next dev version number
Daniele Varrazzo [Mon, 19 Sep 2022 17:31:58 +0000 (18:31 +0100)] 
chore: bump to next dev version number

2 years agochore: bump to version number 3.1.2 3.1.2
Daniele Varrazzo [Mon, 19 Sep 2022 11:08:22 +0000 (12:08 +0100)] 
chore: bump to version number 3.1.2

2 years agofix: fix queries with repeated named parameters in ClientCursor
Daniele Varrazzo [Sun, 18 Sep 2022 21:45:48 +0000 (22:45 +0100)] 
fix: fix queries with repeated named parameters in ClientCursor

Close #378.

2 years agotest: allow to trace libpq to STDERR, rename option to --pq-trace
Denis Laxalde [Thu, 15 Sep 2022 10:24:43 +0000 (12:24 +0200)] 
test: allow to trace libpq to STDERR, rename option to --pq-trace

By using STDERR, we get the trace directly in pytest output for failing
tests. Though this requires care when used in combination with
--capture=sys because this would make sys.stderr an in-memory file.

When STDERR is used, we don't insert the header since the test case
identifier will be interleaved already.

2 years agofix: also sync nested pipeline when a transaction is active
Denis Laxalde [Thu, 15 Sep 2022 16:28:21 +0000 (18:28 +0200)] 
fix: also sync nested pipeline when a transaction is active

Upon enter, transaction() checks the in-transaction status to determine
if a BEGIN (when IDLE) or a SAVEPOINT (otherwise) should be inserted.
However, in pipeline mode, if the pipeline is in "implicit transaction"
(i.e. it has no active BEGIN) and statements have been sent, the
in-transaction status might be ACTIVE if those statements have not yet
completed (typically, when results have not been fetched).

By issuing a sync() before entering a nested pipeline (which will happen
when entering transaction(), if already within a pipeline), we force
completion of those statements, and thus get a predictable
in-transaction status before entering the transaction() block.

Closes #374.

2 years agotest: fail test session in case of segfault
Daniele Varrazzo [Thu, 15 Sep 2022 01:07:57 +0000 (02:07 +0100)] 
test: fail test session in case of segfault

Before that, tox reruns would have made tests pass, because failed tests
wouldn't have gotten a chance to be written in the cache.

2 years agoMerge branch 'fix-372'
Daniele Varrazzo [Wed, 14 Sep 2022 21:30:44 +0000 (22:30 +0100)] 
Merge branch 'fix-372'

2 years agofix(psycopg_c): propagate exceptions in Transformer.set_pgresult()
Daniele Varrazzo [Wed, 14 Sep 2022 21:02:38 +0000 (22:02 +0100)] 
fix(psycopg_c): propagate exceptions in Transformer.set_pgresult()

Fix #372

2 years agotest: add test to verify the behavior of adapters failing init
Daniele Varrazzo [Wed, 14 Sep 2022 20:57:05 +0000 (21:57 +0100)] 
test: add test to verify the behavior of adapters failing init

An exception in loader init doesn't get raised and causes a segfault.
This reproduces the issue in #372.

2 years agoMerge branch 'docs/pgconn'
Daniele Varrazzo [Wed, 14 Sep 2022 14:17:55 +0000 (15:17 +0100)] 
Merge branch 'docs/pgconn'

2 years agodocs: document PGconn's tracing methods 373/head
Denis Laxalde [Wed, 14 Sep 2022 12:20:05 +0000 (14:20 +0200)] 
docs: document PGconn's tracing methods

2 years agodocs: document PGconn.encrypt_password()
Denis Laxalde [Wed, 14 Sep 2022 12:02:43 +0000 (14:02 +0200)] 
docs: document PGconn.encrypt_password()

Including an example of usage.

2 years agorefactor(psycopg_c): define loggers at module level
Daniele Varrazzo [Wed, 14 Sep 2022 14:14:32 +0000 (15:14 +0100)] 
refactor(psycopg_c): define loggers at module level

2 years agofix(psycopg_c): add missing logger declaration
Daniele Varrazzo [Wed, 14 Sep 2022 13:40:41 +0000 (14:40 +0100)] 
fix(psycopg_c): add missing logger declaration

2 years agoMerge branch 'fix-371'
Daniele Varrazzo [Wed, 14 Sep 2022 12:24:55 +0000 (13:24 +0100)] 
Merge branch 'fix-371'

2 years agodocs: mention Windows timezone problem fixed in change log
Daniele Varrazzo [Wed, 14 Sep 2022 11:59:14 +0000 (12:59 +0100)] 
docs: mention Windows timezone problem fixed in change log

2 years agofix: catch any type of error if ZoneInfo creation fails
Daniele Varrazzo [Wed, 14 Sep 2022 11:50:05 +0000 (12:50 +0100)] 
fix: catch any type of error if ZoneInfo creation fails

OSError would be enough to solve the problem reported in #371. However,
in case of error, Windows C implementation segfaults. I would prefer to
not chase this error just because of weirdness in the tzdata external
library, so let's cast a wider net.

Fix #371

2 years agotest: add bad timezone to simulate a reported timezone issue
Daniele Varrazzo [Wed, 14 Sep 2022 11:33:23 +0000 (12:33 +0100)] 
test: add bad timezone to simulate a reported timezone issue

The bad timezone causes OSError on Windows.

See #371

2 years agochore(pool): bump to next dev version number
Daniele Varrazzo [Thu, 8 Sep 2022 12:59:47 +0000 (13:59 +0100)] 
chore(pool): bump to next dev version number

2 years agochore: bump psycopg-pool version to 3.1.2 pool-3.1.2
Daniele Varrazzo [Wed, 7 Sep 2022 11:01:04 +0000 (12:01 +0100)] 
chore: bump psycopg-pool version to 3.1.2

2 years agoMerge branch 'fix-370'
Daniele Varrazzo [Wed, 7 Sep 2022 10:56:43 +0000 (11:56 +0100)] 
Merge branch 'fix-370'

2 years agofix(pool): continue growing if the pool is not full yet
Daniele Varrazzo [Tue, 6 Sep 2022 23:49:14 +0000 (00:49 +0100)] 
fix(pool): continue growing if the pool is not full yet

Previously, starting from an empty pool, we would have stopped at the
first connection created.

2 years agofix(pool): allow growing again after failing a growing connection attempt
Daniele Varrazzo [Tue, 6 Sep 2022 16:53:40 +0000 (17:53 +0100)] 
fix(pool): allow growing again after failing a growing connection attempt

Fix #370

2 years agochore: bump to next dev version number
Daniele Varrazzo [Tue, 6 Sep 2022 11:49:19 +0000 (12:49 +0100)] 
chore: bump to next dev version number

2 years agochore: bump to version number 3.1.1 3.1.1
Daniele Varrazzo [Mon, 5 Sep 2022 12:23:19 +0000 (13:23 +0100)] 
chore: bump to version number 3.1.1

2 years agoMerge branch 'macos-broken'
Daniele Varrazzo [Mon, 5 Sep 2022 12:21:37 +0000 (13:21 +0100)] 
Merge branch 'macos-broken'

2 years agodocs: add news entry about Homebrew fix
Daniele Varrazzo [Mon, 5 Sep 2022 11:28:05 +0000 (12:28 +0100)] 
docs: add news entry about Homebrew fix

2 years agorefactor: add find_libpq_full_path() to use both in library and tests
Daniele Varrazzo [Mon, 5 Sep 2022 11:09:33 +0000 (12:09 +0100)] 
refactor: add find_libpq_full_path() to use both in library and tests

2 years agofix(macos): find the libpq in non-standard places
Daniele Varrazzo [Mon, 5 Sep 2022 09:56:06 +0000 (10:56 +0100)] 
fix(macos): find the libpq in non-standard places

2 years agochore: upgrade QEMU to v2 for build
Daniele Varrazzo [Sat, 3 Sep 2022 18:24:52 +0000 (19:24 +0100)] 
chore: upgrade QEMU to v2 for build

Also make sure to use a version not affected by bug #304

2 years agofix: make sure to pass a port number to getaddrinfo
Daniele Varrazzo [Fri, 2 Sep 2022 15:30:23 +0000 (16:30 +0100)] 
fix: make sure to pass a port number to getaddrinfo

Was passing an empty string by mistake, if no port was specified. Mostly
not a problem, except on some platforms, where it causes an
"unrecognized service" error.

Close #366.

2 years agoBump to next dev release
Daniele Varrazzo [Fri, 2 Sep 2022 15:29:28 +0000 (16:29 +0100)] 
Bump to next dev release

2 years agodocs: fix title level in news
Daniele Varrazzo [Tue, 30 Aug 2022 22:46:46 +0000 (23:46 +0100)] 
docs: fix title level in news

2 years agochore: bump version number to release 3.1 3.1
Daniele Varrazzo [Mon, 29 Aug 2022 23:01:14 +0000 (00:01 +0100)] 
chore: bump version number to release 3.1

2 years agochore: bump to version 3.0.17
Daniele Varrazzo [Mon, 29 Aug 2022 22:52:03 +0000 (23:52 +0100)] 
chore: bump to version 3.0.17

2 years agoMerge branch 'crdb-ci'
Daniele Varrazzo [Mon, 29 Aug 2022 08:58:57 +0000 (09:58 +0100)] 
Merge branch 'crdb-ci'

2 years agoci: run CRDB tests in CI
Daniele Varrazzo [Sun, 28 Aug 2022 16:56:08 +0000 (17:56 +0100)] 
ci: run CRDB tests in CI

2 years agotest(crdb): consider Decimal("Infinity") not supported in CRDB < 22
Daniele Varrazzo [Mon, 29 Aug 2022 01:23:03 +0000 (02:23 +0100)] 
test(crdb): consider Decimal("Infinity") not supported in CRDB < 22

2 years agotest(crdb) Skip tests affected by BEGIN READ ONLY bug
Daniele Varrazzo [Mon, 29 Aug 2022 00:43:50 +0000 (01:43 +0100)] 
test(crdb) Skip tests affected by BEGIN READ ONLY bug

The connection doesn't go in read-only mode if the statement is executed
using the advanced protocol.

See https://github.com/cockroachdb/cockroach/issues/87012

2 years agofix: load bytea as bytes, not memoryview, in Python implementation
Daniele Varrazzo [Mon, 29 Aug 2022 01:10:27 +0000 (02:10 +0100)] 
fix: load bytea as bytes, not memoryview, in Python implementation

2 years agochore(crdb): fix file name where to update OIDs
Daniele Varrazzo [Sun, 28 Aug 2022 16:35:33 +0000 (17:35 +0100)] 
chore(crdb): fix file name where to update OIDs

2 years agofix: use a "finally" to clear the result pointer after handling notifies
Daniele Varrazzo [Sat, 27 Aug 2022 20:29:56 +0000 (21:29 +0100)] 
fix: use a "finally" to clear the result pointer after handling notifies

The chance for this to fail failed is slim (an error in the logger? A
ctrl-c just there?) but a bit of paranoia has never hurt anyone.

2 years agoperf(pq_ctypes): use the faster byref() rather than pointer()
Daniele Varrazzo [Sat, 27 Aug 2022 20:28:22 +0000 (21:28 +0100)] 
perf(pq_ctypes): use the faster byref() rather than pointer()

2 years agoMerge branch 'pgnotifyfixes'
Daniele Varrazzo [Sun, 28 Aug 2022 11:56:52 +0000 (12:56 +0100)] 
Merge branch 'pgnotifyfixes'