AttributeError: module ‘sys’ has no attribute ‘maxint’

In python3, sys.maxint changed to sys.maxsize.

Here are the values:

Python2

>>> sys.maxint
9223372036854775807

Python3

>>> sys.maxsize
9223372036854775807

On the same platform, the values match. The value is typically 2**31 - 1 on a 32-bit platform and 2**63 - 1 on a 64-bit platform.

Replacing your call to maxint with maxsize will stop this particular Traceback.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)