- May 31, 2022
-
-
Pierre-Yves David authored
-
Pierre-Yves David authored
-
Pierre-Yves David authored
-
Pierre-Yves David authored
-
Pierre-Yves David authored
This will be useful in case of corrupted index.
-
Pierre-Yves David authored
This will be useful in case of corrupted index.
-
Pierre-Yves David authored
We are about to add a bunch of new column and most of them are probably only relevant to --verbose. We add some more testing of the `--verbose` mode in a sidedata context.
-
Pierre-Yves David authored
Each column is now declared as a decorated function. This will make it much simpler to add more new column in the future.
-
Pierre-Yves David authored
We will add new columns with the "revnum" version of the parent. It will be useful in case we need to inspect a corrupted revlog index.
-
Pierre-Yves David authored
It will be simpler to align everything on the same side, and the right seems a better side as it match the value alignment.
-
- May 30, 2022
-
-
Pierre-Yves David authored
Adding more information will significantly increase the amount of code. So we move the code into its own module before making it more complex.
-
Pierre-Yves David authored
The command dump some content of the revlog index and omit a lot of information. I am going to make it display the missing information. For clarity, we rename the command to explicitly mention revlog.
-
Manuel Jacob authored
Changeset f574cc00831a introduced the wrapper, to make bin() behave like on Python 2, where it raised TypeError in many cases. Another previous approach, changing callers to catch binascii.Error in addition to TypeError, was backed out after negative review feedback [1]. However, I think it’s worth reconsidering the approach. Now that we’re on Python 3 only, callers have to catch only binascii.Error instead of both. Catching binascii.Error instead of TypeError has the advantage that it’s less likely to cover a programming error (e.g. passing an int to bin() raises TypeError). Also, raising TypeError never made sense semantically when bin() got an argument of valid type. As a side-effect, this fixed an exception in test-http-bad-server.t. The TODO was outdated: it was not an uncaught ValueError in batch.results() but uncaught TypeError from the now removed wrapper. Now that bin() raises binascii.Error instead of TypeError, it gets converted to a proper error in wirepeer.heads.<locals>.decode() that catches ValueError (superclass of binascii.Error). This is a good example of why this changeset is a good idea. Catching TypeError instead of ValueError there would not make much sense. [1] https://phab.mercurial-scm.org/D2244
-
- May 29, 2022
-
-
Manuel Jacob authored
Making try blocks as small as possible is generally a good idea, especially when catching very general errors like TypeError.
-
Manuel Jacob authored
-
- Jun 02, 2022
-
-
Raphaël Gomès authored
-
Raphaël Gomès authored
-
Raphaël Gomès authored
-
- May 04, 2022
-
-
idlsoft authored
Reviewer note: this was sent by the author as a simple bugfix, but can be considered a security patch, since it allows users to access things outside of the ACL, hence the (SEC) prefix. However, this affects the `narrow` extention which is still marked as experimental and has relatively few users aside from large companies with their own security layers on top from what we can gather. We feel (Alphare: or at least, I feel) like pinging the packaging list is enough in this case.
-
- May 30, 2022
-
-
Raphaël Gomès authored
This should fix this error we see in the CI from time to time: ``` --- /tmp/mercurial-ci/tests/test-chg.t +++ /tmp/mercurial-ci/tests/test-chg.t.err @@ -187,6 +187,26 @@ $ chg bulkwrite --pager=on --color no --config ui.formatted=True paged! 'going to write massive data\n' killed! (?) + Traceback (most recent call last): + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/commandserver.py", line 509, in _serverequest + sv.cleanup() + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/chgserver.py", line 382, in cleanup + self._restoreio() + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/chgserver.py", line 461, in _restoreio + os.close(fd) + OSError: [Errno 9] Bad file descriptor + Traceback (most recent call last): + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/commandserver.py", line 693, in _acceptnewconnection + self._runworker(conn) + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/commandserver.py", line 744, in _runworker + prereposetups=[self._reposetup], + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/commandserver.py", line 509, in _serverequest + sv.cleanup() + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/chgserver.py", line 382, in cleanup + self._restoreio() + File "/tmp/hgtests._uvojvqb/install/lib/python/mercurial/chgserver.py", line 461, in _restoreio + os.close(fd) + OSError: [Errno 9] Bad file descriptor [255] ```
-
- May 27, 2022
-
-
Pierre-Yves David authored
We add a revision with null parent but that is not the first revision of the revlog. It make it a different a case that is worthy of testing.
-
Pierre-Yves David authored
Using a revision with non-null parents makes it a different case that is worthy of testing.
-
Pierre-Yves David authored
We need to be careful to not create invalid delta for changelog. Changelog is special because it does not use any delta in practice and don't use general delta in its format. Using the new patch will help use to test more cases.
-
Anton Shestakov authored
Since pylint does its own directory traversal to find files to check and doesn't use hg locate command, this requirement is not valid. See also a29f071751df.
-
Anton Shestakov authored
This requirement exists to make sure for hg has locate command, which is used in this test file for getting a list of files to check. Since in theory current versions of tests could be run on older hg, it doesn't hurt to mark even this version requirement (as old as it is). See also: a29f071751df.
-
- May 29, 2022
-
-
Manuel Jacob authored
-
- May 21, 2022
-
-
Manuel Jacob authored
The core logic for readinto() was already implemented in read(), so this is mostly extracting that code into its own method. Another fix for issue6444 was committed to the stable branch: 2fe4efaa59af. That is a minimal fix that implements readinto() only on Python versions that require readinto() (3.8.0 and 3.8.1), which is the right approach for the stable branch. However, I think that this changeset has its value. It improves performance in cases when pickle can use readinto(), it reduces code duplication compared to the other patch, and by defining readinto() on all Python versions, it makes behavior more consistent across all Python versions. This changesets reverts the other change.
-
Manuel Jacob authored
On CPython, before resizing the bytearray, all memoryviews referencing it must be released. Before this change, we ensured that all references to them were deleted. On CPython, this was enough to set the reference count to zero, which results in garbage collecting and releasing them. On PyPy, releasing the memoryviews is not necessary because they are implemented differently. If it would be necessary however, ensuring that all references are deleted would not be suffient because PyPy doesn’t use reference counting. By using with statements that take care of releasing the memoryviews, we ensure that the bytearray is resizable without relying on implementation details. So while this doesn’t fix any observable bug, it increases compatiblity with other and future Python implementations.
-
Manuel Jacob authored
-
Manuel Jacob authored
-
- May 17, 2022
-
-
Pierre-Yves David authored
We tried a `hg bundle --base ':(tip^)' --rev 'all()'` on a large repository and it spent 3 minutes on this 2 list comprehensions. This change remove this cost. There are still a lot of low hanging fruits as the command still take 30 seconds. However this is a trivial patch with a massive speedup so I'll just sent it.
-
- May 20, 2022
-
-
Pierre-Yves David authored
See command documentation for details. For some reason, pytype is confused by our usage of None/deltainfo variable, so I had to quiet it.
-
- May 19, 2022
-
-
Pierre-Yves David authored
This provide a way to enable the code introduced in the previous changeset. This will provide a large amount of output when applying a bundle with details about each delta "computation".
-
Pierre-Yves David authored
I have been looking into performance issue around pull and getting more information about the computation and time involved into applying each revision is very useful. There will be various way to use this new output, so I am introducing the code first.
-
- Apr 21, 2022
-
-
Pierre-Yves David authored
This got changed at some point.
-
- May 25, 2022
-
-
Manuel Jacob authored
13dfad0f9f7a merged stable into default, but accidentally added the _blockingreader class from stable (but deindented) instead of merging the changes from stable (2fe4efaa59af) into the existing _blockingreader class. This resulted in the _blockingreader being there two times.
-
- May 18, 2022
-
-
Pierre-Yves David authored
See inline comment for details, this is a case where the delta is neither against p1 or p2, Yet it is still a simple delta part of a simple chain. We now display them as `skip1/skip2` instead of `other`.
-
Pierre-Yves David authored
So that one can understand what is displayed by the command.
-
Pierre-Yves David authored
Looking at the parents is a common need when trying to understanding why a delta was chosen, having it readily available helps a lot.
-
Pierre-Yves David authored
We mostly care about generaldelta happening, the exact details of storage size variation is not really important so we can glob it instead of having multiple lines for each variances. This will make updating the output of the command simpler.
-