]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/log
thirdparty/sqlalchemy/sqlalchemy.git
10 months agoBump pypa/cibuildwheel from 2.21.1 to 2.21.2 (#11947)
dependabot[bot] [Sat, 5 Oct 2024 07:43:30 +0000 (09:43 +0200)] 
Bump pypa/cibuildwheel from 2.21.1 to 2.21.2 (#11947)

Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel) from 2.21.1 to 2.21.2.
- [Release notes](https://github.com/pypa/cibuildwheel/releases)
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md)
- [Commits](https://github.com/pypa/cibuildwheel/compare/v2.21.1...v2.21.2)

---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
10 months agoMerge "block mariadb 1.1.10" into main
Michael Bayer [Tue, 24 Sep 2024 20:20:31 +0000 (20:20 +0000)] 
Merge "block mariadb 1.1.10" into main

10 months agoblock mariadb 1.1.10
Mike Bayer [Tue, 24 Sep 2024 13:35:48 +0000 (09:35 -0400)] 
block mariadb 1.1.10

does not build for any python version

see https://jira.mariadb.org/browse/CONPY-293

Change-Id: I1bf53d79eda7ded017b233f1639aae4bf9578ae6

10 months agoLink scalar result method in scalar_one / scalar_one_or_none
Federico Caselli [Mon, 23 Sep 2024 21:11:06 +0000 (23:11 +0200)] 
Link scalar result method in scalar_one / scalar_one_or_none

References: #11919

Change-Id: Iccbcd3fc3a6143be902683837b36260e5dd31c60

10 months agoAdd type annotations to CreateSchema & DropSchema (#11914)
sh-at-cs [Mon, 23 Sep 2024 17:21:40 +0000 (19:21 +0200)] 
Add type annotations to CreateSchema & DropSchema (#11914)

10 months agopropagate populate_existing for ORM bulk update
Mike Bayer [Sun, 22 Sep 2024 15:34:48 +0000 (11:34 -0400)] 
propagate populate_existing for ORM bulk update

Similar to #9742

Fixed bug in ORM bulk update/delete where using RETURNING with bulk
update/delete in combination with populate existing would fail to
accommodate the populate_existing option.

Fixes: #11912
Change-Id: Ib9ef659512a1d1ae438eab67332a691941c06f43

10 months agoUpdated link for the Kinetica dialect (#11895)
am-kinetica [Thu, 19 Sep 2024 20:46:11 +0000 (02:16 +0530)] 
Updated link for the Kinetica dialect (#11895)

10 months agoMerge "Remove test warning in python 3.13" into main
Federico Caselli [Wed, 18 Sep 2024 22:09:25 +0000 (22:09 +0000)] 
Merge "Remove test warning in python 3.13" into main

10 months agoadd python 3.13 to pipeline
Federico Caselli [Mon, 5 Aug 2024 21:26:13 +0000 (23:26 +0200)] 
add python 3.13 to pipeline

Change-Id: Id223cfa08b187c2225ea7a6c29817d79474acfc1

10 months agoRemove test warning in python 3.13
Federico Caselli [Tue, 17 Sep 2024 18:22:11 +0000 (20:22 +0200)] 
Remove test warning in python 3.13

Change-Id: Ib098754ef6d157e8dd1eac32b3cb114a9ca66e4a

10 months agoMerge "MAINT: pytest doesn't have any more python 3.12 deprecations" into main
Federico Caselli [Tue, 17 Sep 2024 18:16:40 +0000 (18:16 +0000)] 
Merge "MAINT: pytest doesn't have any more python 3.12 deprecations" into main

10 months agoupdate MonetDB dialect information (#11884)
Yunus Koning [Tue, 17 Sep 2024 18:05:09 +0000 (20:05 +0200)] 
update MonetDB dialect information (#11884)

10 months agoBump pypa/cibuildwheel from 2.20.0 to 2.21.1 (#11885)
dependabot[bot] [Tue, 17 Sep 2024 18:02:26 +0000 (20:02 +0200)] 
Bump pypa/cibuildwheel from 2.20.0 to 2.21.1 (#11885)

Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel) from 2.20.0 to 2.21.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases)
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md)
- [Commits](https://github.com/pypa/cibuildwheel/compare/v2.20.0...v2.21.1)

---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
10 months agocherry-pick changelog update for 2.0.36
Mike Bayer [Mon, 16 Sep 2024 20:30:25 +0000 (16:30 -0400)] 
cherry-pick changelog update for 2.0.36

10 months agocherry-pick changelog from 2.0.35
Mike Bayer [Mon, 16 Sep 2024 20:30:25 +0000 (16:30 -0400)] 
cherry-pick changelog from 2.0.35

10 months agorequire insert_returning for new EagerLoadTest DML suite
Mike Bayer [Mon, 16 Sep 2024 17:43:30 +0000 (13:43 -0400)] 
require insert_returning for new EagerLoadTest DML suite

Change-Id: I354e3ba68ba6efaab6618e514d11355d72652bb5

10 months agoMerge "Merge url query args to opts in mariadbconnector like mysqldb" into main
Michael Bayer [Sun, 15 Sep 2024 23:16:49 +0000 (23:16 +0000)] 
Merge "Merge url query args to opts in mariadbconnector like mysqldb" into main

10 months agoMerge url query args to opts in mariadbconnector like mysqldb
Tobias Petersen [Fri, 13 Sep 2024 18:34:33 +0000 (14:34 -0400)] 
Merge url query args to opts in mariadbconnector like mysqldb

Fixed issue in mariadbconnector dialect where query string arguments that
weren't checked integer or boolean arguments would be ignored, such as
string arguments like ``unix_socket``, etc.  As part of this change, the
argument parsing for particular elements such as ``client_flags``,
``compress``, ``local_infile`` has been made more consistent across all
MySQL / MariaDB dialect which accept each argument. Pull request courtesy
Tobias Alex-Petersen.

Fixes: #11870
Closes: #11869
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11869
Pull-request-sha: 8fdcabc83b548e3fc19aa1625035d43ebc0e1875

Change-Id: I3a11a0e65e118c94928027478409488b0d5e94f8

10 months agoUpdate index.rst (#11799)
Vitalii Fuglaev [Fri, 13 Sep 2024 20:03:04 +0000 (23:03 +0300)] 
Update index.rst (#11799)

08/28/2024 была обновлена версия sqlalchemy-greenplum в PyPI и сейчас она поддерживает SQLAlchemy 2.0 и выше

10 months agoFix subquery typos in documentation and changelog (#11807)
Studnikov Dmitry [Fri, 13 Sep 2024 20:01:26 +0000 (23:01 +0300)] 
Fix subquery typos in documentation and changelog (#11807)

* fix: subquery typo

* fix: subquery typo in changelog

---------

Co-authored-by: Dmitry Studnikov <dmitrii.studnikov@mysky.com>
10 months agoMAINT: pytest doesn't have any more python 3.12 deprecations
Brigitta Sipőcz [Fri, 13 Sep 2024 20:01:04 +0000 (16:01 -0400)] 
MAINT: pytest doesn't have any more python 3.12 deprecations

<!-- Provide a general summary of your proposed changes in the Title field above -->

### Description
<!-- Describe your changes in detail -->
I believe this workaround is not needed any more, pytest doesn't have any more python deprecations. (Arguably neither 3.13)

### Checklist
<!-- go over following points. check them with an `x` if they do apply, (they turn into clickable checkboxes once the PR is submitted, so no need to do everything at once)

-->

This pull request is:

- [x] Tweek to the (testing) infrastructure
        - New category as I didn't think this PR fit in any of the 3 options offered.

- [ ] A documentation / typographical / small typing error fix
- Good to go, no issue or tests are needed
- [ ] A short code fix
- please include the issue number, and create an issue if none exists, which
  must include a complete example of the issue.  one line code fixes without an
  issue and demonstration will not be accepted.
- Please include: `Fixes: #<issue number>` in the commit message
- please include tests.   one line code fixes without tests will not be accepted.
- [ ] A new feature implementation
- please include the issue number, and create an issue if none exists, which must
  include a complete example of how the feature would look.
- Please include: `Fixes: #<issue number>` in the commit message
- please include tests.

**Have a nice day!**

Closes: #11838
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11838
Pull-request-sha: 7d500de8707cb6d89ba59922d0671afc4062de82

Change-Id: I5fef8ee799fa2dbed1d00f5a779d6b25ce3e5ae8

10 months agoFix wrong ticket reference in changelog for #11820 (#11867)
Frazer McLean [Fri, 13 Sep 2024 19:57:47 +0000 (21:57 +0200)] 
Fix wrong ticket reference in changelog for #11820 (#11867)

10 months agoMerge "fix most broken links" into main
Michael Bayer [Fri, 13 Sep 2024 17:20:18 +0000 (17:20 +0000)] 
Merge "fix most broken links" into main

10 months agoMerge "MAINT: cleanup the lasts of datetime.utcnow()" into main
Michael Bayer [Fri, 13 Sep 2024 17:19:43 +0000 (17:19 +0000)] 
Merge "MAINT: cleanup the lasts of datetime.utcnow()" into main

10 months agoFix use of typing.Literal on Python 3.8 and 3.9
Frazer McLean [Thu, 5 Sep 2024 11:29:47 +0000 (07:29 -0400)] 
Fix use of typing.Literal on Python 3.8 and 3.9

Fixed issue where it was not possible to use ``typing.Literal`` with
``Mapped[]`` on Python 3.8 and 3.9.  Pull request courtesy Frazer McLean.

Fixes: #11820
Closes: #11825
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11825
Pull-request-sha: e1e50a97d2a6e0e9ef7ba8dc1a5f07d252e79fa4

Change-Id: Idf04326abcba45813ad555127e81d581a0353587

10 months agoMerge "deprecate joinedload, subqueryload with DML; use correct statement" into main
Michael Bayer [Tue, 10 Sep 2024 14:35:09 +0000 (14:35 +0000)] 
Merge "deprecate joinedload, subqueryload with DML; use correct statement" into main

10 months agodeprecate joinedload, subqueryload with DML; use correct statement
Mike Bayer [Mon, 9 Sep 2024 13:21:20 +0000 (09:21 -0400)] 
deprecate joinedload, subqueryload with DML; use correct statement

An ORM exception is raised if :func:`_orm.joinedload` or
:func:`_orm.subqueryload` are used as a top level option against a
statement that is not a SELECT statement, such as with an
``insert().returning()``.   There are no JOINs in INSERT statements nor is
there a "subquery" that can be repurposed for subquery eager loading, and
for UPDATE/DELETE joinedload does not support these either, so it is never
appropriate for this use to pass silently.

Fixed issue where using eager loaders such as :func:`_orm.selectinload`
with additional criteria in combination with ORM DML such as
:func:`_sql.insert` with RETURNING would not correctly set up internal
contexts required for caching to work correctly, leading to incorrect
results.

Fixes: #11853
Fixes: #11855
Change-Id: Ibbf46ba4f83e472441074c3257e23388e0fcec37

10 months agoMerge "test for Concatenable in ORM evaluator for concat_op" into main
Michael Bayer [Mon, 9 Sep 2024 18:34:54 +0000 (18:34 +0000)] 
Merge "test for Concatenable in ORM evaluator for concat_op" into main

10 months agotest for Concatenable in ORM evaluator for concat_op
Mike Bayer [Sat, 7 Sep 2024 21:41:16 +0000 (17:41 -0400)] 
test for Concatenable in ORM evaluator for concat_op

Fixed issue in ORM evaluator where two datatypes being evaluated with the
SQL concatenator operator would not be checked for
:class:`.UnevaluatableError` based on their datatype; this missed the case
of :class:`_postgresql.JSONB` values being used in a concatenate operation
which is supported by PostgreSQL as well as how SQLAlchemy renders the SQL
for this operation, but does not work at the Python level. By implementing
:class:`.UnevaluatableError` for this combination, ORM update statements
will now fall back to "expire" when a concatenated JSON value used in a SET
clause is to be synchronized to a Python object.

Fixes: #11849
Change-Id: Iccd97edf57b99b9a606ab3a47d2e3e5b63f0db07

10 months agorevert SQLite CHECK constraint changes and add new tests
Mike Bayer [Thu, 5 Sep 2024 17:21:17 +0000 (13:21 -0400)] 
revert SQLite CHECK constraint changes and add new tests

The changes made for SQLite CHECK constraint reflection in versions 2.0.33
and 2.0.34 , :ticket:`11832` and :ticket:`11677`, have now been fully
reverted, as users continued to identify existing use cases that stopped
working after this change.   For the moment, because SQLite does not
provide any consistent way of delivering information about CHECK
constraints, SQLAlchemy is limited in what CHECK constraint syntaxes can be
reflected, including that a CHECK constraint must be stated all on a
single, independent line (or inline on a column definition)  without
newlines, tabs in the constraint definition or unusual characters in the
constraint name.  Overall, reflection for SQLite is tailored towards being
able to reflect CREATE TABLE statements that were originally created by
SQLAlchemy DDL constructs.  Long term work on a DDL parser that does not
rely upon regular expressions may eventually improve upon this situation.
A wide range of additional cross-dialect CHECK constraint reflection tests
have been added as it was also a bug that these changes did not trip any
existing tests.

Fixes: #11840
Change-Id: Iaa4f9651d0c3dd5dbb530ccaa6688169eb7f3bb8

10 months agoMAINT: cleanup the lasts of datetime.utcnow()
Brigitta Sipőcz [Fri, 6 Sep 2024 06:44:53 +0000 (02:44 -0400)] 
MAINT: cleanup the lasts of datetime.utcnow()

<!-- Provide a general summary of your proposed changes in the Title field above -->

### Description
<!-- Describe your changes in detail -->

I'm chasing some loose datetime.datetime.utcnow() deprecation warning in some test suites, and one of these was seemingly coming from sqlalchemy. It wasn't, but nevertheless these minor cleanup changes may still be found useful.

### Checklist
<!-- go over following points. check them with an `x` if they do apply, (they turn into clickable checkboxes once the PR is submitted, so no need to do everything at once)

-->

This pull request is:

- [x] A documentation / typographical / small typing error fix
- Good to go, no issue or tests are needed

**Have a nice day!**

Closes: #11736
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11736
Pull-request-sha: 9bee8af8d1082c3cde5f64c78f1e565ef4ab14cd

Change-Id: Ib1b85fa3d66b665165d908e7c8394482b714c57f

11 months agocherry-pick changelog update for 1.4.55
Mike Bayer [Thu, 5 Sep 2024 15:54:33 +0000 (11:54 -0400)] 
cherry-pick changelog update for 1.4.55

11 months agocherry-pick changelog from 1.4.54
Mike Bayer [Thu, 5 Sep 2024 15:54:32 +0000 (11:54 -0400)] 
cherry-pick changelog from 1.4.54

11 months agomove py313 tests to greenlet main
Mike Bayer [Thu, 5 Sep 2024 14:06:36 +0000 (10:06 -0400)] 
move py313 tests to greenlet main

vstinner's branch merged and was immediately deleted from
that repo.  greenlet still not released.  so keep on
chasing it :/

Change-Id: I79927061566db75b4e26b3dbc39b817786531db6

11 months agoFix the runtime issue related to the join operation in the association example (...
BOBOTANG [Wed, 4 Sep 2024 18:26:52 +0000 (02:26 +0800)] 
Fix the runtime issue related to the join operation in the association example (#11721)

11 months agoInclude operators in postgres JSONB documentation (#11828)
Jimmy AUDEBERT [Wed, 4 Sep 2024 17:23:53 +0000 (19:23 +0200)] 
Include operators in postgres JSONB documentation (#11828)

11 months agofix typo in `elect.slice` docs
Federico Caselli [Wed, 4 Sep 2024 17:10:31 +0000 (19:10 +0200)] 
fix typo in `elect.slice` docs

Change-Id: I859b48e320a04cedc6084d067cb20b89ac5d76bb

11 months agocherry-pick changelog update for 2.0.35
Mike Bayer [Wed, 4 Sep 2024 15:19:59 +0000 (11:19 -0400)] 
cherry-pick changelog update for 2.0.35

11 months agocherry-pick changelog from 2.0.34
Mike Bayer [Wed, 4 Sep 2024 15:19:59 +0000 (11:19 -0400)] 
cherry-pick changelog from 2.0.34

11 months agoFix regular expression for `SQLiteDialect.get_check_constraints`
Mike Bayer [Wed, 4 Sep 2024 12:45:52 +0000 (08:45 -0400)] 
Fix regular expression for `SQLiteDialect.get_check_constraints`

Fixed regression in SQLite reflection caused by :ticket:`11677` which
interfered with reflection for CHECK constraints that were followed
by other kinds of constraints within the same table definition.   Pull
request courtesy Harutaka Kawamura.

Fixes: #11832
Closes: #11834
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11834
Pull-request-sha: a10fcef45ccfad6ebf17ec94fc48d0965f0d4123

Change-Id: I50bcc7aa727f73be235895d154cd859f19adda09

11 months agouse proper functions to get typing origin, args
Mike Bayer [Wed, 4 Sep 2024 03:08:21 +0000 (23:08 -0400)] 
use proper functions to get typing origin, args

Fixed regression caused by issue :ticket:`11814` which broke support for
certain flavors of :pep:`593` ``Annotated`` in the type_annotation_map when
builtin types such as ``list``, ``dict`` were used without an element type.
While this is an incomplete style of typing, these types nonetheless
previously would be located in the type_annotation_map correctly.

Fixes: #11831
Change-Id: I6ea7fc1bce462d44ffcf67ef18b60050dfc2c91e

11 months agocherry-pick changelog update for 2.0.34
Mike Bayer [Tue, 3 Sep 2024 17:22:39 +0000 (13:22 -0400)] 
cherry-pick changelog update for 2.0.34

11 months agocherry-pick changelog from 2.0.33
Mike Bayer [Tue, 3 Sep 2024 17:22:38 +0000 (13:22 -0400)] 
cherry-pick changelog from 2.0.33

11 months agochangelog categorization fixes, typos
Mike Bayer [Tue, 3 Sep 2024 16:54:22 +0000 (12:54 -0400)] 
changelog categorization fixes, typos

Change-Id: I1292ad4c8a671a98d23861281a8d36e2ab8a6f55

11 months agoMerge "add asyncio.CancelledError to terminate conditions" into main
Michael Bayer [Tue, 3 Sep 2024 14:15:09 +0000 (14:15 +0000)] 
Merge "add asyncio.CancelledError to terminate conditions" into main

11 months agoMerge "unpin setuptools" into main
Michael Bayer [Mon, 2 Sep 2024 23:44:39 +0000 (23:44 +0000)] 
Merge "unpin setuptools" into main

11 months agoMerge "add "The server failed to resume the transaction" to pymssql" into main
Michael Bayer [Mon, 2 Sep 2024 23:42:46 +0000 (23:42 +0000)] 
Merge "add "The server failed to resume the transaction" to pymssql" into main

11 months agoadd "The server failed to resume the transaction" to pymssql
Mike Bayer [Mon, 2 Sep 2024 15:22:36 +0000 (11:22 -0400)] 
add "The server failed to resume the transaction" to pymssql

Added error "The server failed to resume the transaction" to the list of
error strings for the pymssql driver in determining a disconnect scenario,
as observed by one user using pymssql under otherwise unknown conditions as
leaving an unusable connection in the connection pool which fails to ping
cleanly.

Fixes: #11822
Change-Id: I1cf98046978b10775f19531878b597d32b056f13

11 months agodont erase transaction if rollback/commit failed outside of asyncpg
Mike Bayer [Mon, 2 Sep 2024 14:37:29 +0000 (10:37 -0400)] 
dont erase transaction if rollback/commit failed outside of asyncpg

Fixed critical issue in the asyncpg driver where a rollback or commit that
fails specifically for the ``MissingGreenlet`` condition or any other error
that is not raised by asyncpg itself would discard the asyncpg transaction
in any case, even though the transaction were still idle, leaving to a
server side condition with an idle transaction that then goes back into the
connection pool.   The flags for "transaction closed" are now not reset for
errors that are raised outside of asyncpg itself.  When asyncpg itself
raises an error for ``.commit()`` or ``.rollback()``, asyncpg does then
discard of this transaction.

Fixes: #11819
Change-Id: I12f0532788b03ea63fb47a7af21e07c37effb070

11 months agounpin setuptools
Mike Bayer [Mon, 2 Sep 2024 13:13:27 +0000 (09:13 -0400)] 
unpin setuptools

This removes the pin that was placed in 2607262110bdc5c5dc96fc19ddca895a15a58e4e

The pin for ``setuptools<69.3`` in ``pyproject.toml`` has been
removed.  This pin was to prevent a sudden change to :pep:`625` in
setuptools from taking place which changes the file name of SQLAlchemy's
source distribution on pypi to be an all lower case name, which is very
likely to cause problems with various build environments that expected a
particular naming style.  However, the presence of this pin is now holding
back environments that otherwise want to use a newer setuptools, so we've
decided to move forward with this change, with the assumption that build
environments will have largely accommodated the setuptools change by
now.

References: #11818
Change-Id: I0cd9ab0512004669a8f0aa0cb7f560d89a2da2bd

11 months agoadd asyncio.CancelledError to terminate conditions
Mike Bayer [Mon, 2 Sep 2024 15:18:35 +0000 (11:18 -0400)] 
add asyncio.CancelledError to terminate conditions

Revising the asyncpg ``terminate()`` fix first made in :ticket:`10717`
which improved the resiliency of this call under all circumstances, adding
``asyncio.CancelledError`` to the list of exceptions that are intercepted
as failing for a graceful ``.close()`` which will then proceed to call
``.terminate()``.

Fixes: #11821
Change-Id: Ic5e21cd18cc5517aae372560c52b2b2396c65483

11 months agore-process args for builtin generic types
Mike Bayer [Sat, 31 Aug 2024 16:56:00 +0000 (12:56 -0400)] 
re-process args for builtin generic types

Improvements to the ORM annotated declarative type map lookup dealing with
composed types such as ``dict[str, Any]`` linking to JSON (or others) with
or without "future annotations" mode.

There's apparently a big incompatiblity in types from typing vs.
Python builtins in the way they genericize.   The typing library makes
it very difficult to distinguish between the two sets of types.  This
patch is a bit slash and burn to work around all this.   These should
likely be reported as bugs in the Python standard library if they
aren't already.

Fixes: #11814
Change-Id: I56a62701d5e883be04df7f45fd9429bb9c1c9a6f

11 months agoMerge "Fix select.with_only_columns type hints" into main
Michael Bayer [Sat, 31 Aug 2024 15:00:16 +0000 (15:00 +0000)] 
Merge "Fix select.with_only_columns type hints" into main

11 months agopass to_metadata argument to Enum.copy()
Mike Bayer [Thu, 29 Aug 2024 14:04:47 +0000 (10:04 -0400)] 
pass to_metadata argument to Enum.copy()

Fixed bug where the ``metadata`` element of an ``Enum`` datatype would not
be transferred to the new :class:`.MetaData` object when the type had been
copied via a :meth:`.Table.to_metadata` operation, leading to inconsistent
behaviors within create/drop sequences.

Fixes: #11802
Change-Id: Ibbc93aa31bdfde0d67a9530f41a08e826c17d58e

11 months agoFix select.with_only_columns type hints
Federico Caselli [Tue, 27 Aug 2024 18:02:00 +0000 (20:02 +0200)] 
Fix select.with_only_columns type hints

Fixes: #11782
Change-Id: Idce218a9730986d3ca70547c83aa1c0f8b5ee5b2

11 months agoMerge "Fix memory leak on top-level _ModuleMarker." into main
Michael Bayer [Wed, 28 Aug 2024 15:55:06 +0000 (15:55 +0000)] 
Merge "Fix memory leak on top-level _ModuleMarker." into main

11 months agoUpdate SQLite UNIQUE inline constraint parsing to handle tabs
John A Stevenson [Mon, 26 Aug 2024 15:05:38 +0000 (11:05 -0400)] 
Update SQLite UNIQUE inline constraint parsing to handle tabs

Improvements to the regex used by the SQLite dialect to reflect the name
and contents of a UNIQUE constraint that is defined inline within a column
definition inside of a SQLite CREATE TABLE statement, accommodating for tab
characters present within the column / constraint line. Pull request
courtesy John A Stevenson.

Fixes: #11746
Closes: #11759
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11759
Pull-request-sha: 5752491154ad19e29abec8d69fa4076d996d964e

Change-Id: I048a90c992bfaf6857c1150f50bf3c6cc5697095

11 months agoFix memory leak on top-level _ModuleMarker.
Federico Caselli [Tue, 27 Aug 2024 17:20:44 +0000 (19:20 +0200)] 
Fix memory leak on top-level _ModuleMarker.

Correctly cleanup the internal top-level module registry when no
inner modules or classes are registered into it.

Fixes: #11788
Change-Id: I489dd6394dd3f14458379368b8c8f18d5a0bb109

11 months agoUpdate link for sqlalchemy-pytds dialect (#11786)
Gord Thompson [Sun, 25 Aug 2024 21:53:59 +0000 (15:53 -0600)] 
Update link for sqlalchemy-pytds dialect (#11786)

11 months agofix most broken links
Federico Caselli [Sun, 11 Aug 2024 09:55:15 +0000 (11:55 +0200)] 
fix most broken links

This was achieved by running Broken Link Checker
https://github.com/stevenvachon/broken-link-checker
on the docs

Change-Id: Ic415f9435b3c817e518fbbad46ac8fb9e8503d15

11 months agoadd missing slash for sqlite URL with explicit :memory:
Mike Bayer [Wed, 21 Aug 2024 14:49:27 +0000 (10:49 -0400)] 
add missing slash for sqlite URL with explicit :memory:

Fixes: #11772
Change-Id: I3bdb1c81c5a503cb16143c9d1c130ec79769fbca

11 months agoRevert "Update bug_report.yaml"
Mike Bayer [Tue, 20 Aug 2024 02:40:44 +0000 (22:40 -0400)] 
Revert "Update bug_report.yaml"

This reverts commit 09f8ff139ab2cbc69c9d8969af5c439b92c8a160.

11 months agoUpdate bug_report.yaml
Michael Bayer [Tue, 20 Aug 2024 02:39:12 +0000 (22:39 -0400)] 
Update bug_report.yaml

11 months agotry a new bug template.
Mike Bayer [Mon, 19 Aug 2024 20:53:34 +0000 (16:53 -0400)] 
try a new bug template.

i really dont want people opening issues, saying things like
"this is not correct", etc.   Let's talk about the problem you
have and what's the ideal outcome.  thanks

Change-Id: Ia74a067f14cc30b84c6710c5a897cc35ce284bf4

11 months agoFix docs link to Oracle Cloud Autonomous Databases (#11762)
Edgar Ramírez Mondragón [Mon, 19 Aug 2024 18:17:54 +0000 (12:17 -0600)] 
Fix docs link to Oracle Cloud Autonomous Databases (#11762)

11 months agoremove print statement
Mike Bayer [Thu, 15 Aug 2024 12:46:13 +0000 (08:46 -0400)] 
remove print statement

Change-Id: I33c9f7daee1034639bb0725b114f6e48803a4fed

11 months agoMerge "Reflect broader range of check constraints for SQLite." into main
Michael Bayer [Thu, 15 Aug 2024 12:38:29 +0000 (12:38 +0000)] 
Merge "Reflect broader range of check constraints for SQLite." into main

11 months agoMerge "omit mysql8 dupe key alias for INSERT..FROM SELECT" into main
Michael Bayer [Wed, 14 Aug 2024 14:28:19 +0000 (14:28 +0000)] 
Merge "omit mysql8 dupe key alias for INSERT..FROM SELECT" into main

11 months agoMerge "de-memoize _proxy_key when new annotations are added" into main
Michael Bayer [Wed, 14 Aug 2024 14:04:42 +0000 (14:04 +0000)] 
Merge "de-memoize _proxy_key when new annotations are added" into main

11 months agoMerge "handle quoted_name instances separately in engine.reflection.cache" into main
Michael Bayer [Tue, 13 Aug 2024 20:45:56 +0000 (20:45 +0000)] 
Merge "handle quoted_name instances separately in engine.reflection.cache" into main

11 months agoReflect broader range of check constraints for SQLite.
Jeff Horemans [Tue, 13 Aug 2024 15:22:51 +0000 (11:22 -0400)] 
Reflect broader range of check constraints for SQLite.

Improvements to the regex used by the SQLite dialect to reflect the name
and contents of a CHECK constraint.  Constraints with newline, tab, or
space characters in either or both the constraint text and constraint name
are now properly reflected.   Pull request courtesy Jeff Horemans.

Fixes: #11677
Closes: #11701
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11701
Pull-request-sha: b2d629f18695ecb08cddeb99d7c2573e1f3d04b2

Change-Id: I2dd06c778e7c130848e418a80004032eb6144e6d

11 months agode-memoize _proxy_key when new annotations are added
Mike Bayer [Mon, 12 Aug 2024 23:50:05 +0000 (19:50 -0400)] 
de-memoize _proxy_key when new annotations are added

Fixed regression from 1.3 where the column key used for a hybrid property
might be populated with that of the underlying column that it returns, for
a property that returns an ORM mapped column directly, rather than the key
used by the hybrid property itself.

Fixes: #11728
Change-Id: Ifb298e46a20f90f6b6a717674f142a87cbceb468

11 months agoomit mysql8 dupe key alias for INSERT..FROM SELECT
Mike Bayer [Tue, 13 Aug 2024 13:13:51 +0000 (09:13 -0400)] 
omit mysql8 dupe key alias for INSERT..FROM SELECT

Fixed issue in MySQL dialect where using INSERT..FROM SELECT in combination
with ON DUPLICATE KEY UPDATE would erroneously render on MySQL 8 and above
the "AS new" clause, leading to syntax failures.  This clause is required
on MySQL 8 to follow the VALUES clause if use of the "new" alias is
present, however is not permitted to follow a FROM SELECT clause.

Fixes: #11731
Change-Id: I254a3db4e9dccd9a76b11fdfe6e38a064ba0b5cf

11 months agoMerge "turn off pyodbc pooling" into main
Michael Bayer [Sun, 11 Aug 2024 20:49:16 +0000 (20:49 +0000)] 
Merge "turn off pyodbc pooling" into main

11 months agoturn off pyodbc pooling
Mike Bayer [Sun, 11 Aug 2024 19:41:36 +0000 (15:41 -0400)] 
turn off pyodbc pooling

new updates of unixodbc are turning this on in CI revealing
that our isolation level tests assume no pooling takes place,
so disable this, which is only at global module level for pyodbc

Change-Id: I971dfddc90d248281e8ca8677a3a41af6de28b86

11 months agoDocs: Dialects/index.rst - Add clickhouse-sqlalchemy pypi link. (#11717)
Gregg Lind [Fri, 9 Aug 2024 19:56:44 +0000 (14:56 -0500)] 
Docs:  Dialects/index.rst - Add clickhouse-sqlalchemy pypi link. (#11717)

Add the Pypi link for the `clickhouse-sqlalchemy` package to Externally supported dialects.

11 months agoFix typo in docs (#11715)
Gabi Nagy [Fri, 9 Aug 2024 19:54:24 +0000 (21:54 +0200)] 
Fix typo in docs (#11715)

11 months agonote prefix_with as a hint mechanism
Mike Bayer [Wed, 7 Aug 2024 18:31:48 +0000 (14:31 -0400)] 
note prefix_with as a hint mechanism

References: #11702
References: #11704
Change-Id: Ieee0780f6d132a29269430fc26de5c0664b16c2e

11 months agohandle quoted_name instances separately in engine.reflection.cache
Masterchen09 [Tue, 6 Aug 2024 18:20:51 +0000 (14:20 -0400)] 
handle quoted_name instances separately in engine.reflection.cache

Fixed issue in internal reflection cache where particular reflection
scenarios regarding same-named quoted_name() constructs would not be
correctly cached.  Pull request courtesy Felix Lüdin.

Fixes: #11687
Closes: #11688
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11688
Pull-request-sha: 43d94273a5b13a89226e60de4b958d5b4ac7ff78

Change-Id: I73273dff532a9d14d54065bc33339874e3cb2716

11 months agorestore generative to with_statement_hint
Mike Bayer [Wed, 7 Aug 2024 16:18:25 +0000 (12:18 -0400)] 
restore generative to with_statement_hint

Fixed regression in :meth:`_sql.Select.with_statement_hint` and others
where the generative behavior of the method stopped producing a copy of the
object.

Fixes: #11703
Change-Id: Ia4482f91f76fae9982dc6b075bf5cfec7042ffa6

11 months agoMerge "Add array_type to SuiteRequirements" into main
Michael Bayer [Wed, 7 Aug 2024 14:14:03 +0000 (14:14 +0000)] 
Merge "Add array_type to SuiteRequirements" into main

11 months agodisable recovery tests for oracledb
Mike Bayer [Wed, 7 Aug 2024 13:10:40 +0000 (09:10 -0400)] 
disable recovery tests for oracledb

this is not holding up in CI and is not a critical feature
for now

Change-Id: Ib9547028265403497c176d96c462d76cd86c967a

11 months agoFix a misreference in inheritance.rst (#11700)
Tao Zhou [Tue, 6 Aug 2024 20:21:44 +0000 (16:21 -0400)] 
Fix a misreference in inheritance.rst (#11700)

12 months agoBump pypa/cibuildwheel from 2.19.2 to 2.20.0 (#11690)
dependabot[bot] [Mon, 5 Aug 2024 21:07:55 +0000 (23:07 +0200)] 
Bump pypa/cibuildwheel from 2.19.2 to 2.20.0 (#11690)

Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel) from 2.19.2 to 2.20.0.
- [Release notes](https://github.com/pypa/cibuildwheel/releases)
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md)
- [Commits](https://github.com/pypa/cibuildwheel/compare/v2.19.2...v2.20.0)

---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
12 months agoAdd array_type to SuiteRequirements
Anders Bogsnes [Mon, 5 Aug 2024 20:28:48 +0000 (16:28 -0400)] 
Add array_type to SuiteRequirements

Added missing ``array_type`` property to the testing suite
``SuiteRequirements`` class.

Closes: #11694
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11694
Pull-request-sha: 24697f6a4346005aa83d8eb06f94bba4cc994862

Change-Id: I192b5b932dfef07043c0c0cfe8ea36b02425a44d

12 months agoadd changelog for #11557
Mike Bayer [Mon, 5 Aug 2024 21:01:08 +0000 (17:01 -0400)] 
add changelog for #11557

also classify for oracle

Change-Id: I725db9c6ae6a8fabe7faf8631113633b338afea4

12 months agocherry-pick changelog update for 2.0.33
Mike Bayer [Mon, 5 Aug 2024 19:08:57 +0000 (15:08 -0400)] 
cherry-pick changelog update for 2.0.33

12 months agocherry-pick changelog from 2.0.32
Mike Bayer [Mon, 5 Aug 2024 19:08:57 +0000 (15:08 -0400)] 
cherry-pick changelog from 2.0.32

12 months agoAdded support for server-side cursor in oracledb async dialect.
Federico Caselli [Thu, 1 Aug 2024 19:16:20 +0000 (21:16 +0200)] 
Added support for server-side cursor in oracledb async dialect.

Added API support for server-side cursors for the oracledb async dialect,
allowing use of the :meth:`_asyncio.AsyncConnection.stream` and similar
stream methods.

Fixes: #10820
Change-Id: I861670ccc20a81ec5ee45132b8059fc2a0359087

12 months agochangelog updates
Mike Bayer [Fri, 2 Aug 2024 13:42:59 +0000 (09:42 -0400)] 
changelog updates

Change-Id: I3c319c15d883b88a4ceae2ea17d3122fcc90fb1f

12 months agoMerge "skip in eager row processors for enable_eagerloads=False" into main
Michael Bayer [Fri, 2 Aug 2024 13:39:07 +0000 (13:39 +0000)] 
Merge "skip in eager row processors for enable_eagerloads=False" into main

12 months agoMerge "escape percents for mysql enum and add suite tests" into main
Michael Bayer [Fri, 2 Aug 2024 13:38:10 +0000 (13:38 +0000)] 
Merge "escape percents for mysql enum and add suite tests" into main

12 months agoMerge "add check for pre-existing history records" into main
Michael Bayer [Fri, 2 Aug 2024 13:36:54 +0000 (13:36 +0000)] 
Merge "add check for pre-existing history records" into main

12 months agobring oracle timeout thing lower
Mike Bayer [Thu, 1 Aug 2024 23:15:57 +0000 (19:15 -0400)] 
bring oracle timeout thing lower

still seeing failures

we may very well have to revert this and mark oracle as not supporting
recovery

Change-Id: I4d48607cb8579dc73c650f5232e4414a408735e2

12 months agoskip in eager row processors for enable_eagerloads=False
Mike Bayer [Thu, 1 Aug 2024 19:58:57 +0000 (15:58 -0400)] 
skip in eager row processors for enable_eagerloads=False

Fixed issue where using the :meth:`_orm.Query.enable_eagerloads` and
:meth:`_orm.Query.yield_per` methods at the same time, in order to disable
eager loading that's configured on the mapper directly, would be silently
ignored, leading to errors or unexpected eager population of attributes.

Fixes: #10834
Change-Id: I6a20bdedf23f6dd4e98ffb49ad784117fe4afdd3

12 months agoadd check for pre-existing history records
Mike Bayer [Thu, 1 Aug 2024 20:41:45 +0000 (16:41 -0400)] 
add check for pre-existing history records

Fixed issue in history_meta example where the "version" column in the
versioned table needs to default to the most recent version number in the
history table on INSERT, to suit the use case of a table where rows are
deleted, and can then be replaced by new rows that re-use the same primary
key identity.  This fix adds an additonal SELECT query per INSERT in the
main table, which may be inefficient; for cases where primary keys are not
re-used, the default function may be omitted.  Patch courtesy  Philipp H.
v. Loewenfeld.

Fixes: #10267
Change-Id: I6b0737a7e871763f95fd636c9ad98b80f3b5808e

12 months agoescape percents for mysql enum and add suite tests
Mike Bayer [Thu, 1 Aug 2024 19:51:00 +0000 (15:51 -0400)] 
escape percents for mysql enum and add suite tests

Fixed issue in MySQL dialect where ENUM values that contained percent signs
were not properly escaped for the driver.

Fixes: #11479
Change-Id: I40d9aba619618603d3abb466f84a793d152b6788

12 months agoMerge "mutate lists in place for return_defaults=True" into main
Michael Bayer [Thu, 1 Aug 2024 19:31:26 +0000 (19:31 +0000)] 
Merge "mutate lists in place for return_defaults=True" into main

12 months agoMerge "Add support for two-phase commit in oracledb." into main
Michael Bayer [Thu, 1 Aug 2024 17:47:00 +0000 (17:47 +0000)] 
Merge "Add support for two-phase commit in oracledb." into main

12 months agomutate lists in place for return_defaults=True
Mike Bayer [Thu, 1 Aug 2024 13:49:55 +0000 (09:49 -0400)] 
mutate lists in place for return_defaults=True

Fixed regression from version 1.4 in
:meth:`_orm.Session.bulk_insert_mappings` where using the
:paramref:`_orm.Session.bulk_insert_mappings.return_defaults` parameter
would not populate the passed in dictionaries with newly generated primary
key values.

Fixes: #11661
Change-Id: I331d81a5b04456f107eb868f882d67773b3eec38