github sqlalchemy/sqlalchemy rel_1_4_16
1.4.16

latest releases: rel_2_0_36, rel_2_0_35, rel_1_4_54...
3 years ago

1.4.16

Released: May 28, 2021

general

  • [general] [bug] Resolved various deprecation warnings which were appearing as of Python
    version 3.10.0b1.

    References: #6540, #6543

orm

  • [orm] [bug] Fixed issue when using _orm.relationship.cascade_backrefs
    parameter set to False, which per change_5150 is set to become
    the standard behavior in SQLAlchemy 2.0, where adding the item to a
    collection that uniquifies, such as set or dict would fail to fire
    a cascade event if the object were already associated in that collection
    via the backref. This fix represents a fundamental change in the collection
    mechanics by introducing a new event state which can fire off for a
    collection mutation even if there is no net change on the collection; the
    action is now suited using a new event hook
    _orm.AttributeEvents.append_wo_mutation().

    References: #6471

  • [orm] [bug] [regression] Fixed regression involving clause adaption of labeled ORM compound
    elements, such as single-table inheritance discriminator expressions with
    conditionals or CASE expressions, which could cause aliased expressions
    such as those used in ORM join / joinedload operations to not be adapted
    correctly, such as referring to the wrong table in the ON clause in a join.

    This change also improves a performance bump that was located within the
    process of invoking _sql.Select.join() given an ORM attribute
    as a target.

    References: #6550

  • [orm] [bug] [regression] Fixed regression where the full combination of joined inheritance, global
    with_polymorphic, self-referential relationship and joined loading would
    fail to be able to produce a query with the scope of lazy loads and object
    refresh operations that also attempted to render the joined loader.

    References: #6495

  • [orm] [bug] Enhanced the bind resolution rules for _orm.Session.execute() so that
    when a non-ORM statement such as an _sql.insert() construct
    nonetheless is built against ORM objects, to the greatest degree possible
    the ORM entity will be used to resolve the bind, such as for a
    _orm.Session that has a bind map set up on a common superclass
    without specific mappers or tables named in the map.

    References: #6484

engine

  • [engine] [bug] Fixed issue where an @ sign in the database portion of a URL would not
    be interpreted correctly if the URL also had a username:password section.

    References: #6482

  • [engine] [bug] Fixed a long-standing issue with URL where query parameters
    following the question mark would not be parsed correctly if the URL did
    not contain a database portion with a backslash.

    References: #6329

sql

  • [sql] [bug] [regression] Fixed regression in dynamic loader strategy and _orm.relationship()
    overall where the _orm.relationship.order_by parameter were
    stored as a mutable list, which could then be mutated when combined with
    additional "order_by" methods used against the dynamic query object,
    causing the ORDER BY criteria to continue to grow repetitively.

    References: #6549

mssql

  • [mssql] [usecase] Implemented support for a _sql.CTE construct to be used directly
    as the target of a _sql.delete() construct, i.e. "WITH ... AS cte
    DELETE FROM cte". This appears to be a useful feature of SQL Server.

    References: #6464

misc

  • [bug] [ext] Fixed a deprecation warning that was emitted when using
    _automap.automap_base() without passing an existing
    Base.

    References: #6529

  • [bug] [pep484] Remove pep484 types from the code.
    Current effort is around the stub package, and having typing in
    two places makes thing worse, since the types in the SQLAlchemy
    source were usually outdated compared to the version in the stubs.

    References: #6461

  • [bug] [ext] [regression] Fixed regression in the sqlalchemy.ext.instrumentation extension that
    prevented instrumentation disposal from working completely. This fix
    includes both a 1.4 regression fix as well as a fix for a related issue
    that existed in 1.3 also. As part of this change, the
    sqlalchemy.ext.instrumentation.InstrumentationManager class now
    has a new method unregister(), which replaces the previous method
    dispose(), which was not called as of version 1.4.

    References: #6390

Don't miss a new sqlalchemy release

NewReleases is sending notifications on new releases.