[avalanche] Test framework: don't assume the p2p avaproof messages are using the legacy format
Summary: This is continuing the work from D11117 to remove the test framework assumptions about the proof format. This diff attempts to deserialize the p2p messages with the new format, and fallback to the legacy format if it fails. This makes the event callback work with both the new and legacy formats, and the test can still check the type match expectation if needed. The correct fallback handling is demonstrated by the tests still passing.
Test Plan:
ninja check-functional-extended
Reviewers: #bitcoin_abc, PiRK
Reviewed By: #bitcoin_abc, PiRK
Differential Revision: https://reviews.bitcoinabc.org/D11121