To reproduce: Connect to a postgres database, save the following to a file and include it via \i <file>:
--
--
The shell will report list index out of range.
Commands before the trailing comments will not be executed, i.e., the following will produce the same output and no user will be created:
create role foobar123;
--
--
If the comments are not the last thing in the file, all is fine and commands are executed as expected, as in the following example:
select 1;
--
--
select 2;
Your environment
[x] Please provide your OS and version information:
Linux charon 5.7.4-arch1-1 #1 SMP PREEMPT Thu, 18 Jun 2020 16:01:07 +0000 x86_64 GNU/Linux
[x] Please provide your CLI version:
> pgcli --version
Version: 3.0.0
(Note that pgcli was installed as a system package, not using pip. I hope that the bug is easy to reproduce. If that is not the case, I can try and see what happens when using the current master.)
Description
To reproduce: Connect to a postgres database, save the following to a file and include it via
\i <file>
:The shell will report
list index out of range
.Commands before the trailing comments will not be executed, i.e., the following will produce the same output and no user will be created:
If the comments are not the last thing in the file, all is fine and commands are executed as expected, as in the following example:
Your environment
(Note that pgcli was installed as a system package, not using pip. I hope that the bug is easy to reproduce. If that is not the case, I can try and see what happens when using the current master.)
pip freeze
command: