See https://github.com/bitcoin/bitcoin/pull/22762#issuecomment-951063826

This can be fixed by creating a new exception type and catching it in the right place.

#### Useful skills:

* C++ exceptions
* Addrman serialization
* Functional tests

#### Want to work on this issue?

For guidance on contributing, please read [CONTRIBUTING.md](https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md) before opening your pull request.

{
    return m_impl->size();
}
bool AddrMan::Add(const std::vector<CAddress>& vAddr, const CNetAddr& source, int64_t nTimePenalty)
{
    return m_impl->Add(vAddr, source, nTimePenalty);
}
bool AddrMan::Good(const CService& addr, int64_t nTime)
{
    return m_impl->Good(addr, nTime);
}
void AddrMan::Attempt(const CService& addr, bool fCountFailure, int64_t nTime)
{
    m_impl->Attempt(addr, fCountFailure, nTime);
}
void AddrMan::ResolveCollisions()
{
    m_impl->ResolveCollisions();
}
std::pair<CAddress, int64_t> AddrMan::SelectTriedCollision()