Merging upstream version 1.24.4.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
d4cbf43afd
commit
c3d94d7b9c
7 changed files with 22 additions and 7 deletions
|
@ -87,6 +87,7 @@ Contributors:
|
|||
* Zhaolong Zhu
|
||||
* Zhidong
|
||||
* Zhongyang Guan
|
||||
* Arvind Mishra
|
||||
|
||||
Created by:
|
||||
-----------
|
||||
|
|
|
@ -1 +1 @@
|
|||
__version__ = '1.24.3'
|
||||
__version__ = '1.24.4'
|
||||
|
|
|
@ -30,7 +30,7 @@ def mycli_line_magic(line):
|
|||
u = conn.session.engine.url
|
||||
_logger.debug('New mycli: %r', str(u))
|
||||
|
||||
mycli.connect(u.database, u.host, u.username, u.port, u.password)
|
||||
mycli.connect(host=u.host, port=u.port, passwd=u.password, database=u.database, user=u.username, init_command=None)
|
||||
conn._mycli = mycli
|
||||
|
||||
# For convenience, print the connection alias
|
||||
|
|
|
@ -2,6 +2,7 @@ from collections import defaultdict
|
|||
from io import open
|
||||
import os
|
||||
import sys
|
||||
import shutil
|
||||
import traceback
|
||||
import logging
|
||||
import threading
|
||||
|
@ -1054,7 +1055,7 @@ class MyCli(object):
|
|||
"""Get the number of lines to reserve for the completion menu."""
|
||||
reserved_space_ratio = .45
|
||||
max_reserved_space = 8
|
||||
_, height = click.get_terminal_size()
|
||||
_, height = shutil.get_terminal_size()
|
||||
return min(int(round(height * reserved_space_ratio)), max_reserved_space)
|
||||
|
||||
def get_last_query(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue