This revision was automatically updated to reflect the committed changes.
Closed by commit rHG328ca3b9e545: branchmap: encapsulate cache updating in the
map itself (authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGbf7fb97aecf1: branchmap: make branchcache responsible for
reading (authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGc795c462b1d6: branchmap: add some clarifications and clean
up flow (authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGeb7ce452e0fb: branchmap: updating triggers a write
(authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5636?vs=13331=13807
mjpieters updated this revision to Diff 13543.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5638?vs=13502=13543
REVISION DETAIL
https://phab.mercurial-scm.org/D5638
AFFECTED FILES
contrib/perf.py
mercurial/branchmap.py
mercurial/localrepo.py
mjpieters updated this revision to Diff 13542.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5635?vs=13501=13542
REVISION DETAIL
https://phab.mercurial-scm.org/D5635
AFFECTED FILES
contrib/perf.py
mercurial/branchmap.py
CHANGE DETAILS
diff --git
mjpieters added inline comments.
INLINE COMMENTS
> martinvonz wrote in perf.py:2299
> Same here: I think this needs to be made compatible with both versions
> (before and after this patch)
I'll wait for confirmation; see the other patch.
> martinvonz wrote in localrepo.py:2077
> Hmm, it's
mjpieters updated this revision to Diff 13502.
mjpieters marked an inline comment as done.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5638?vs=1=13502
REVISION DETAIL
https://phab.mercurial-scm.org/D5638
AFFECTED FILES
contrib/perf.py
mjpieters updated this revision to Diff 13501.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5635?vs=13330=13501
REVISION DETAIL
https://phab.mercurial-scm.org/D5635
AFFECTED FILES
contrib/perf.py
mercurial/branchmap.py
CHANGE DETAILS
diff --git
mjpieters added inline comments.
INLINE COMMENTS
> martinvonz wrote in discovery.py:242-243
> Indentation seems bad (seemed bad before too)
It's a generator expression as single argument. I was deliberately not making
style changes in these patches, so I didn't touch the indentation here.
If
mjpieters added a subscriber: yuja.
mjpieters added inline comments.
INLINE COMMENTS
> martinvonz wrote in perf.py:2326
> As I was recently reminded by Yuya, the perf commands are supposed to be
> compatible with older versions of hg too, and this doesn't seem to be
> compatible with the
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG3461814417f3: branchmap: rename partial - bcache
(authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5290?vs=13329=13490
mjpieters added a comment.
@yuja: you wanted separate commits, you got separate commits. :-)
(and apologies for taking so long)
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5290
To: mjpieters, #hg-reviewers
Cc: yuja, mercurial-devel
mjpieters abandoned this revision.
mjpieters added a comment.
This would need more thought then; the evolve/topic/topicmap codebase wraps
the whole branchmap.branchcache class and mucks about with a context manager to
re-instate the right name in the branchmap globals so super() doesn't
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
Rather than have a repository update the cache, move handling of cache updates
into the branchmap module, in the form of a custom mapping class.
This makes
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
- Remove indentation where it is not needed.
- Swap the subset test branches to follow along logically and put the 'empty'
case last.
REPOSITORY
rHG
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
Encapsulate reading in a classmethod, to make it clear what kind of object is
being handled.
This is part of a stack of refactoring changes to help
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
Rather than separate updating and writing, create a subclass that doesn't
write
on update. This minimises chances we forget to write out updates somewhere.
mjpieters updated this revision to Diff 13329.
mjpieters edited the summary of this revision.
mjpieters retitled this revision from "branchmap: refactor for better
encapsulation" to "branchmap: rename partial -> bcache".
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
mjpieters added a comment.
The goal of this refactor is to bring clarity to the branchmap cache
behaviour, and to make it easier to add performance improvements (in an
upcoming additional series of patches).
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5290
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
The _branchcache global gives us a reference for super() to use even if an
extension subclasses branchmap.branchcache then replaces the class in the
module.
mjpieters added a comment.
In https://phab.mercurial-scm.org/D5064#78545, @av6 wrote:
> I look at the changes and see nitpicks at best. On the one hand, black
proved better than any linter that we can already write consistent code. On the
other, if black were a linter... I'd switch to
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5290
AFFECTED FILES
contrib/perf.py
mercurial/branchmap.py
mercurial/discovery.py
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG5644f7c8982e: branchmap: remove redundant sort (authored by
mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5111?vs=12157=12158
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
There is absoluty no benefit in sorting a list that's being merged into a set
on the next line. The changelog.ancestors() call later on also doesn't benefit
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG47084b5ffd80: style: drop requirement to only use single
lines between top-level objects (authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
mjpieters added a subscriber: indygreg.
mjpieters added a comment.
This was split out from https://phab.mercurial-scm.org/D5064 (cc @indygreg )
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5105
To: mjpieters, #hg-reviewers
Cc: indygreg, mercurial-devel
mjpieters updated this revision to Diff 12135.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5064?vs=12059=12135
REVISION DETAIL
https://phab.mercurial-scm.org/D5064
AFFECTED FILES
contrib/import-checker.py
mercurial/cacheutil.py
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5105
AFFECTED FILES
contrib/check-commit
CHANGE DETAILS
diff --git a/contrib/check-commit
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG8cf459d8b111: py3: use py3 as the test tag, dropping the k
(authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
mjpieters added a comment.
Note: I undid the change to `mercurial/thirdparty/zope/interface/_compat.py`
as it should not have been changed to begin with.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5079
To: mjpieters, #hg-reviewers, pulkit, durin42
Cc:
mjpieters updated this revision to Diff 12091.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5079?vs=12068=12091
REVISION DETAIL
https://phab.mercurial-scm.org/D5079
AFFECTED FILES
mercurial/help.py
tests/hghave.py
tests/run-tests.py
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5079
AFFECTED FILES
mercurial/help.py
mercurial/thirdparty/zope/interface/_compat.py
mjpieters updated this revision to Diff 12059.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5064?vs=12047=12059
REVISION DETAIL
https://phab.mercurial-scm.org/D5064
AFFECTED FILES
contrib/check-commit
contrib/import-checker.py
mjpieters updated this revision to Diff 12047.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D5064?vs=12030=12047
REVISION DETAIL
https://phab.mercurial-scm.org/D5064
AFFECTED FILES
mercurial/cacheutil.py
mercurial/diffhelper.py
mjpieters added a comment.
The `import` parentheses collapsing is described here:
https://github.com/ambv/black#parentheses. The behavior is not configurable.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5064
To: mjpieters, indygreg, durin42, #hg-reviewers
mjpieters created this revision.
mjpieters added reviewers: indygreg, durin42.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
This applied black to the 20 smallest files in mercurial/:
ls -S1 mercurial/*.py | tail -n20 | xargs black
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGf16c3efe35e3: perf: time loading branchmap caches (authored
by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D4280?vs=10352=10373
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG9a800691f075: branchmap: load branchmap as an iterable
(authored by mjpieters, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D4281?vs=10353=10374
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
This avoids reading all the file into memory if the cache turns out to be
invalid.
REPOSITORY
rHG Mercurial
REVISION DETAIL
mjpieters created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D4280
AFFECTED FILES
contrib/perf.py
CHANGE DETAILS
diff --git a/contrib/perf.py b/contrib/perf.py
+timing_stats = timedcmstats(level=timedcm._nested)
> > +try:
> > +yield timing_stats
> > +finally:
> > +timing_stats.elapsed = timer() - timing_stats.start
> > +timedcm._nested -= 1
> > +
> > +timedcm._nest
# HG changeset patch
# User Martijn Pieters
# Date 1533239583 -3600
# Thu Aug 02 20:53:03 2018 +0100
# Branch stable
# Node ID d7c68ee641ff02542680bdaa4bff95a348db688e
# Parent 07ca3b8354d59c70db5f10448e53d4bbfd50e72e
# EXP-Topic debugextensions
util: make new timedcmstats class Python 3
# HG changeset patch
# User Martijn Pieters
# Date 1533058674 -7200
# Tue Jul 31 19:37:54 2018 +0200
# Branch stable
# Node ID 92180b2297bd8bff6e2f3bc9d6e4ea71ed9e
# Parent 23e31b60983e3fb78aeb8822de8c630798f46447
# EXP-Topic persistentmanifestcache
manifest: persist
# HG changeset patch
# User Martijn Pieters
# Date 1533157442 -7200
# Wed Aug 01 23:04:02 2018 +0200
# Branch stable
# Node ID 23e31b60983e3fb78aeb8822de8c630798f46447
# Parent e06a10d3b926844b5a933ec2b8f2b70cf1fb941e
# EXP-Topic persistentmanifestcache
debug: allow specifying a manifest
I accidentally added a v2 flag to this. Mea Culla, there is no v1.
Martijn
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
# HG changeset patch
# User Martijn Pieters
# Date 1533132341 -7200
# Wed Aug 01 16:05:41 2018 +0200
# Branch stable
# Node ID 2bad2ee57e26f05f99a81715e781f7978515b705
# Parent 545a3e6650cd8f7e19c0f0256082837a33bea029
# EXP-Topic debugextensions
utils: create a context manager to handle
# HG changeset patch
# User Martijn Pieters
# Date 1533132413 -7200
# Wed Aug 01 16:06:53 2018 +0200
# Branch stable
# Node ID 07ca3b8354d59c70db5f10448e53d4bbfd50e72e
# Parent 2bad2ee57e26f05f99a81715e781f7978515b705
# EXP-Topic debugextensions
extensions: add detailed loading information
# HG changeset patch
# User Martijn Pieters
# Date 1533058674 -7200
# Tue Jul 31 19:37:54 2018 +0200
# Branch stable
# Node ID b17ebb3cc106e209c0f8b40fc10e45656a9b8fd2
# Parent aeabcb9ce5d398de42f623320873a789b94ba2b8
# EXP-Topic persistentmanifestcache
manifest: persist
# HG changeset patch
# User Martijn Pieters
# Date 1533058668 -7200
# Tue Jul 31 19:37:48 2018 +0200
# Branch stable
# Node ID aeabcb9ce5d398de42f623320873a789b94ba2b8
# Parent e06a10d3b926844b5a933ec2b8f2b70cf1fb941e
# EXP-Topic persistentmanifestcache
debug: allow specifying a manifest
# HG changeset patch
# User Martijn Pieters
# Date 1531769057 -3600
# Mon Jul 16 20:24:17 2018 +0100
# Node ID 6b76d41520cded0655a6214fdd515014a23b6b9c
# Parent 2a227782e75426a3e4408273a9a4eebe79dfdcea
# EXP-Topic persistentmanifestcache
manifest: persist the manifestfulltext cache
# HG changeset patch
# User Martijn Pieters
# Date 1531315693 -3600
# Wed Jul 11 14:28:13 2018 +0100
# Node ID 39bc6540388e79da1a670fcd382aa77b8aa27224
# Parent 4d5fb4062f0bb159230062701461fa6cab9b539b
# EXP-Topic fncache_prevent_load_when_exists
fncache: avoid loading the filename cache
Review handled on Phabricator, at https://phab.mercurial-scm.org/D830
On 27 September 2017 at 13:59, Martijn Pieters <m...@zopatista.com> wrote:
> # HG changeset patch
> # User Martijn Pieters <mjpiet...@fb.com>
> # Date 1506517103 -3600
> # Wed Sep 27 13:58:2
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1506517103 -3600
# Wed Sep 27 13:58:23 2017 +0100
# Node ID 64cc414eabb05a260f664682516c264cce04d02c
# Parent 5289a6772ae59a8da42c75c508152997fcc1bb1a
tests: re-order tags and bookmarks in tracking test
Core
mjpieters accepted this revision.
mjpieters added a comment.
I was being too strict; like `open()` it's sometimes fine to apply the action
in the constructor.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D472
To: martinvonz, #hg-reviewers, quark, mjpieters
mjpieters added inline comments.
INLINE COMMENTS
> extensions.py:408-412
> +origfn = getattr(container, funcname)
> +assert callable(origfn)
> +wrap = bind(wrapper, origfn)
> +_updatewrapper(wrap, origfn, wrapper)
> +setattr(container, funcname, wrap)
On 18 May 2017, at 19:22, Gregory Szorc <gregory.sz...@gmail.com> wrote:
> On Wed, Mar 15, 2017 at 11:09 AM, Martijn Pieters <m...@zopatista.com
> <mailto:m...@zopatista.com>> wrote:
> # HG changeset patch
> # User Martijn Pieters <mjpiet...@fb.com <mailto:mj
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1489356745 25200
# Sun Mar 12 15:12:25 2017 -0700
# Node ID c363e933a66bb85ddbfe8301bbfd246ecaad95d6
# Parent 719e64bf9ec2d7b8e86b6550a5d193b3c67944d1
py3: initial type hinting stubs
These are stub files to b
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1489348572 25200
# Sun Mar 12 12:56:12 2017 -0700
# Node ID 22c38e571b5ccf3bb6d9f075526170954843f37a
# Parent 719e64bf9ec2d7b8e86b6550a5d193b3c67944d1
config: avoid using a mutable default
Nothing *currently* m
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1489340031 25200
# Sun Mar 12 10:33:51 2017 -0700
# Node ID 55a2a84cb75e7bbfb9dcd510b686de417fb9dfab
# Parent abf029200e198878a4576a87e095bd8d77d9cea9
config: honour the trusted flag in ui.configint
diff --git a/mer
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1489299699 28800
# Sat Mar 11 22:21:39 2017 -0800
# Node ID 8be2b42b977c09ca7405dc671e160300a887aa5e
# Parent abf029200e198878a4576a87e095bd8d77d9cea9
config: honour the trusted flag in ui.configint
diff --git a/mer
_
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
join` only, you want to use a list comp
here, not a generator expression, as it is faster and more memory efficient:
_xchar = pycompat.bytechr
_keepalnum = ''.join(c for c in map(_xchar, range(256))
if not c.isalnum())
--
On 16 Feb 2017, at 16:35, Augie Fackler > wrote:
> +if pycompat.ispy3:
> +_unicodes = [bytes([c]).decode('latin1') for c in range(256)]
> +_notalnum = [s.encode('latin1') for s in _unicodes if not s.isalnum()]
...
> +_keepalnum =
"Mercurial-devel on behalf of Martijn Pieters" <
mercurial-devel-boun...@mercurial-scm.org on behalf of m...@zopatista.com>
wrote:
>
> # HG changeset patch
> # User Martijn Pieters <mjpiet...@fb.com>
> # Date 1480435818 0
> # Tue Nov 29 16:10:18 201
vec,
> debugrename, debugwireargs?)
>
> (Or am I missing something obvious?)
>
This was caused by remotefilelog looking for the debugindex command in the
command table without importing the new mercurial.debugcommand module; I've
committ
On 29 November 2016 at 20:43, Martijn Pieters <m...@zopatista.com> wrote:
> On 17 November 2016 at 18:44, Mads Kiilerich <m...@kiilerich.com> wrote:
> >
> > # HG changeset patch
> > # User Mads Kiilerich <mad...@unity3d.com>
> > # Date 1421194526 -3
ile or directory
+ [1]
$ cat .hg/localtags
- 4e7abb4840c46a910f6d7b4d3c3fc7e5209e684c lfoo
- 430ed4828a74fa4047bc816a25500f7472ab4bfe lbar
+ cat: .hg/localtags: No such file or directory
+ [1]
$ cat ../b/.hgtags
4e7abb4840c46a910f6d7b4d3c3fc7e5209e684c foo
ERROR: test-hardlinks.t output chan
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1480435818 0
# Tue Nov 29 16:10:18 2016 +
# Node ID 28a092ed406e930894c59eb88d645221abddc307
# Parent cb2bac3253fbd52894ffcb4719a148fe6a3da38b
wireproto: chunking and compression is forthwith to be handled by
il.py: error importing: No module
> named 'mercurial.cffi' (error at check-py3-compat.py:*)
>
> Ok, but you'll get a different error if you have cffi installed.
>
Hrm, so how can we best make this conditional?
> _______
file.write(clock + '\0')
> @@ -98,8 +104,6 @@
> if notefiles:
> file.write('\0'.join(notefiles))
> file.write('\0')
> -finally:
> -file.close()
>
> def invalidate(self):
> try:
&g
http://bugs.python.org/issue1633941, where you can provoke the bug by using
^Z while reading from stdin.
Also, before Python 2.7.4 (including 2.6) there is no EINTR handling *at
all*, all reading operations that can be interrupted are affected. See
http://bugs.python.org/issue12268, which aimed at fi
> On 11 Nov 2016, at 12:54, Yuya Nishihara <y...@tcha.org> wrote:
>
> On Thu, 10 Nov 2016 17:01:22 +, Martijn Pieters wrote:
>>> On 10 Nov 2016, at 13:09, Yuya Nishihara <y...@tcha.org> wrote:
>>> On Wed, 09 Nov 2016 11:23:38 -0500, Augie Fackler wrote
> On 10 Nov 2016, at 13:09, Yuya Nishihara wrote:
>
> On Wed, 09 Nov 2016 11:23:38 -0500, Augie Fackler wrote:
>> # HG changeset patch
>> # User Augie Fackler
>> # Date 1476019730 14400
>> # Sun Oct 09 09:28:50 2016 -0400
>> # Node ID
d
> ___________
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
On 21 Oct 2016, at 14:08, timeless wrote:
> Is there a checkcode test for this?
No, but tests simply fail when you make this mistake. In this *specific case*
that was only visible in the Python 3 tests because the base classes used in
Python 2 were old-style classes, so in
On 16 Oct 2016, at 15:30, Pierre-Yves David
wrote:
>
>> py3: use namedtuple._replace to produce new tokens
>
> We seems to be using a private function of some stdlib type?
> Can you elaborate on why this is a good move?
It is not private. This is one of the
On 15 Oct 2016, at 08:39, Yuya Nishihara <y...@tcha.org> wrote:
>
> On Fri, 14 Oct 2016 17:55:25 +0100, Martijn Pieters wrote:
>> # HG changeset patch
>> # User Martijn Pieters <mjpiet...@fb.com>
>> # Date 1476464102 -3600
>> # F
> This loop would never stop if malformed tokens were provided. I guess you
> had a working version in which _isop() could raise IndexError.
Nice catch! I'll turn the `while True` into a `for j in xrange(i + 2,
len(tokens)):` loop instead, and avoid IndexError or looping to infinity
altogether.
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476347257 -3600
# Thu Oct 13 09:27:37 2016 +0100
# Node ID d20dd7db86044bdca79825499b913840d726d841
# Parent 9031460519503abe5dc430c8ece29d198121cd65
py3: use namedtuple._replace to produce new tokens
diff
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476464102 -3600
# Fri Oct 14 17:55:02 2016 +0100
# Node ID 9031460519503abe5dc430c8ece29d198121cd65
# Parent 733fb9f7bc92c694ba6bededaeb93206528c0bcd
py3: refactor token parsing to handle call args properly
The
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476350485 -3600
# Thu Oct 13 10:21:25 2016 +0100
# Node ID 36607cf1bbd9fd4d99b607f927bc807fcc48d0ea
# Parent 733fb9f7bc92c694ba6bededaeb93206528c0bcd
py3: refactor token parsing to handle call args properly
The
> Nice refactor. While I haven't looked at the code in detail yet, does
> check-code not complain about the use of underscore_function_names?
Apparently not! I did run the whole test suite, and ran it again just now.
Nested function names are locals and exempt from the rule it appears.
Should
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476347257 -3600
# Thu Oct 13 09:27:37 2016 +0100
# Node ID 22a15130f57927a79227ebfe763be082e2992f04
# Parent 81d23b9e2b329666db6e342f6bafec54a893687c
py3: use namedtuple._replace to produce new tokens
diff
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476346188 -3600
# Thu Oct 13 09:09:48 2016 +0100
# Node ID 81d23b9e2b329666db6e342f6bafec54a893687c
# Parent 733fb9f7bc92c694ba6bededaeb93206528c0bcd
py3: refactor token parsing to handle call args properly
The
On 12 Oct 2016, at 14:00, Yuya Nishihara wrote:
> FWIW, the current transformer will also rewrite open(f('foo')).
This then also applies to getattr(f('foo'), ...). We'll need to assert that the
3rd token is a comma, I think.
signature.asc
Description: Message signed with
ument is not converted to a `bytes` object instead.
You can compare this to the "if fn in ('getattr', 'setattr', 'hasattr',
'safehasattr'):" block above this change.
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-s
On 10 October 2016 at 21:47, Yuya Nishihara <y...@tcha.org> wrote:
> Do we still need this after 1f01e3e6 "py3: a second argument to open
> can't be bytes" ?
>
I don't think so, no, but I haven't explicitly tested this l
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476137475 -3600
# Mon Oct 10 23:11:15 2016 +0100
# Node ID d74c594b68768d14d9414b0ebe062d1b0bdd542a
# Parent 8d079c0594b35dfbf57baf8d83fde686a946920a
pycompat: only accept a bytestring filepath in Python 2
diff
only
needed in 3 really.
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476027863 -7200
# Sun Oct 09 17:44:23 2016 +0200
# Node ID 1fef9008cbd2098f058f1458df4d59552da88c16
# Parent 82489cd912f332be976cf432673ad47af0d04cd7
py3: add an os.fsencode backport to ease path handling
diff
_
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
try:
> mod = _importh("hgext.%s" % name)
> ___________
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
+ value = self._data[self.encodekey(key)]
> +File "/usr/lib/python3.5/os.py", line 754, in encode
> + raise TypeError("str expected, not %s" % type(value).__name__)
> + TypeError: str expected, not bytes
> + [1]
> ___
> Mercurial-devel mailing list
&g
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1476012788 -7200
# Sun Oct 09 13:33:08 2016 +0200
# Node ID 096d7a42fe6425bf741b09d47e77b387c6180ca4
# Parent a56076f85aa6aa728457ecc571ff58514bc59896
py3: a second argument to open can't be bytes
diff --git a/mer
al-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
# HG changeset patch
# User Martijn Pieters <mjpiet...@fb.com>
# Date 1475946679 -7200
# Sat Oct 08 19:11:19 2016 +0200
# Node ID 8475a954a40385035b57abe05af31308597a0b3c
# Parent 2c8ec8c2ddfeb2d229b81eb5b11e3639fb34b0a0
hgweb: fix the MRO in Python 3
object should appear at t
arobj._table.items():
> symbols[name] = func
> if func._safe:
> safesymbols.add(name)
> ___
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
, 256):
> > ___
> > Mercurial-devel mailing list
> > Mercurial-devel@mercurial-scm.org
> > https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
> ___
> Mercurial-devel
error at patch.py:*)
>mercurial/templatekw.py: error importing: module
> 'mercurial.util' has no attribute 'stringio' (error at patch.py:*)
> ___
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
--
Martijn Pieters
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
1 - 100 of 113 matches
Mail list logo