Fix copy_repo sending incorrect repo pairs when providing multiple pairs#333
Conversation
23f2ac3 to
c08eb6d
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #333 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 54 54
Lines 3011 3014 +3
=========================================
+ Hits 3011 3014 +3 ☔ View full report in Codecov by Sentry. |
| """The repo to which content was copied.""" | ||
|
|
||
|
|
||
| class partpartial(partial): |
There was a problem hiding this comment.
Minor: I am not really fond of the name, because to me it implies a weaker kind of partial ("part partial"), while this is actually stronger than a usual partial object. It freezes all the arguments, while I think partial's name comes from the fact that it's typically used to partially freeze/bind a function's arguments.
Not a big deal obviously, given it's not public API.
Some other ideas for names: freeze_arguments, bind_arguments, full_partial.
There was a problem hiding this comment.
Thanks for the insight.
"Part partial" came from the fact that it's not providing all the features of a "partial", hence the name. However, suggested names sounds more meaningful.
Copy_repo waits for the complete copy of non-rpm content before copying rpm content. However, there were some instances where previous repo pair was sent for non-rpm content copy when multiple repo pairs were provided. Lambda functions seems to be the reason for the error as they resolve the values during execution rather than creation, hence might be picking incorrect values. This patch replaces it with a modified partial function method that resolves the values during creation instead of execution.
c08eb6d to
6fedeac
Compare
Copy_repo waits for the complete copy of non-rpm content before copying rpm content. However, there were some instances where previous repo pair was sent for non-rpm content copy when multiple repo pairs were provided.
Lambda functions seems to be the reason for the error as they resolve the values during execution rather than creation, hence might be picking incorrect values. This patch replaces it with a modified partial function method that resolves the values during creation instead of execution.