> Why 2 loops? Because I just incrementally improved my variants and mechanically moved the code from `package--get-activatable-pkg` to `package-process-define-package` in hope of next improvements. > And why is that sorting a problem? Maybe putting it to docs as a "known bug" would be better. It is just unintuitive behaviour. I understand that tested code is the priority. On the other hand, if the fb87d500 feature is little enough, why not revert and pretest without it? Or fix it and pretest fixed version. > Евгений, does this change fix your use case? Yes, reverted fb87d500 fixes the case too. On Mon, Jun 5, 2023 at 12:55 AM Eli Zaretskii wrote: > > From: Евгений Бойков > > Date: Mon, 5 Jun 2023 00:47:43 +1000 > > Cc: philipk@posteo.net, monnier@iro.umontreal.ca, 63757@debbugs.gnu.org > > > > > I guess we need to reverse the list of directories, since > > > directory-files sorts using string-lessp as the predicate? > > Unfortunately, `directory-files` order in `package-load-all-descriptors` > is later overlapped by > > `package--get-activatable-pkg` order which sorts `package-alist` > in-place. > > And why is that sorting a problem? > -- __________________________ С уважением, Бойков Евгений Алексеевич сот. 8-924-202-25-65 e-mail: artscan@list.ru