What behavior did you expect?
I expect the server not to crash.
What was the actual behavior (provide screenshots if the issue is GUI-related)?
Server crashes on startup
How reliably can you reproduce the issue, what are the steps to do so?
Using my wallet (which I obviously can't share).
What version of Bitcoin Core are you using, where did you get it (website, self-compiled, etc)?
0.16.0, 0.16.1 on Ubuntu 16.04 0.15.1 does not crash
Additional info
$ bin/bitcoind -printtoconsole -addresstype=legacy
<snip>
2018-06-20 11:01:30 AddToWalletIfInvolvingMe: Detected a used keypool key, mark all keypool key up to this key as used
bitcoind: wallet/wallet.cpp:4237: void CWallet::LearnRelatedScripts(const CPubKey&, OutputType): Assertion `IsSolvable(*this, witprog)' failed.
Aborted (core dumped)