赖信涛
bc7a5d0100
Drop Python3.5. ( #1154 )
...
* Drop Python3.5.
* delete 3.5 from setup.py
* fix black format. Using python3.7 for development now.
* black target to py36
2020-03-11 13:58:13 -07:00
lazydba247
91263c37b9
Add Support for partitioned tables. ( #1145 )
...
* partitioned tables: add support
Starting from 9.6+ relkind has new members (more info here: https://www.postgresql.org/docs/12/catalog-pg-class.html )
* Update AUTHORS
* Update changelog.rst
* foreign tables: add support
Starting from 9.6+ relkind has new members (more info here: https://www.postgresql.org/docs/12/catalog-pg-class.html )
2020-02-13 14:24:37 -08:00
Amjith Ramanujam
43e79d0027
Use libpq version instead of psycopg2 version.
2019-10-26 19:45:02 -07:00
Irina Truong
270e1ce7a2
Log message.
2019-10-26 13:21:23 -07:00
Irina Truong
4f0c4d5a38
Fix for PQconninfo not available.
2019-10-19 11:36:38 -07:00
Irina Truong
04a74fce2c
Get server params, such as is_superuser and server_version, without extra queries.
2019-08-28 08:26:24 -07:00
Sebastian Janko
f85642da67
Issue 1019 stacktrace on empty query ( #1078 )
...
* Added changes to skip empty queries
Empty queries consist of one or more semicolons
* Reformatted with black
* Added contribution to changelog and name to AUTHORS
* Black.
2019-07-12 17:24:39 -07:00
Irina Truong
10cc4ce2b9
Partial fix for #1058 . ( #1068 )
2019-06-09 17:05:28 +02:00
Amjith Ramanujam
9abb4f8560
Run black.
2019-06-02 18:02:02 -07:00
Amjith Ramanujam
3a45620731
Add \G as a temporary way to use expanded mode.
...
This is similar to mycli.
2019-06-02 17:57:36 -07:00
Irina Truong
8cb7009bcd
black all the things. ( #1049 )
...
* added black to develop guide
* no need for pep8radius.
* changelog.
* Add pre-commit checkbox.
* Add pre-commit to dev reqs.
* Add pyproject.toml for black.
* Pre-commit config.
* Add black to travis and dev reqs.
* Install and run black in travis.
* Remove black from dev reqs.
* Lower black target version.
* Re-format with black.
2019-05-25 13:08:56 -07:00
Irina Truong
d661f63eec
pep8.
2019-05-21 20:28:05 -07:00
Amjith Ramanujam
a45c67acf0
Handle password with spaces.
2019-05-13 15:13:15 -07:00
Irina Truong
300febccdd
Dsn parameters not always present. ( #1054 )
...
* Dsn parameters not always present.
2019-05-11 07:57:45 +02:00
Amjith Ramanujam
a6d44df4a7
Merge branch 'master' into pr1035
2019-05-06 07:18:46 -07:00
Amjith Ramanujam
e5501cb83c
Check if dsn and password values are passed in.
2019-05-06 06:34:24 -07:00
Irina Truong
3fd91012f2
More intelligent dsn format ( #1045 )
...
* Psycopg2 already has a method to format a dsn. We should use it. Fix for #1043 .
* Changelog.
* pep8.
2019-04-28 15:06:01 -07:00
raylu
eef0e0d65c
Allow application_name to be overridden ( #1044 )
...
* Allow application_name to be overridden
* Fixed broken link.
* Default password value is empty str?
* Make pep8 happier.
2019-04-27 21:25:19 -06:00
Xavier Francisco
e0eac14c96
Revert main changes; Filter unwanted params when dsn present
2019-04-09 21:46:20 +01:00
Xavier Francisco
49582ccb7c
Fix usage of pgservice
2019-04-08 19:46:29 +01:00
Irina Truong
d25d27846a
Fix for https://github.com/dbcli/pgcli/issues/1014 .
2019-03-18 03:09:26 +00:00
Amjith Ramanujam
3652134bc5
Merge branch 'master' into system-error
2019-03-16 21:18:21 -07:00
Amjith Ramanujam
9df9c222d0
Remove the unnecessary try/except.
2019-03-16 13:36:32 -07:00
Amjith Ramanujam
f4ebcd2383
Access only the required element from the tuple.
2019-03-16 13:34:36 -07:00
Amjith Ramanujam
951cfb28a7
Catch and ignore the system interrupt.
2019-03-15 20:28:40 -07:00
Irina Truong
33dbb602de
Fix crash when using --single-connection.
2019-03-04 16:09:12 -08:00
Marcin Cieślak
ef8aac61c4
Determine hstore OID from the system view ( #992 )
...
Avoid error message on the server side if hstore
extension is not installed in the current database.
Issue: https://github.com/dbcli/pgcli/issues/991
2019-01-21 16:00:25 -08:00
Mikhail Elovskikh
f614cef7ed
Support multihost connection string ( #978 )
...
* Switch to psycopg2 parse_dsn instead of urlparse
* Added wronglink to contributors and updated changelog
* Fix test codestyle
* Support for PGPORT customization in tests
* Support for PGPORT customization in tests
* Refactored PGExecute init and moved short_host generation to object property
* Fix test util codestyle
* Fix local tests run
* Store PGExecute initial params in _conn_params and added PGExecute.copy method
* Fix codestyle
* Added docstring to PGExecute.copy() method
2019-01-03 14:27:47 -08:00
Irina Truong
0cae7e2036
Remove some functions completions ( #982 )
...
Remove extension and private functions from completer.
2019-01-02 16:15:59 -08:00
Lele Gaifax
05ec05c4cb
Adapt the query used to get functions metadata to PG11
...
This fixes #919 .
2018-07-25 08:13:17 +02:00
Irina Truong
22d184dc6b
Change server version query.
2018-07-24 15:14:53 -07:00
Irina Truong
7653ea9c1f
Print server version as part of welcome message.
2018-07-20 15:47:40 -07:00
Saif Hakim
80957c59c5
Fix lint, update AUTHORS, and changelog
2018-07-04 01:36:50 -07:00
Saif Hakim
5cdb151999
Avoid reconnect prompt after error if connection is still valid
...
Instead of whitelisting all errors that do not require reconnecting, we simply
only reconnect if we detect a disconnect has occurred.
psql notably behaves in a similar way: https://git.io/fbxuc#L1461
Fixes #807
2018-07-03 23:56:26 -07:00
Irina Truong
a26b8b92a2
Pep8.
2018-06-17 14:34:20 -07:00
Irina Truong
4b06769002
Can't add tuple and list.
2018-06-17 14:21:30 -07:00
Irina Truong
aa58fbf028
Non-existent function will raise a ProgrammingError.
2018-06-16 21:49:28 -07:00
Irina Truong
8ee20aa82e
Fix for 'only named arguments may follow *expression'
2018-06-16 21:49:28 -07:00
catherinedevlin
74daa23a45
switched view query to imitating psql
2018-06-16 21:47:18 -07:00
catherinedevlin
bb8cbac3de
Added \ef
2018-06-16 21:46:31 -07:00
catherinedevlin
675e1dbff2
Moved code to pgexecute
2018-06-16 21:46:31 -07:00
Matthieu Guilbert
1a2421892b
fix: not enough values to unpack
2018-06-07 00:43:48 +08:00
Amjith Ramanujam
9ae9df624f
Merge branch 'master' into feature/get-last-sql-query
2018-05-18 21:48:21 -07:00
Amjith Ramanujam
5990e55413
Restrict the offer to reconnect.
2018-05-15 10:06:50 -04:00
Rishi Ramraj
a49f5bdd0f
Add is_special to run return
2018-05-15 00:35:07 -04:00
Irina Truong
7a4d9a0792
Fix for #805 (partial).
2017-10-21 11:10:45 -07:00
François Pietka
902fe94f3c
Fix psycopg2 error code lookup
2017-08-12 13:03:29 +02:00
François Pietka
9c0304df1f
Get socket directory if no host provided by psycopg2
2017-08-12 13:03:28 +02:00
François Pietka
60f3a50b5c
Add query to get socket directory
2017-08-12 13:03:28 +02:00
François Pietka
f63081495c
Use psycopg2 to get database details
2017-07-29 16:05:35 +02:00