Colorbleed / maya-capture-gui

GUI front-end for maya-capture
MIT License
76 stars 29 forks source link

libshiboken: Overflow: #68

Open melMass opened 6 years ago

melMass commented 6 years ago

On maya 2017 I have the following error.

Replacing sys.maxint with maxint = 2 ** (struct.Struct('i').size * 8 - 1) - 1 works.

BigRoy commented 6 years ago

Can you post the exact error? How to reproduce it? And also, how come this fixes it?

melMass commented 6 years ago

Sorry about that, I just posted it quickly as I was fixing it.

So it's in the file timeplugin.py line 106 sys.maxintreturns 9223372036854775807

and trigger the following error:

# RuntimeWarning: libshiboken: 
Overflow: Value -9223372036854775807 exceeds limits of type  [signed] "i" (4bytes)., at line 106, in "${HOME}/Library/Preferences/Autodesk/maya/2017/scripts/capture_gui/plugins/timeplugin.py"
# OverflowError
# RuntimeWarning: libshiboken: Overflow: Value 9223372036854775807 exceeds limits of type  [signed] "i" (4bytes)., at line 106, in ${HOME}/Library/Preferences/Autodesk/maya/2017/scripts/capture_gui/plugins/timeplugin.py"

Whereas 2 ** (struct.Struct('i').size * 8 - 1) - 1 which computes C's maxint returns 2147483647