Skip to content
Snippets Groups Projects
  1. Dec 18, 2019
  2. Dec 13, 2019
  3. Dec 07, 2019
  4. Dec 20, 2019
  5. Dec 13, 2019
    • Pierre-Yves David's avatar
      rust-index: add a function to convert PyObject index for hg-core · f98f0e3d
      Pierre-Yves David authored
      Function in hg-core need something implementing the `Graph` trait. Right now,
      the `hg-cpython` entry points directly turn the PyObject passed as argument
      into a `cindex::Index`. However, if we start having the option to use an Index
      in Rust, we need to dispatch between the different possible PyObject we could
      receive.
      
      So move the "duplicate" call into a unified function. When time come. It will be
      easy to update the logic of all interface when the time come.
      
      Differential Revision: https://phab.mercurial-scm.org/D7653
      f98f0e3d
  6. Dec 11, 2019
  7. Dec 18, 2019
  8. Dec 19, 2019
  9. Dec 17, 2019
  10. Dec 18, 2019
    • Martin von Zweigbergk's avatar
      rebase: use rewriteutil.precheck() instead of reimplementing it · 71fee456
      Martin von Zweigbergk authored
      After this patch, there's still another place in `rebase.py`, in the
      `--stop` code path, that reimplements `rewriteutil.precheck()`. I
      couldn't fix that place because it `rewriteutil.precheck()` checks
      that there is only one dirstate parent, which fails because we have
      two parents at that point. I think it's incorrect that rebase leaves
      the user with two parents during conflicts, but changing that is way
      out of scope for this series.
      
      Differential Revision: https://phab.mercurial-scm.org/D7685
      71fee456
  11. Dec 17, 2019
  12. Dec 13, 2019
  13. Dec 18, 2019
  14. Dec 17, 2019
  15. Dec 16, 2019
    • Matt Harbison's avatar
      util: move common proxyobserver attributes to the base class · 4222b9d5
      Matt Harbison authored
      Fixes the following pytype warnings:
      
          line 791, in _writedata: No attribute 'logdata' on baseproxyobserver [attribute-error]
          line 792, in _writedata: No attribute 'logdataapis' on baseproxyobserver [attribute-error]
          line 793, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 794, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 799, in _writedata: No attribute 'logdataapis' on baseproxyobserver [attribute-error]
          line 800, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 802, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 803, in _writedata: No attribute 'name' on baseproxyobserver [attribute-error]
          line 805, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 809, in _writedata: No attribute 'logdataapis' on baseproxyobserver [attribute-error]
          line 810, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 814, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
          line 815, in _writedata: No attribute 'name' on baseproxyobserver [attribute-error]
          line 817, in _writedata: No attribute 'fh' on baseproxyobserver [attribute-error]
      
      Differential Revision: https://phab.mercurial-scm.org/D7675
      4222b9d5
  16. Dec 12, 2019
    • Martin von Zweigbergk's avatar
      config: drop debug messages saying where config was read from · 6b687282
      Martin von Zweigbergk authored
      `hg config --debug` includes lines like this:
      
        set config by: $EDITOR
      
      but also lines like this:
      
        $EDITOR: ui.editor=emacs -nw
      
      The `set config by` messages don't seem to provide much additional
      information over what we get from the `$EDITOR:`-type message. I could
      imagine wanting to see which values got overriden by a later entry,
      but that information is already not present. So let's just remove the
      first type of output. My next patch would otherwise amplify the
      redundant output (there would be one `set config by` for each line in
      `mergetools.rc`).
      
      Differential Revision: https://phab.mercurial-scm.org/D7627
      6b687282
  17. Dec 11, 2019
  18. Nov 29, 2019
  19. Dec 12, 2019
    • Matt Harbison's avatar
      exchange: ensure all outgoing subrepo references are present before pushing · 4b7d5d10
      Matt Harbison authored
      We've run into occasional problems with people committing a repo, and then
      amending or rebasing in the subrepo.  That makes it so that the revision in the
      parent can't be checked out, and the problem gets propagated on push.  Mercurial
      already tries to defend against this sort of dangling reference by pushing *all*
      subrepo revisions first.  This reuses the checks that trigger warnings in
      `hg verify` to bail on the push unless using `--force`.
      
      I thought about putting this on the server side, but at that point, all of the
      data has been transferred, only to bail out.  Additionally, SCM Manager hosts
      subrepos in a location that isn't nested in the parent, so normal subrepo code
      would complain that the subrepo is missing when run on the server.
      
      Because the push command pushes subrepos before calling this exchange code, a
      subrepo will be pushed before the parent is verified.  Not great, but no
      dangling references are exchanged, so it solves the problem.  This code isn't in
      the loop that pushes the subrepos because:
      
        1) the list of outgoing revisions is needed to limit the scope of the check
        2) the loop only accesses the current revision, and therefore can miss
           subrepos that were dropped in previous commits
        3) this code is called when pushing a subrepo, so the protection is recursive
      
      I'm not sure if there's a cheap check for the list of files in the outgoing
      bundle.  If there is, that would provide a fast path to bypass this check for
      people not using subrepos (or if no subrepo changes were made).  There's
      probably also room for verifying other references like tags.  But since that
      doesn't break checkouts, it's much less of a problem.
      
      Differential Revision: https://phab.mercurial-scm.org/D7616
      4b7d5d10
Loading