<div dir="ltr">+1 to what Brian said. We ran into this question and the outcome was #5708.<br><div><br></div><div>While #5708 can help to fix the issue Pavel is describing, I believe the resolve_advisories was meant to be run for every repo version finalization.</div><div>I think there is a bug in the implementation if it doesn't work correctly for the mirror case. I filed a bug <a href="https://pulp.plan.io/issues/5924">https://pulp.plan.io/issues/5924</a>. </div><div><br></div><div>Tanya</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Dec 20, 2019 at 9:37 PM Brian Bouterse <<a href="mailto:bmbouter@redhat.com">bmbouter@redhat.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>I haven't looked very closely yet, but I see that the PR [1] has a conditional check in `finalize_new_version` here: <a href="https://github.com/pulp/pulp_rpm/pull/1568/files#diff-886596b2b9cc3257ce61648f8aab8ebfR124" target="_blank">https://github.com/pulp/pulp_rpm/pull/1568/files#diff-886596b2b9cc3257ce61648f8aab8ebfR124</a></div><div><br></div><div>When finalize_new_version was added, an issue came up similar to yours: "where should we put validation/checks that should only run some of the time"? I believe the consensus was that finalize_new_version should only contain checks that are safe to run in all situations. Plugin writers still need checks that can only be run during certain user operations, and so we filed this <a href="https://pulp.plan.io/issues/5708" target="_blank">https://pulp.plan.io/issues/5708</a> as a plugin API feature request.</div><div><br></div><div>Can you read <a href="https://pulp.plan.io/issues/5708" target="_blank">https://pulp.plan.io/issues/5708</a> and let us know if that would help you towards your goal?<br></div><div><br></div><div>Thanks,</div><div>Brian<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Dec 19, 2019 at 12:16 PM Pavel Picka <<a href="mailto:ppicka@redhat.com" target="_blank">ppicka@redhat.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">As working on RPM feature to mirror repository[1], it needs to bypass<br>
the resolve_advisory check. That means argument (if it is mirror or<br>
not) must be passed to Repositorys' new_version.<br>
<br>
I ran into part where pulpcore needs to updated [0] that this argument<br>
can be accepted everywhere.<br>
<br>
I'd like to avoid crashing other plugins which use the mirror feature<br>
so bringing this up to discussion how we want/can process this part.<br>
<br>
<br>
[0] <a href="https://github.com/pulp/pulpcore/compare/master...pavelpicka:5738-mirror-repo" rel="noreferrer" target="_blank">https://github.com/pulp/pulpcore/compare/master...pavelpicka:5738-mirror-repo</a><br>
[1] <a href="https://github.com/pulp/pulp_rpm/pull/1568/files" rel="noreferrer" target="_blank">https://github.com/pulp/pulp_rpm/pull/1568/files</a><br>
<br>
-- <br>
Pavel Picka<br>
Red Hat<br>
<br>
<br>
_______________________________________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pulp-dev</a><br>
<br>
</blockquote></div>
_______________________________________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pulp-dev</a><br>
</blockquote></div>