[PATCH] histedit: add support for exec/x command to histedit (issue4036)

Piotr Listkiewicz piotr.listkiewicz at gmail.com
Sun Oct 25 12:15:03 CDT 2015


>
> One thing I forgot to mention, invalidateall() is wrapped by MQ. It is
> necessary for command server to clear mq status and mq path. So "histedit
> exec"
> might need to call invalidateall().


Added this in Patch V3

2015-10-25 17:08 GMT+00:00 Yuya Nishihara <yuya at tcha.org>:

> On Sun, 25 Oct 2015 16:33:15 +0000, Piotr Listkiewicz wrote:
> > >
> > >  My point here is that if some command changed stuff (new commit,
> > >
> > >     bookmark location etc), some of it might not be detected by the
> > >     current process that already parsed them from disk and naively
> > >     assume they did not changed since it hold the lock.
> > >     I would like to see some investigation to know if we need to do
> > >     something special (or if it is already handled, for example by the
> > >     lock). to make sure we are safe here.
> > >
> > > We should talk about this, i still have no idea how can i check this or
> > > what to do with it
> > > Sid, Foozy and yuya are good people discuss this
> > >
> > From my investigation and talk with yuya i think that all caches are
> > cleared:
> >
> > finally:
> >     self.state.wlock = repo.wlock(times=wlockheld)
> >     self.state.lock   = repo.lock(times=lockheld)
> >
> > repo.wlock invoke lock constructor with acquirefn callback set to
> > localrepo.invalidatedirstate.
> >
> > repo.lock invoke lock constructor with acquirefn callback set to
> > localrepo.invalidate.
> >
> > invalidateall function in localrepository has invocation only to
> invalidate
> > and invalidatedirstate.
> >
> > So if acquiring those two locks dont clear all caches that would mean
> that
> > localrepository.invalidateall has bug right now.
>
> One thing I forgot to mention, invalidateall() is wrapped by MQ. It is
> necessary for command server to clear mq status and mq path. So "histedit
> exec"
> might need to call invalidateall().
>
> Regards,
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20151025/a9887118/attachment.html>


More information about the Mercurial-devel mailing list