[Bug 5695] New: Crash on attempting to fetch length of dirstate map

mercurial-bugs at mercurial-scm.org mercurial-bugs at mercurial-scm.org
Sun Oct 1 15:45:07 UTC 2017


https://bz.mercurial-scm.org/show_bug.cgi?id=5695

            Bug ID: 5695
           Summary: Crash on attempting to fetch length of dirstate map
           Product: Mercurial
           Version: 4.3-rc
          Hardware: PC
                OS: Mac OS
            Status: UNCONFIRMED
          Severity: feature
          Priority: wish
         Component: Mercurial
          Assignee: bugzilla at mercurial-scm.org
          Reporter: swhitaker at fb.com
                CC: mercurial-devel at mercurial-scm.org

perftweaks._trackdirstatesizes is crashing because it (legitimately) calls
len() on dirstate._map, but the new dirstatemap class introduced in b36881c6
doesn't implement len().

hg-crew (0133ca3|remote/@) $ hg version
Mercurial Distributed SCM (version 4.3-rc+7-ec0025a85466)
Facebook Mercurial release: dev

(see https://mercurial-scm.org for more information)

Copyright (C) 2005-2017 Matt Mackall and others
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
hg-crew (0133ca3|remote/@) $ hg st
Traceback (most recent call last):
  File "/Users/swhitaker/src/facebook-hg-rpms/hg-crew/mercurial/dispatch.py",
line 311, in _callcatch
    return scmutil.callcatch(ui, func)
  File "/Users/swhitaker/src/facebook-hg-rpms/hg-crew/mercurial/scmutil.py",
line 151, in callcatch
    return func()
  File "/Users/swhitaker/src/facebook-hg-rpms/hg-crew/mercurial/dispatch.py",
line 293, in _runcatchfunc
    return _dispatch(req)
  File "/Users/swhitaker/src/facebook-hg-rpms/hg-crew/mercurial/dispatch.py",
line 929, in _dispatch
    cmdpats, cmdoptions)
  File
"/Users/swhitaker/src/facebook-hg-rpms/fb-hgext/hgext3rd/fastpartialmatch.py",
line 105, in _runcommand
    res = orig(lui, repo, cmd, fullargs, ui, *args, **kwargs)
  File "/Users/swhitaker/src/facebook-hg-rpms/fb-hgext/hgext3rd/undo.py", line
113, in _runcommandwrapper
    result = orig(lui, repo, cmd, fullargs, *args)
  File "/Users/swhitaker/src/facebook-hg-rpms/hg-crew/hgext/journal.py", line
84, in runcommand
    return orig(lui, repo, cmd, fullargs, *args)
  File
"/Users/swhitaker/src/facebook-hg-rpms/fb-hgext/fastmanifest/__init__.py", line
181, in _logonexit
    r = orig(ui, repo, cmd, fullargs, *args)
  File "/Users/swhitaker/src/facebook-hg-rpms/fb-hgext/hgext3rd/perftweaks.py",
line 271, in _tracksparseprofiles
    res = runcommand(lui, repo, *args)
  File "/Users/swhitaker/src/facebook-hg-rpms/fb-hgext/hgext3rd/perftweaks.py",
line 267, in _trackdirstatesizes
    lui.log('dirstate_size', '', dirstate_size=len(dirstate._map))
TypeError: object of type 'dirstatemap' has no len()

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Mercurial-devel mailing list