Changelog limit doesn't work properly with --compatibility
andrewlukoshko opened this issue · 2 comments
If run createrepo_c --compatibility --changelog-limit=10 .
then changelog will not be limited because of this code:
createrepo_c/src/createrepo_c.c
Line 1262 in ace4c87
if (cmd_options->compatibility && cmd_options->changelog_limit == DEFAULT_CHANGELOG_LIMIT ) {
user_data.changelog_limit = -1;
} else {
user_data.changelog_limit = cmd_options->changelog_limit;
}
I'm pretty sure --changelog-limit=10 should force limit.
Thank you for the report, I think the --compatibility
option is not used very much so this issue has a low priority for us right now.
I believe that was intentional, actually b66ff10
IMO this ought to be changed in the next breaking change release, though. Keeping all changelogs is much more obviously broken these days than it probably was at the time. It can cause quite serious scalability issues with the metadata, cause OOM errors, and other anomolous behavior.
Or perhaps given the above, we can just change it now? It's not even documented as something that the --compatibility
flag does.