This is an archive of the discontinued Mercurial Phabricator instance.

store: refactor space delimited list to proper tuple
ClosedPublic

Authored by pulkit on Aug 7 2020, 8:44 AM.

Details

Summary

There is no good reason why are having a space delimited list and then using
.split() to get the actual list. Let's convert this into a proper tuple.

Diff Detail

Repository
rHG Mercurial
Branch
default
Lint
No Linters Available
Unit
No Unit Test Coverage

Event Timeline

pulkit created this revision.Aug 7 2020, 8:44 AM
indygreg accepted this revision.Aug 8 2020, 1:01 PM
This revision is now accepted and ready to land.Aug 8 2020, 1:01 PM
indygreg added inline comments.Aug 8 2020, 1:13 PM
mercurial/store.py
458
+    File "/home/gps/src/hg-committed/mercurial/store.py", line 458, in copylist
+      return [b'requires'] + _data
+  TypeError: can only concatenate list (not "tuple") to list

I think I'll just change _data to a list in-flight.