summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/dialects/postgresql/psycopg2.py
Commit message (Collapse)AuthorAgeFilesLines
* Psycopg2 JSONB support.pr/145Mateusz Susik2014-10-241-2/+14
|
* - clean up unicode docs and clarify that client_encodingMike Bayer2014-10-071-13/+53
| | | | | at the engine level is not the same thing as at the connect args level.
* - A revisit to this issue first patched in 0.9.5, apparentlyMike Bayer2014-09-291-5/+9
| | | | | | | | | | psycopg2's ``.closed`` accessor is not as reliable as we assumed, so we have added an explicit check for the exception messages "SSL SYSCALL error: Bad file descriptor" and "SSL SYSCALL error: EOF detected" when detecting an is-disconnect scenario. We will continue to consult psycopg2's connection.closed as a first check. fixes #3021
* - apply pep8 formatting to sqlalchemy/sql, sqlalchemy/util, sqlalchemy/dialects,Brian Jarrett2014-07-201-56/+71
| | | | sqlalchemy/orm, sqlalchemy/event, sqlalchemy/testing
* - break up the <authors> copyright comment as part of a passMike Bayer2014-07-091-1/+2
| | | | to get all flake8 passing
* - changelog + docs for pg8000 transaction isolation levelMike Bayer2014-05-301-0/+6
|
* update commentsMike Bayer2014-05-301-4/+6
|
* Merge branch 'psycopg_disconnect' of https://github.com/dirkmueller/sqlalchemyMike Bayer2014-05-301-1/+5
|\
| * Another Variant for detecting if a connection is closedpr/87Dirk Mueller2014-05-111-1/+5
| | | | | | | | | | | | | | If there is a closed attribute on the connection and it is true, return true. Implements a todo in the code and helps in one specific disconnect case where it previously did not match because the error message was "unknown error".
* | Merged in mineo/sqlalchemy/mineo/posgtresql-postgresql-1399232068499 (pull ↵Mike Bayer2014-05-121-1/+1
|\ \ | | | | | | | | | | | | | | | request #17) Posgtresql -> PostgreSQL
| * | Posgtresql -> PostgreSQLWieland Hoffmann2014-05-041-1/+1
| |/
* | Documentation fix-up: "its" vs. "it's"pr/91Matthias Urlichs2014-05-111-1/+1
|/ | | | | | | | | Removed ungrammatical apostrophes from documentation, replacing "it's" with "its" where appropriate (but in a few cases with "it is" when that read better). While doing that, I also fixed a couple of minor typos etc. as I noticed them.
* Fix many typos throughout the codebasepr/85Alex Gaynor2014-04-261-2/+2
| | | | Found using: https://github.com/intgr/topy
* added an SSL related connection errorantti_haapala2014-04-111-1/+3
|
* - Fixed ORM bug where changing the primary key of an object, then markingMike Bayer2014-03-281-1/+4
| | | | | | | | | | | | | it for DELETE would fail to target the correct row for DELETE. Then to compound matters, basic "number of rows matched" checks were not being performed. Both issues are fixed, however note that the "rows matched" check requires so-called "sane multi-row count" functionality; the DBAPI's executemany() method must count up the rows matched by individual statements and SQLAlchemy's dialect must mark this feature as supported, currently applies to some mysql dialects, psycopg2, sqlite only. fixes #3006 - Enabled "sane multi-row count" checking for the psycopg2 DBAPI, as this seems to be supported as of psycopg2 2.0.9.
* - Added an additional message to psycopg2 disconnect detection,Mike Bayer2014-02-191-0/+1
| | | | | | "could not send data to server", which complements the existing "could not receive data from server" and has been observed by users, fixes #2936
* - add documentation regarding native hstore flag, psycopg2Mike Bayer2014-02-161-4/+31
| | | | hstore extension. #2959
* - happy new yearMike Bayer2014-01-051-1/+1
|
* - make the json serializer and deserializer per-dialect, so that we areMike Bayer2013-12-171-0/+5
| | | | | compatible with psycopg2's per-connection/cursor approach. add round trip tests for both native and non-native.
* - rework JSON expressions to be based off __getitem__ exclusivelyMike Bayer2013-12-171-4/+2
| | | | | | | | | - add support for "standalone" JSON objects; this involves getting CAST to upgrade the given type of a bound parameter. should add a core-only test for this. - add tests for "standalone" json round trips both with and without unicode - add mechanism by which we remove psycopg2's "json" handler in order to get the effect of using our non-native result handlers
* Merge branch 'issue_2581' of github.com:nathan-rice/sqlalchemy into pg_jsonMike Bayer2013-12-171-0/+15
|\
| * sqlalchemy/dialects/postgresql/psycopg2:nathan2013-12-101-2/+0
| | | | | | | | - Removed unneeded import of psycopg2.extensions
| * sqlalchemy/dialects/postgresql/pgjson:nathan2013-12-101-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | - Fixed reference to HSTORE - Corrected spelling of SQLAlchemy sqlalchemy/dialects/postgresql/psycopg2: - Added psycopg2 specific wrapper type for JSON which uses inherent json deserialization facilities - Added code to detect and utilize the JSON wrapper if psycopg2 >= 2.5 test/dialect/postgresql/test_types: - removed reference to use_native_hstore
* | - add "force_nocheck" as a way to turn on unicode=force without evenMike Bayer2013-12-151-19/+9
|/ | | | | | | doing the isinstance() check - currently used only by psycopg2 + native enum + py2k. - didn't realize psycopg2 had UNICODEARRAY extension all this time; replace _PGArray with just using UNICODEARRAY instead. - replace unnecessary/inconsistent __import__ in _isolation_lookup.
* - evaulate decimal_return_scale statelessly. Don't re-assign to ↵Mike Bayer2013-11-231-1/+2
| | | | | | self.decimal_return_scale so that __repr__() is maintained (for alembic tests)
* - The precision used when coercing a returned floating point value toMike Bayer2013-11-221-1/+2
| | | | | | | | | | Python ``Decimal`` via string is now configurable. The flag ``decimal_return_scale`` is now supported by all :class:`.Numeric` and :class:`.Float` types, which will ensure this many digits are taken from the native floating point value when it is converted to string. If not present, the type will make use of the value of ``.scale``, if the type supports this setting and it is non-None. Otherwise the original default length of 10 is used. [ticket:2867]
* fix up the isolation level docs which were a messMike Bayer2013-06-171-16/+33
|
* - changelogMike Bayer2013-06-151-1/+5
| | | | - docs
* Add AUTOCOMMIT isolation level support for psycopg2pr/7Roman Podolyaka2013-06-151-0/+1
| | | | | | | | | | | | | | One can use this to emit statements, which can not be executed within a transaction (e. g. CREATE DATABASE): from sqlalchemy import create_engine eng = create_engine('postgresql://test:test@localhost/test') conn = eng.connect().execution_options(isolation_level='AUTOCOMMIT') conn.execute('CREATE DATABASE test2;') Fixes issue #2072.
* - repair for py3kMike Bayer2013-05-291-1/+6
| | | | - fix test
* Unicode support for psycopg2 native hstore implementationDmitry Mugtasimov2013-05-291-1/+2
|
* postgresql dialect testsMike Bayer2013-04-281-14/+13
|
* - the raw 2to3 runMike Bayer2013-04-271-15/+15
| | | | - went through examples/ and cleaned out excess list() calls
* - only search in the exception before the first newline, to avoidMike Bayer2013-04-231-2/+3
| | | | false positives for SQL statements containing certain text
* Opened up the checking for "disconnect" with psycopg2/libpqMike Bayer2013-04-221-18/+21
| | | | | | | | to check for all the various "disconnect" messages within the full exception hierarchy. Specifically the "closed the connection unexpectedly" message has now been seen in at least three different exception types. [ticket:2712]
* - remove all compat items that are pre-2.5 (hooray)Mike Bayer2013-03-091-1/+1
| | | | | | - other cleanup - don't need compat.decimal, that approach never panned out. hopefully outside libs aren't pulling it in, they shouldn't be
* happy new year (see #2645)Diana Clarke2013-01-011-1/+1
|
* just a pep8 pass of lib/sqlalchemy/dialects/postgresqlDiana Clarke2012-11-191-18/+24
|
* - hstore adjustmentsMike Bayer2012-11-171-20/+46
|
* Register HStore adapter and typecaster in psycopg2 dialectAudrius Kažukauskas2012-11-151-0/+26
|
* - rework the sphinx customizations into distinct modulesMike Bayer2012-10-191-17/+6
| | | | | | | - build a new Sphinx extension that allows dialect info to be entered as directives which is then rendered consistently throughout all dialect/dbapi sections - break out the "empty_strings" requirement for oracle test
* - move out maxdbMike Bayer2012-10-181-3/+7
| | | | | | - begin consolidating docs for dialects to be more self contained - add a separate section for "external" dialects - not sure how we're going to go with this yet.
* - [bug] Added 'terminating connection' to the listMike Bayer2012-09-251-1/+2
| | | | | | of messages we use to detect a disconnect with PG, which appears to be present in some versions when the server is restarted. [ticket:2570]
* - update all the visit_mod() functions with new naming schemeMike Bayer2012-08-141-2/+3
| | | | | | - visit_mods all seemed to not propagate **kw down to process(). this is [ticket:2548] which may be backported to 0.7 pending a test case to illustrate wrong behavior.
* - update engine docstrings due to moveMike Bayer2012-08-131-1/+1
| | | | - struggle with Operators class autodoc
* - break out engine/base.py into base, interfaces, result, util.Mike Bayer2012-08-071-3/+3
| | | | - remove deprecated 0.7 engine methods
* more import cleanupsMike Bayer2012-08-071-7/+7
|
* trailing whitespace bonanzaMike Bayer2012-07-281-27/+27
|
* - a big renaming of all the _Underscore classes to haveMike Bayer2012-07-171-1/+1
| | | | | | plain names. The old names are still defined for backwards compatibility. - _BindParamClause renamed to BindParameter
* Add some `Sphinx` paragraph level versions informations markups,Mike Bayer2012-06-081-2/+3
| | | | such as ``.. versionadded::``, ``.. versionchanged::`` and ``.. deprecated::``.