If the DESCRIPTION variable must be limited repoman should test length of the DESCRIPTION variable. Today there are 2398 ebuilds in the tree ignoring the limit [1] which can be used for testing the new repoman function. [1] qgrep -C -N DESCRIPTION= | sed -e "s/DESCRIPTION=//g" | awk '{split($0,a,":"); if (length(a[2])>81) print a[1] " --> " a[2]}' Reproducible: Always
repoman has a DESCRIPTION.toolong error message, that is prompted if you run "repoman full" on a package.
Thank you for pointing me to that. The stable repoman 2.2.20.1 did not have this feature yet, but found it now with your hint on [1]. But I do not understand why max_desc_len = 100 79 CHAR from devman + 14 CHAR for DESCRIPTION="" = 93 CHAR in sum [1] https://github.com/gentoo/portage/blob/master/pym/repoman/checks/ebuilds/variables/description.py [2] https://github.com/gentoo/portage/blob/master/pym/repoman/qa_data.py#L11
(In reply to Jonas Stein from comment #2) > The stable repoman 2.2.20.1 did not have this feature yet, [...] Sure it has. That test is there since a long time. > But I do not understand why > max_desc_len = 100 > > 79 CHAR from devman > + 14 CHAR for DESCRIPTION="" > = 93 CHAR in sum Repoman will trigger a warning if the string between the "" is longer than 100. This doesn't include the length of the variable name. But indeed, if the devmanual says 80 characters then repoman should warn if the length is greater than 80 characters. So max_desc_len should be 80 not 100. CCing QA.
Yep. There was a comment suggesting that 'DESCRIPTION=' is taken into consideration but the code proves otherwise. I'm sending a patch to gentoo-portage-dev@ to fix it.
Fix committed now, repoman will complain if DESCRIPTIONS is longer than 80 characters.
Thank you for the patch. But I think it is not fully in accordance with devman yet, where it says: "*less* than 80 characters" https://github.com/gentoo/portage/blob/master/pym/repoman/checks/ebuilds/variables/description.py#L27 tests for: if len(pkg._metadata['DESCRIPTION']) > max_desc_len: so https://github.com/gentoo/portage/blob/master/pym/repoman/qa_data.py#L10 should be max_desc_len = 79 instead of max_desc_len = 80 or the test shuld be >=
In that case, I think >= would be better (to match the devmanual wording). Of course I can do the change if someone else confirms. I'm sure people are going to hate me even more for taking their precious 1 character and causing their perfectly awesome packages to generate warnings once more.
(In reply to Michał Górny from comment #7) > In that case, I think >= would be better (to match the devmanual wording). > Of course I can do the change if someone else confirms. Please don't. The devmanual's wording is mostly informal, therefore I would not take it for granted that the intention was to exclude equality. Also 79 characters would be a very unusual limit. Also, "less" refers to quantity, not to number. So presumably the devmanual should be updated to say "not more than 80 characters" or "strictly fewer than 80 characters".
(In reply to Ulrich Müller from comment #8) > Also, "less" refers to quantity, not to number. So presumably the devmanual > should be updated to say "not more than 80 characters" or "strictly fewer > than 80 characters". I've committed that change to the devmanual, see bug 562806. Can this bug be closed (again)?