- 12 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 11 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
Python3 doesn't support "%s" with int arguments (and not with None arguments either, which this code was also using).
-
- 17 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
random.choice() (and others based on random.randint()) changed between py2 and py3 without a way to get the py2 behavior. However, random.random() did not change, so we can re-implement random.choice() based on that.
-
- 13 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 17 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 11 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 12 Jul, 2019 2 commits
-
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
Replaced by "'%s'", which I think is clearer anyway.
-
- 11 Jul, 2019 2 commits
-
-
Martin von Zweigbergk authored
These are all for messages to the user and we don't want unicode for that.
-
Martin von Zweigbergk authored
-
- 09 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
array.array.{to,from}string() still exists on py3, but they're deprecated and generate warnings. I've put the compat function in compat.pt for now. We can move into a dedicated pycompat.py if we end up with a lot of py3 compat stuff.
-
- 11 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 13 Jul, 2019 2 commits
-
-
Martin von Zweigbergk authored
Mercurial's source transformer also replaces the 'def iteritems(' in branchmap by 'def items(', so we need to call whichever version is there.
-
Martin von Zweigbergk authored
The only remaining iteritems() call is on branchmap. That will be dealt with in the next patch.
-
- 15 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
-
- 13 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
map(some_generator()) in py2 returns a list, while in py3 it returns a generator, so the passed-in generator won't be called unless the returned one is.
-
- 11 Jul, 2019 5 commits
-
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
The py2 and py3 docs ([1] and [2]) disagree how to get bytes output, but it seems obvious that this should be "bytes" to be compatible with both. [1] https://docs.python.org/2/library/sqlite3.html#sqlite3.Connection.text_factory [2] https://docs.python.org/3/library/sqlite3.html#sqlite3.Connection.text_factory
-
Martin von Zweigbergk authored
-
- 13 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
ui.edit() has had the "action" argument since 6e6452bc441d (editor: use an unambiguous path suffix for editor files, 2017-08-30), which was first released in hg version 4.4. Since we support only versions higher than 4.5, we can drop this check.
-
- 12 Jul, 2019 2 commits
-
-
Martin von Zweigbergk authored
`opts.get('rev') or '.'` is either a list of strings or just a string. It happened to work because `'.'[0] == '.'` on Python 2, but it won't work on Python 3 (for byte strings). The fallback value wasn't even needed (it was also set just after), so let's just remove it.
-
Martin von Zweigbergk authored
-
- 11 Jul, 2019 2 commits
-
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
D6623 has now been accepted in Mercurial (commit 83666f011679), so evolve commit 23323092f0a7 (py3: convert _origdoc to sysstr to match __doc__, 2019-07-09) is not longer needed.
-
- 17 Jul, 2019 2 commits
-
-
Pierre-Yves David authored
-
Sushil Khanchi authored
When touching a node, the way we check if it can lead to divergence is we look at the successors sets of the rev being touched. And if there is successor revs exists (excluding the case when that successor set is (A,) for rev A) that means there will be divergence and we warn the user. This works fine but there is still a case (which is not covered by looking at successor sets) which can lead to divergence. That case is: when there is already a revision exists which is divergent to the revision being touched. And performing the touch would revive that "dead" divergence. (Dead because one of the revision is obsolete which is the one we are touching) And to see if there is any rev which is divergent to a particular rev we already have a function which we can use here i.e. `evolvecmd.divergentsets(repo, ctx_being_touched)` Changes in test file demonstrate the fixed behaviour.
-
- 29 Jun, 2019 1 commit
-
-
Sushil Khanchi authored
-
- 17 Jul, 2019 1 commit
-
-
Sushil Khanchi authored
-
- 15 Jul, 2019 1 commit
-
-
Martin von Zweigbergk authored
This makes tests pass again after Mercurial commit c7d236b55a3e (py3: fix formatting of branchmap log messages with repo.filtername=None, 2019-07-14). CORE-TEST-OUTPUT-UPDATE: c7d236b55a3e
-
- 13 Jul, 2019 1 commit
-
-
Anton Shestakov authored
As with fold (see the previous patch), it's allowed to metaedit a merge commit or a set of commits including merge commits (with --fold) as long as there are less than 2 parents of the set not included in the said set.
-
- 11 Jul, 2019 2 commits
-
-
Anton Shestakov authored
It's possible to fold revision chains that include a single merge commit: just fold everything into the merge commit while saving its other parent (so it continues being a merge commit). It's also possible to fold revisions that include multiple merge commits, on the condition that they merge with not more than 2 external changesets (i.e. a changesets that aren't going to be folded).
-
Anton Shestakov authored
Otherwise rewinding a merge commit makes it lose all changes. This fix populates `updates` argument of rewriteutil.rewrite() with parent changesets. That argument is normally used for folding multiple changesets, but in this case it's simply used to include files from p1 and p2. Usually, rewrite() works fine using ctx.files(), but that function can return an empty list when ctx is a merge commit.
-
- 10 Jul, 2019 1 commit
-
-
Anton Shestakov authored
Otherwise touching a merge commit makes it lose all changes. This fix populates `updates` argument of rewriteutil.rewrite() with parent changesets. That argument is normally used for folding multiple changesets, but in this case it's simply used to include files from p1 and p2. Usually, rewrite() works fine using ctx.files(), but that function can return an empty list when ctx is a merge commit.
-
- 09 Jul, 2019 5 commits
-
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
This makes `import hgext3rd.topic` work.
-
Martin von Zweigbergk authored
It's currently stored as bytes by core, so we need to convert it to match Python's expected type for __doc__. This patch can be dropped if D6623 gets accepted.
-
Martin von Zweigbergk authored
-
Martin von Zweigbergk authored
-