Unable to perfectly round-trip releases pointed at by occurrences
The current model for occurrences and releases makes it impossible to list the releases that appear for a given origin at a given time.
When we store an occurrence that points to a release, we "peel" the release until we find a revision, and store that.
This means that when we want to list the releases that were found on a given origin, we need to "backtrack" all the releases that point to some revisions that have been found in the origin. We therefore get a superset of the releases found at the origin (nothing prevents another origin from having other annotated releases pointing to the revisions we have in our origin).
One possible solution would be to let occurrences point to releases instead of being peeled down to revisions.
Migrated from T78 (view on Phabricator)