HdrHistogram_py icon indicating copy to clipboard operation
HdrHistogram_py copied to clipboard

HdrHistogram.encode() crashes

Open saifjarboui opened this issue 1 year ago • 0 comments

os : windows python 3.11

  File "C:\Users\saifeddine.jarboui\AppData\Roaming\JetBrains\PyCharmCE2024.2\scratches\scratch_4.py", line 7, in __getstate__
    state = self.encode()
            ^^^^^^^^^^^^^
  File "C:\Workspace\antlyzer\venv311\Lib\site-packages\hdrh\histogram.py", line 425, in encode
    return self.encoder.encode()
           ^^^^^^^^^^^^^^^^^^^^^
  File "C:\Workspace\antlyzer\venv311\Lib\site-packages\hdrh\codec.py", line 303, in encode
    cpayload = self.payload.compress(relevant_length)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Workspace\antlyzer\venv311\Lib\site-packages\hdrh\codec.py", line 227, in compress
    varint_len = encode(addressof(self.counts), counts_limit,
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OverflowError: Python int too large to convert to C long

saifjarboui avatar Oct 04 '24 10:10 saifjarboui