You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
g:neoformat_run_all_formatters doesn't seem to properly pass the output from one formatter to the next -- it seems llike neoformat sometimes cuts off the last line if a previous formatter changed the number of lines in the output (when formatting the whole file).
My reproduction example below uses isort, yapf, and Python, but I suspect this issue affects more than just my situation.
If you look at the list of lines being formatted (as an array of strings), the last entry disappears between the output from isort and the input to yapf.
Running neoformat a second time
If I run :Neoformat a second time, it successfully runs yapf, and provides me with my expected output.
g:neoformat_run_all_formatters
doesn't seem to properly pass the output from one formatter to the next -- it seems llike neoformat sometimes cuts off the last line if a previous formatter changed the number of lines in the output (when formatting the whole file).My reproduction example below uses
isort
,yapf
, and Python, but I suspect this issue affects more than just my situation.Configuration
Vim version:
neoformat version: the tip of HEAD as of a few minutes ago: 6b66c20
Relevant .vimrc configuration:
Relevant isort configuration (eg, in
setup.cfg
):(yapf config doesn't matter for this example)
Input file (Python)
Expected output file
First run output
I run:
:Neoformat
However, after the first run, the output file is (yapf failed to run):
The verbose output for this run is:
If you look at the list of lines being formatted (as an array of strings), the last entry disappears between the output from isort and the input to yapf.
Running neoformat a second time
If I run
:Neoformat
a second time, it successfully runsyapf
, and provides me with my expected output.(see above for expected file output)
The verbose neoformat output for the second run:
The text was updated successfully, but these errors were encountered: