Summary:
In a future diff we'll increase the size of the rotatelog temporarily
during clones. To do so we need it to be configurable.
Reviewed By: quark-zju
Differential Revision: D23089541
fbshipit-source-id: 5010e417a83a2611283322f1dbb7023f4286f503
Summary:
Remove HgIdDataStore::get_delta and all implementations. Remove HgIdDataStore::get_delta_chain from trait, remove all unnecessary implentations, remove all implementations from public Rust API. Leave Python API and introduce "delta-wrapping".
MutableDataPack::get_delta_chain must remain in some form, as it necessary to implement get using a sequence of Deltas. It has been moved to a private inherent impl.
DataPack::get_delta_chain must remain in some form for the same reasons, and in fact both implenetations can probably be merged, but it is also used in repack.rs for the free function repack_datapack. There are a few ways to address this without making DataPack::get_delta_chain part of the public API. I've currently chosen to make the method pub(crate), ie visible only within the revisionstore crate. Alternatively, we could move the repack_datapack function to a method on DataPack, or use a trait in a private module, or some other technique to restrict visibility to only where necessary.
UnionDataStore::get has been modified to call get on it's sub-stores and return the first which matches the given key.
MultiplexDeltaStore has been modified to implement get similarly to UnionDataStore.
Reviewed By: xavierd
Differential Revision: D21356420
fbshipit-source-id: d04e18a0781374a138395d1c21c3687897223d15
Summary:
One of the main drawback of the current version of repack is that it writes
back the data to a packfile, making it hard to change file format. Currently, 2
file format changes are ongoing: moving away from packfiles entirely, and
moving from having LFS pointers stored in the packfiles, to a separate storage.
While an ad-hoc solution could be designed for this purpose, repack can
fullfill this goal easily by simply writing to the ContentStore, the
configuration of the ContentStore will then decide where this data will
be written into.
The main drawback of this code is the unfortunate added duplication of code.
I'm sure there is a way to avoid it by having new traits, I decided against it
for now from a code readability point of view.
Reviewed By: DurhamG
Differential Revision: D20567118
fbshipit-source-id: d67282dae31db93739e50f8cc64f9ecce92d2d30
Summary:
assertEquals is deprecated and shows warnings in the tests in python 3
ignore-conflict-markers
Reviewed By: quark-zju, sfilipco
Differential Revision: D19907385
fbshipit-source-id: 7d261489856a4eeb6719eae581ed986d0415d99e
Summary: More replacements of dict.iteritems with pycompat.iteritems(dict) for py3 compatibility.
Reviewed By: singhsrb
Differential Revision: D19704211
fbshipit-source-id: 544cb292c0241a293fc4ab83c3d9472dcf4328b6
Summary:
Use sed to convert testutil.ddot requires to hghave.
ignore-conflict-markers
for test-simplemerge.py
Reviewed By: simpkins
Differential Revision: D19658355
fbshipit-source-id: afae73eb1e43ead79514dfaf9f911f51ac25972e
Summary:
This diff marks **ALL** mercurial tests requiring Python 2 feature.
After you fixes some tests, simply remove the `py2` feature requirement and that tests will be continuously run after your diff is landed.
To bypass this feature requirement, run the tests command with `HGTEST_FORCE_PY2=1`. For example:
```
HGTEST_FORCE_PY2=1 buck test //eden/scm/tests:hg_run_tests
```
or
```
HGTEST_FORCE_PY2=1 python run-tests.py
```
----
Basically this diff are created with the following commands:
```
$ sed -i 's/import feature\(.*\)$/import feature\1\n\nfeature.require(["py2"])/' test-*-t.py
$ sed -i '1s/^/#require py2\n/' test-*.t
$ ls | grep -P "^test.*(?<\!-t)\.py$" > list && vim -p $(cat list)
# manually adding feature requires for these Python tests.
```
(Note: this ignores all push blocking failures!)
ignore-conflict-markers
Reviewed By: singhsrb
Differential Revision: D19655148
fbshipit-source-id: 985e3ccb4010cc559049f1d89f8909bc2d9b5e20
Summary:
Python errors wrapped in a Rust Error would be incorrectly changed into a
RuntimeError instead of the original one. The map_pyerr method does the right
thing, and is also shorter, let's use it.
Reviewed By: quark-zju
Differential Revision: D19313883
fbshipit-source-id: 1ecb41a8eef9d41618905d6d00f199252d373f96
Summary:
In preparation for merging fb-mercurial sources to the Eden repository,
move everything from the top-level directory into an `eden/scm`
subdirectory.