Did you try HAL_I2C_Master_Receive_IT? If it gets a NACK, it's going to do something. Either go to the error interrupt or still hit the transfer complete interrupt. Either way, it probably has enough information in the state machine to discern how many bytes were received.
"If you feel a post has answered your question, please click ""Accept as Solution""."
This is a general deficiency in the HAL, as it likely does interrupt for each byte you could probably override the lackluster implementation by goosing the appropriate counter within the device instance..
Look at the logic the code calling the call-back implements. The source is open and reviewable.
Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..