[OpenWalnut-Dev] abort: outstanding uncommitted changes

Mathias Goldau math at informatik.uni-leipzig.de
Tue Jul 10 10:44:39 CEST 2012


Ahh, don't even try it. All those extensions are not shipped with mercurial
for a reason: they don't work. And I should have backuped my 2h work. Really I
should have backuped before trying them.

First I tried: hg shelve http://mercurial.selenic.com/wiki/ShelveExtension and
downloaded from http://bitbucket.org/tksoh/hgshelve/

hg shelve always gave me:
abort: shelve data already exists
hg unshelve gave me then
nothing to unshelve
even `hg shelve -l` didn't worked and also the test-shelve scripts weren't
successfull. I've read then this mailinglist item:
http://selenic.com/pipermail/mercurial/2010-April/031612.html advertising
hgattic instead: http://mercurial.selenic.com/wiki/AtticExtension and
downloaded from here  https://bitbucket.org/Bill_Barry/hgattic.`hg shelve`
worked this way for me:

hg shelve
** unknown exception encountered, please report by visiting
**  http://mercurial.selenic.com/wiki/BugTracker
** Python 2.7.3 (default, Apr 20 2012, 22:39:59) [GCC 4.6.3]
** Mercurial Distributed SCM (version 2.0.2)
** Extensions loaded: convert, graphlog, extdiff, churn, record, mq, hgattic
Traceback (most recent call last):
  File "/usr/bin/hg", line 38, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 27, in run
    sys.exit(dispatch(request(sys.argv[1:])))
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 64, in
dispatch
    return _runcatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 87, in
_runcatch
    return _dispatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 655, in
_dispatch
    repo = hg.repository(ui, path=path)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 98, in repository
    hook(ui, repo)
  File "/home/math/repos/hgattic/attic.py", line 693, in reposetup
    repo.attic = attic(ui, repo.join(''))
  File "/home/math/repos/hgattic/attic.py", line 60, in __init__
    self.opener = util.opener(self.path)
AttributeError: 'module' object has no attribute 'opener'
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/apport_python_hook.py", line 64, in
apport_excepthook
    from apport.fileutils import likely_packaged, get_recent_crashes
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 95,
in _demandimport
    return _import(name, globals, locals, fromlist, level)
  File "/usr/lib/python2.7/dist-packages/apport/__init__.py", line 1, in <module>
    from apport.report import Report
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 114,
in _demandimport
    mod = _origimport(name, globals, locals)
  File "/usr/lib/python2.7/dist-packages/apport/report.py", line 155, in <module>
    class Report(problem_report.ProblemReport):
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 86,
in __getattribute__
    self._load()
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 58,
in _load
    mod = _origimport(head, globals, locals)
  File "/usr/lib/python2.7/dist-packages/problem_report.py", line 93, in <module>
    class ProblemReport(UserDict):
TypeError: Error when calling the metaclass bases
    module.__init__() takes at most 2 arguments (3 given)

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/hg", line 38, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 27, in run
    sys.exit(dispatch(request(sys.argv[1:])))
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 64, in
dispatch
    return _runcatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 87, in
_runcatch
    return _dispatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 655, in
_dispatch
    repo = hg.repository(ui, path=path)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 98, in repository
    hook(ui, repo)
  File "/home/math/repos/hgattic/attic.py", line 693, in reposetup
    repo.attic = attic(ui, repo.join(''))
  File "/home/math/repos/hgattic/attic.py", line 60, in __init__
    self.opener = util.opener(self.path)
AttributeError: 'module' object has no attribute 'opener'


then I tried to see what has happend to my changes:


hg st
** unknown exception encountered, please report by visiting
**  http://mercurial.selenic.com/wiki/BugTracker
** Python 2.7.3 (default, Apr 20 2012, 22:39:59) [GCC 4.6.3]
** Mercurial Distributed SCM (version 2.0.2)
** Extensions loaded: convert, graphlog, extdiff, churn, record, mq, hgattic
Traceback (most recent call last):
  File "/usr/bin/hg", line 38, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 27, in run
    sys.exit(dispatch(request(sys.argv[1:])))
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 64, in
dispatch
    return _runcatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 87, in
_runcatch
    return _dispatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 655, in
_dispatch
    repo = hg.repository(ui, path=path)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 98, in repository
    hook(ui, repo)
  File "/home/math/repos/hgattic/attic.py", line 693, in reposetup
    repo.attic = attic(ui, repo.join(''))
  File "/home/math/repos/hgattic/attic.py", line 60, in __init__
    self.opener = util.opener(self.path)
AttributeError: 'module' object has no attribute 'opener'
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/apport_python_hook.py", line 64, in
apport_excepthook
    from apport.fileutils import likely_packaged, get_recent_crashes
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 95,
in _demandimport
    return _import(name, globals, locals, fromlist, level)
  File "/usr/lib/python2.7/dist-packages/apport/__init__.py", line 1, in <module>
    from apport.report import Report
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 114,
in _demandimport
    mod = _origimport(name, globals, locals)
  File "/usr/lib/python2.7/dist-packages/apport/report.py", line 155, in <module>
    class Report(problem_report.ProblemReport):
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 86,
in __getattribute__
    self._load()
  File "/usr/lib/python2.7/dist-packages/mercurial/demandimport.py", line 58,
in _load
    mod = _origimport(head, globals, locals)
  File "/usr/lib/python2.7/dist-packages/problem_report.py", line 93, in <module>
    class ProblemReport(UserDict):
TypeError: Error when calling the metaclass bases
    module.__init__() takes at most 2 arguments (3 given)

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/hg", line 38, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 27, in run
    sys.exit(dispatch(request(sys.argv[1:])))
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 64, in
dispatch
    return _runcatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 87, in
_runcatch
    return _dispatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 655, in
_dispatch
    repo = hg.repository(ui, path=path)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 98, in repository
    hook(ui, repo)
  File "/home/math/repos/hgattic/attic.py", line 693, in reposetup
    repo.attic = attic(ui, repo.join(''))
  File "/home/math/repos/hgattic/attic.py", line 60, in __init__
    self.opener = util.opener(self.path)
AttributeError: 'module' object has no attribute 'opener'


Ahh forget both of them!
Mathias

BTW: Disabling the module in hgrc at least gives me valid `hg st` I will check
if files have changed and repository state. Lousy shelve pansen!

On 05.07.2012 11:15, Mathias Goldau wrote:
> On 05.07.2012 10:54, Christof Pieloth wrote:
>> Hello,
>>
>> I have not really investigated the problem, but as far as I know you use "git
>> stash"in the git world to do this. It seems to be, thatthe mercurial extension
>> "shelve" is the git equivalent.
>> http://mercurial.selenic.com/wiki/ShelveExtension
>>
>> In my opinion, all solutions using copy, change directories etc. are unhandy.
>> Today, amodern VCS should do all the stuff for me.
> 
> Yes, I was always a bit envy that Alex could do that cool git-stash-apply
> stuff with git and wanted this for hg too. I've just looked again to the hg
> shelve extention and they state:
> 
> hg shelve --all
> hg unshelve
> 
> should exactly do that. Next time I will try it :D.
> 
> Cheers,
> Mathias
> 


-- 
Institut für Informatik
Universität Leipzig
Johannisgasse 26, 04103 Leipzig
Phone: +493419732283




More information about the OpenWalnut-Dev mailing list