This assertion was triggered after F39 final freeze lifted, and one of the many updates included the splitting out of a -libs subpackage from a runtime dependency. At least in that case, the solution is to update the runtime, but without a message it is difficult to debug.
"{package.name} dependency cannot be resolved" is not an accurate representation here. The package was resolved - the problem is that we can't figure out why it was resolved.
What I suggested on IRC:
I'd also stick to asking for a raise not an assert. Including the tag name will require passing cli_data to collate_packages().