Skip to content
Snippets Groups Projects
  1. Feb 28, 2023
    • Matt Harbison's avatar
      configitems: enable changegroup3 by default (unless using infinitepush) · 2cf264e9aa75
      Matt Harbison authored
      The LFS extension requires this, and if it isn't enabled on the client (or the
      LFS extension isn't loaded), a web client gets a 500 instead of a sensible error
      message.  Now it gets a different (client) error, but maybe it can be handled
      more gracefully.  c0f11347b107 indicates that treemanifest repos have this issue
      too.  29cfc474c5fd mentions gating this behind `experimental` so that the format
      could change, but that was 7 years ago and we now have an experimental
      `changegroup4` as well.
      
      We can keep this as a config for the next cycle in case someone runs into an
      unexpected problem, and then jettison it if the infinitepush bundle name changes
      are either acceptable as-is or can be created differently.
      2cf264e9aa75
    • Matt Harbison's avatar
      infinitepush: opt out of changegroup3 unless explicitly configured · 806ca6bd0719
      Matt Harbison authored
      This is currently a no-op, as changegroup3 is disabled by default.  But when it
      is enabled, it changes the hash names of the bundle files.  As I don't use this
      extension, I have no idea if that's OK or not.  So keep the current default
      behavior until we can get more info from actual users, while allowing them to
      opt-in for testing purposes.
      806ca6bd0719
  2. Mar 01, 2023
  3. Mar 02, 2023
  4. Feb 28, 2023
    • Matt Harbison's avatar
      typing: add typehints to mercurial/diffutil.py · b8cac4e37100
      Matt Harbison authored
      Lack of typehints here caused the fact that TortoiseHg was passing str instead
      of bytes as the key in `opts` to be missed, resulting in shelf corruption in
      cases where `diff.git` is required.
      b8cac4e37100
    • Matt Harbison's avatar
      patchbomb: respect the `--git` option · a6b497872b97
      Matt Harbison authored
      I *think* this is the only diffopt exposed on the command line.  TortoiseHg had
      a similar issue creating diffopts, and this was caught by type hints in the next
      commit.
      a6b497872b97
  5. Mar 01, 2023
    • Raphaël Gomès's avatar
      rhg: remember the inode of .hg/dirstate · dbe09fb038fc
      Raphaël Gomès authored
      This allows us to detect changes of `.hg/dirstate`, which is either the
      full dirstate (in dirstate-v1) or the docket file (v2) without relying on
      data inside the file. It only works on UNIX systems.
      
      This fixes a race condition for dirstate-v1 (as demonstrated by
      the test changes) and adds a confortable layer of sanity for dirstate-v2.
      dbe09fb038fc
  6. Feb 28, 2023
    • Raphaël Gomès's avatar
      rust-dirstate-v2: don't write dirstate if data file has changed · 07d030b38097
      Raphaël Gomès authored
      This fixes the following race:
          - process A reads the dirstate
          - process B reads and writes the dirstate
          - process A writes the dirstate
      
      This either resulted in losing what process B had just written or a crash
      because the `uuid` had changed and we were trying to write to a file that
      doesn't exist. More explanations inside.
      
      This doesn't fix the issue for dirstate-v1, a later patch addresses it.
      07d030b38097
  7. Dec 12, 2022
  8. Mar 01, 2023
    • Pierre-Yves David's avatar
      dirstate: set identity whenever we read the dirstate's v2 docket · 379a78001d8e
      Pierre-Yves David authored
      The docket can be loaded outside of a full read (for exemple when
      pre-fetching parents), so the current code would read/set the identity
      after loading the data, opening a race condition:
      
      A0: first process docket is read
      B0: other process appends new data to the dirstate (and changes the docket)
      A1: first process sets the identity (based on pre-B content, but with post-B identity)
      A1: first process loads the dirstatemap from the data file
      A1: first process does not detect the race and overwrites the update from B.
      379a78001d8e
  9. Feb 21, 2023
  10. Feb 28, 2023
Loading