Skip to content
Snippets Groups Projects
  1. Apr 18, 2025
  2. Apr 16, 2025
  3. Apr 17, 2025
  4. Apr 16, 2025
  5. Apr 15, 2025
    • Pierre-Yves David's avatar
      pytype: stop running "make local" before run · 064b7812
      Pierre-Yves David authored
      `make local` would copy the compiled extension in place, but I don't think
      Mercurial does much use of them so keeping seems simple seems better.
      
      It would speed up the CI job a bit and help keeping the associated CI image
      slim.
      064b7812
  6. Apr 16, 2025
  7. Apr 15, 2025
  8. Mar 07, 2025
  9. Apr 16, 2025
    • Pierre-Yves David's avatar
      ci: always --retest error on Windows · dbbf4d4e
      Pierre-Yves David authored
      The Windows test are very flaky, let always re run failed test after the first
      run. This should help the overall flakiness making the windows test unreliable.
      
      This will make job with many legitimate failures slower to report their errors,
      but it helps the other cases so much that this is worse it.
      dbbf4d4e
  10. Apr 07, 2025
    • Mitchell Kember's avatar
      rust-annotate: change FileId let-else to match · aedbc690
      Mitchell Kember authored
      This changes all the let-else statements on FileId to instead use an exhaustive
      match to make it more clear that the "else" case is Wdir.
      aedbc690
    • Mitchell Kember's avatar
      rust-annotate: do ancestor checks for all revs · 04bc2087
      Mitchell Kember authored
      This makes rhg annotate do ancestor checks for all filelog revs. Previously it
      only did so for revs that would actually appear in the output. While this often
      improves performance, sometimes it hurts it (in a few rare cases making it
      slower overall than Python).
      
      The reason is that linkrev adjustment goes in reverse topological order such
      that each changelog scan picks up where its child (or other descendant) left
      off. By skipping revs that don't appear in the output, we do fewer scans, but
      the scans are longer. If we do "unnecessary" ancestor checks (which are
      comparatively cheap), we get better descendants to start those changelog scans
      from. That's what this change does.
      
      Here are some poulpe benchmarks on the jane repo. The "file-with-long-history"
      examples were chosen by the setup script. The "was-faster-in-python" files I
      manually selected. The "50-random-files" is from `hg files | shuf -n50`.
      
      ### data-env-vars.name               = jane
      ### benchmark.name                   = hg.command.annotate
      ### bin-env-vars.hg.flavor           = rhg
      ### benchmark.variants.files-as-text = no
      ### benchmark.variants.follow-copies = yes
      ### benchmark.variants.listed        = default
      
       ## benchmark.variants.files         = 50-random-files.list
      ce5d61140f14: 167.293994  ~~~~~
      49568c6ba019: 98.502573 (-41.12%, -68.79)
       ## benchmark.variants.files         = file-with-long-history.a
      ce5d61140f14: 49.005604  ~~~~~
      49568c6ba019: 24.821525 (-49.35%, -24.18)
       ## benchmark.variants.files         = file-with-long-history.b
      ce5d61140f14: 48.959987  ~~~~~
      49568c6ba019: 25.059625 (-48.82%, -23.90)
       ## benchmark.variants.files         = file-with-long-history.c
      ce5d61140f14: 22.892105  ~~~~~
      49568c6ba019: 21.788369   (-4.82%, -1.10)
       ## benchmark.variants.files         = was-faster-in-python.a
      ce5d61140f14: 35.160262  ~~~~~
      49568c6ba019: 0.749528 (-97.87%, -34.41)
       ## benchmark.variants.files         = was-faster-in-python.b
      ce5d61140f14: 34.236378  ~~~~~
      49568c6ba019: 0.559009 (-98.37%, -33.68)
       ## benchmark.variants.files         = was-faster-in-python.c
      ce5d61140f14: 22.803029  ~~~~~
      49568c6ba019: 1.257608 (-94.48%, -21.55)
       ## benchmark.variants.files         = was-faster-in-python.d
      ce5d61140f14: 18.779003  ~~~~~
      49568c6ba019: 0.960363 (-94.89%, -17.82)
       ## benchmark.variants.files         = was-faster-in-python.e
      ce5d61140f14: 18.147231  ~~~~~
      49568c6ba019: 0.698075 (-96.15%, -17.45)
      04bc2087
    • Mitchell Kember's avatar
      annotate: add test for linkrev descendant behavior · 8c434bb7
      Mitchell Kember authored
      This adds a test to test-annotate.t to demonstrate a difference in behavior
      between Python and Rust. Currently Rust skips linkrev adjustment for revisions
      that don't appear in the output. This has a few consequences:
      
      1. It's usually faster because it skips work.
      2. It's sometimes slower because it does longer changelog scans.
      3. It produces different results in an edge case.
      
      This changeset demonstrates (3). In a follow-up change I will fix (2) and (3)
      while preserving (1).
      8c434bb7
  11. Apr 16, 2025
  12. Mar 03, 2025
    • Mitchell Kember's avatar
      rust-annotate: support -Tjson · b242980e
      Mitchell Kember authored
      This adds support for the json template in rhg annotate. All other -T/--template
      values continue to fallback to Python.
      
      I matched the format of the Python output so all existing tests pass. This was
      not that hard to do printing JSON manually. The only thing I use serde_json for
      is to escape strings.
      b242980e
  13. Mar 06, 2025
  14. Mar 18, 2025
  15. Mar 04, 2025
  16. Mar 06, 2025
  17. Apr 14, 2025
    • Arseniy Alekseyev's avatar
      rhg: extract function expand_aliases · fddb8e12
      Arseniy Alekseyev authored
      In the interest of keeping the code of `main_with_result` clean,
      move all alias-related stuff into a separate function.
      
      Also, add a comment explaining why we think `trailing_args` behavior
      is good enough.
      fddb8e12
  18. Apr 01, 2025
    • Mitchell Kember's avatar
      rhg: support basic aliases · df58357b
      Mitchell Kember authored
      This adds rhg support for resolving aliases. It does not yet support shell
      aliases (starting with "!") or interpolation ("$1", "$@", etc.). It splits words
      in alias definitions using the shlex crate.
      df58357b
  19. Apr 02, 2025
  20. Apr 01, 2025
    • Mitchell Kember's avatar
      rust-config: preserve insertion order · bbab51e5
      Mitchell Kember authored
      This changes ConfigItem to be an indexmap::IndexMap instead of a HashMap, so
      that it preserves insertion order. It also changes Config::iter_section to
      return keys in that order (lowest to highest precedence). For all existing uses
      of iter_section, the order doesn't appear to matter.
      
      This is motivated by a follow-up change that will implement support for aliases
      in rhg, where the order of alias definitions matters.
      bbab51e5
  21. Apr 16, 2025
  22. Mar 19, 2025
  23. Mar 20, 2025
  24. Mar 27, 2024
  25. Jan 29, 2025
Loading