i have a mix of imports that i want sorted by length, and running isort on it while force_sort_within_sections and reverse_sort are both true causes them to be sorted shortest line to longest, rather than longest to shortest, as expected.
pyproject.toml
[tool.isort]
length_sort = true
reverse_sort = true
force_sort_within_sections = true
IN
import blaaa
from bl4aaaaaaaaaaaaaaaa import r
import blaaaaaaaaaaaa
import bla
import blaaaaaaa
from bl1aaaaaaaaaaaaaa import this_is_1
from bl2aaaaaaa import THIIIIIIIIIIIISS_is_2
from bl3aaaaaa import less
OUT
import bla
import blaaa
import blaaaaaaa
import blaaaaaaaaaaaa
from bl3aaaaaa import less
from bl4aaaaaaaaaaaaaaaa import r
from bl1aaaaaaaaaaaaaa import this_is_1
from bl2aaaaaaa import THIIIIIIIIIIIISS_is_2
EXPECTED
from bl2aaaaaaa import THIIIIIIIIIIIISS_is_2
from bl1aaaaaaaaaaaaaa import this_is_1
from bl4aaaaaaaaaaaaaaaa import r
from bl3aaaaaa import less
import blaaaaaaaaaaaa
import blaaaaaaa
import blaaa
import bla
i have a mix of imports that i want sorted by length, and running isort on it while force_sort_within_sections and reverse_sort are both true causes them to be sorted shortest line to longest, rather than longest to shortest, as expected.