`\ef` in a transaction causes pgcli to crash
- 主要言語
- Python
- スター
- 13.4k
- フォーク
- 612
- 平均マージ
- 6日 14時間
- マージ済み PR(30日)
- 10
説明
## Description
If a transaction is manually started (`begin transaction;`) then an attempt to edit a postgres function or stored procedure is made via `\ef function_name`, pgcli will crash.
Expected behavior: Although it is a postgres error to try to edit a function within a transaction, pgcli should not crash.
## Your environment
* FreeBSD 13.1
* pgcli 3.5.0
* postgres 14.6
`pip freeze` output:
acme==2.1.0
awscli==1.27.16
botocore==1.29.13
certbot==2.1.0
certbot-nginx==2.1.0
certifi==2022.9.24
cffi==1.15.1
charset-normalizer==3.0.1
cli-helpers==2.3.0
click==8.0.3
colorama==0.4.5
ConfigArgParse==1.5.3
configobj==5.0.6
cryptography==3.4.8
distro==1.8.0
dnspython==2.2.1
docutils==0.17.1
idna==3.4
importlib-metadata==4.8.1
jmespath==1.0.1
josepy==1.13.0
Markdown==3.3.7
parsedatetime==2.6
pendulum==2.1.2
pgcli==3.5.0
pgspecial==2.0.1
prompt-toolkit==3.0.36
psycopg==3.1.7
psycopg-pool==3.1.4
pyasn1==0.4.8
pycparser==2.21
Pygments==2.14.0
pyOpenSSL==20.0.1
pyparsing==3.0.9
pyRFC3339==1.1
PySocks==1.7.1
python-dateutil==2.8.2
pytz==2022.7
pytzdata==2020.1
PyYAML==5.4.1
requests==2.28.1
rsa==4.9
s3transfer==0.6.0
setproctitle==1.3.2
six==1.16.0
sqlparse==0.4.3
tabulate==0.8.9
typing-extensions==4.4.0
urllib3==1.26.13
wcwidth==0.1.8
zipp==3.4.0
- [X] Please provide your OS and version information.
- [X] Please provide your CLI version.
- [X] What is the output of ``pip freeze`` command.
コントリビューションガイド
調査の方向性
トランザクションを開始し、PostgreSQL に対して `\ef function_name` を実行して、pgcli で問題を再現します。`\ef` コマンドのエラーハンドリングを追跡し、その後、トランザクション内でコマンドを使用したときに pgcli がクラッシュせず、PostgreSQL のエラーが表示されることを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- postgresql, python
- 領域
- cli, databases
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100