Commit Graph

10240 Commits

Author SHA1 Message Date
Hajime Nakagami 8157554998 do_execute() hook in cymysql dialect 2013-03-07 00:14:46 +09:00
Hajime Nakagami 50cc82b796 mysql+cymysql test_types.py 2013-03-06 00:21:54 +09:00
Mike Bayer a436984663 merge default 2013-03-04 12:50:22 -05:00
Mike Bayer 029b79052c - add some more transaction states so that we deliver a more accurate
message for [ticket:2662]; after_commit() is called within "committed"
state, not prepared, and no SQL can be emitted for prepared or committed
- consolidate state assertions in session transaction, use just one
method
- add more unit tests for these assertions
2013-03-04 12:50:11 -05:00
Mike Bayer 43aa4a42d6 merge default 2013-03-03 19:26:36 -05:00
Mike Bayer f4679ea26c yikes, print statement ! 2013-03-03 19:25:49 -05:00
Mike Bayer b3e454bd17 merge default 2013-03-03 19:22:54 -05:00
Mike Bayer 383c3fede5 - this assertion moves out to configure_mappers() now 2013-03-03 19:22:43 -05:00
Mike Bayer 3f014926f4 fix non2.5 compat @property usage 2013-03-03 19:17:03 -05:00
Mike Bayer 8d9038b19c dont need this conditional here 2013-03-03 14:02:54 -05:00
Mike Bayer a77567700e merge default 2013-03-03 13:59:25 -05:00
Mike Bayer 75a3f84e5f - Improved checking for an existing backref name conflict during
mapper configuration; will now test for name conflicts on
superclasses and subclasses, in addition to the current mapper,
as these conflicts break things just as much.  This is new for
0.8, but see below for a warning that will also be triggered
in 0.7.11.
- Improved the error message emitted when a "backref loop" is detected,
that is when an attribute event triggers a bidirectional
assignment between two other attributes with no end.
This condition can occur not just when an object of the wrong
type is assigned, but also when an attribute is mis-configured
to backref into an existing backref pair.  Also in 0.7.11.
- A warning is emitted when a MapperProperty is assigned to a mapper
that replaces an existing property, if the properties in question
aren't plain column-based properties.   Replacement of relationship
properties is rarely (ever?) what is intended and usually refers to a
mapper mis-configuration.   Also in 0.7.11.
[ticket:2674]
2013-03-03 13:51:54 -05:00
Mike Bayer b83dd4dc22 Can set/change the "cascade" attribute on a :func:.relationship
construct after it's been constructed already.  This is not
a pattern for normal use but we like to change the setting
for demonstration purposes in tutorials.
2013-03-02 20:27:53 -05:00
Mike Bayer 98fea3e3dc skip this test for PG, jenkins having failures only when the full suite is run 2013-03-02 17:56:49 -05:00
Mike Bayer b0b4bf9838 merge default 2013-03-02 17:48:49 -05:00
Mike Bayer 67f5c4a96d - add support for introductory notes following .. changelog:: directive 2013-03-02 17:48:22 -05:00
Mike Bayer 6ddfe3b390 - :meth:.MetaData.create_all and :meth:.MetaData.drop_all will
now accommodate an empty list as an instruction to not create/drop
any items, rather than ignoring the collection. [ticket:2664].
This is a behavioral change and extra notes to the changelog
and migration document have been added.

- create a new test suite for exercising codepaths
in engine/ddl.py
2013-03-02 17:47:58 -05:00
Mike Bayer 7090ca9b09 cleanup 2013-03-02 16:40:07 -05:00
Mike Bayer 45ba7b6e0e - some linter cleanup, though have disabled the newer linter rules which are just
too much for now
2013-03-02 16:37:58 -05:00
Mike Bayer 36ed056e0c merge this 2013-03-02 16:31:26 -05:00
Mike Bayer d6b4c2edb5 merge 0.7 changelog 2013-03-02 16:26:10 -05:00
Mike Bayer aa6a6cbf89 merge from 0.8 2013-03-02 16:25:50 -05:00
Mike Bayer 133e8fd388 - Fixed an import of "logging" in test_execute which was not
working on some linux platforms.  Also in 0.7.11.
- only need "logging.handlers" here, "logging" comes in implicitly
2013-03-02 16:20:49 -05:00
Hajime Nakagami a40c50c3db merge from default 2013-03-02 23:34:11 +09:00
Hajime Nakagami 62e3560e4d fix decorator position 2013-03-02 15:30:43 +09:00
Hajime Nakagami 68c7827d69 is_disconnect() in cymysql dialect 2013-03-02 13:37:00 +09:00
Hajime Nakagami 979156c985 modify _extract_error_code() at cymysql dialect 2013-03-02 08:57:45 +09:00
Hajime Nakagami ddca4d30a1 not return unicode string in cymysql dialect 2013-03-02 02:13:05 +09:00
Hajime Nakagami 0cd4b6f805 fix easy miss 2013-03-01 23:58:28 +09:00
Hajime Nakagami af3689191e fix easy miss 2013-03-01 23:45:02 +09:00
Hajime Nakagami 46edfb9872 cython's result_processor() 2013-03-01 23:27:39 +09:00
Hajime Nakagami 220f2b851a mymysql dialect 2013-03-01 00:00:18 +09:00
Mike Gilbert 05eb72d431 test_execute: import logging.handlers to fix AttributeError
See also: https://bugs.gentoo.org/show_bug.cgi?id=458684
2013-02-27 15:01:37 -05:00
Mike Bayer a205a31bc2 merge default 2013-02-26 12:39:38 -05:00
Mike Bayer d9a7f2dbd5 typo 2013-02-26 12:39:26 -05:00
Hajime Nakagami b8ba4f23a5 return erro_code cymysql dialects 2013-02-26 22:57:16 +09:00
Mike Bayer 6a1d81fcfe merge default 2013-02-25 19:27:52 -05:00
Mike Bayer 07cc4ecf05 - A clear error message is emitted if an event handler
attempts to emit SQL on a Session within the after_commit()
handler, where there is not a viable transaction in progress.
[ticket:2662]
- rework how SessionTransaction maintains state, using symbols
instead.
- add lots of notes and cross-linking for session events.
- add a link to :func:`.select()` within :meth:`.FromClause.select`.
2013-02-25 19:27:07 -05:00
Mike Bayer 95297c3544 Detection of a primary key change within the process
of cascading a natural primary key update will succeed
even if the key is composite and only some of the
attributes have changed.
[ticket:2665]
2013-02-25 18:55:09 -05:00
Mike Bayer 4715aadab3 this step is not needed 2013-02-25 18:39:30 -05:00
Hajime Nakagami 7bb5f463df fix cymysql's _extact_error_code() for py3 2013-02-26 00:30:27 +09:00
Hajime Nakagami 105c991c89 cython's _extract_error_code() 2013-02-25 23:42:11 +09:00
Mike Bayer 525a218759 merge default 2013-02-24 14:06:46 -05:00
Mike Bayer 5eb8864463 - repair "map to selectable" example, place a caveat that this isn't
something people should be pursuing
2013-02-24 14:06:35 -05:00
Mike Bayer 46b42b3bbd move this test to have its own data, avoid FK violations 2013-02-21 15:45:36 -05:00
Hajime Nakagami 4eac4f4be1 avoid drop table in mysql+cymysql test because of deadlock 2013-02-22 01:29:43 +09:00
Hajime Nakagami d6472a81a7 merge from default 2013-02-21 23:12:29 +09:00
Mike Bayer 26fb4b8163 - Added new helper function :func:.was_deleted, returns True
if the given object was the subject of a :meth:`.Session.delete`
operation.
- An object that's deleted from a session will be de-associated with
that session fully after the transaction is committed, that is
the :func:`.object_session` function will return None.
[ticket:2658]
2013-02-20 18:24:46 -05:00
Mike Bayer 6d1c473c47 - pep8 cleanup
- some global cleanup
2013-02-20 18:15:15 -05:00
Mike Bayer 5cda7ab85d merge default 2013-02-18 18:49:20 -05:00