In my code:
def unpack_data(self, unpacker, payload):
"""
Unpack binary data from buffer given to the format specified.
Parameters
----------
unpacker: str
Format to unpack the data into
payload: bytes
Data to unpack
Returns
-------
tuple
Values unpacked as per format specified.
"""
try:
output = unpack(unpacker, payload)
except:
breakpoint()
return output
When I run some code that calls the function above, I am getting a struct.error: unpack requires a buffer of 81 bytes
When I print the unpacker
-> <IIqqqIqI8sBqqq
When I print payload
-> <memory at 0x7fc14631fa00>
Any ideas how I can overcome this issue? (I wasn’t sure how to inspect the payload
too)