TypeError: QProgressBar.setMaximum(int): argument 1 has unexpected type 'long' while cloning

Issue #2261 resolved
Anonymous created an issue
** Mercurial version (2.3.2).  TortoiseHg version (2.5.1)
** Command: --nofork clone
** CWD: E:\Projects\hgRepo
** Encoding: cp1252
** Extensions loaded: acl, churn, eol, relink, mercurial_keyring, transplant, CoveoExtensions, reviewboard, checkfiles, extdiff, share
** Python version: 2.7.3 (default, Apr 10 2012, 23:24:47) [MSC v.1500 64 bit (AMD64)]
** Windows version: sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1')
** Processor architecture: x64
** Qt-4.8.0 PyQt-4.9.1
Traceback (most recent call last):
  File "tortoisehg\hgqt\cmdui.pyo", line 127, in progress
  File "tortoisehg\hgqt\cmdui.pyo", line 61, in setcounts
TypeError: QProgressBar.setMaximum(int): argument 1 has unexpected type 'long'

Comments (4)

  1. Georg Dietrich

    Same problem occurred here, too. Repository is >2GB, yes. Luckily, clone still works OK. However, if I close the Bug Report windows during clone, it re-opens again immediately.

  2. Yuya Nishihara

    cmdui: always set percentage to QProgressBar (fixes #2261)

    Mercurial's progress value can exceed INT_MAX when cloning repository over 2GB, which causes TypeError on x86 and would result invalid value even on amd64 because C int is 32bit.

    To avoid the problem, this patch simply converts progress value to percentage.

    → <<cset e58f19aa05d0>>

  3. Log in to comment