exchange: introduce functionality to lock repos during each run

This introduces a exchange lock which writes a `.hg/scmperf-lock` file. This
will help us in someway which I am still not sure.
1 job from topic/default/exchange-lock in 9 minutes 4 seconds (queued for 2 minutes 27 seconds)
Status Job ID Name Coverage
failed #58116


Test tests-py2
 check the repos directory afterwards

ERROR: test-smoke-test.t output changed
Failed test-smoke-test-python3.t: output changed
Failed test-smoke-test.t: output changed
# Ran 11 tests, 0 skipped, 2 failed.
python hash seed: 264865318
ERROR: Job failed: exit code 1