Some packages like media-libs/elementary-1.17.0 set KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-interix ~x86-solaris ~x64-solaris amd64 x86" (in part via the eclass, but that is handled in bug 486392) https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/elementary/elementary-1.17.0.ebuild?id=dc476a8696977481fd245254220c1ad334dd8287 This confuses at least repoman (bug 584560) and eshowkw (bug 584598). It would be good if the next EAPI could explicitly state whether setting e.g. KEYWORDS="arch ~arch" is allowed.
Sorry, I meant bug 584600 for repoman
The PMS section referenced in URL merely describes an existing convention, and it was only added because some explanation of keyword semantics was needed for the use.stable.mask etc. files (introduced in EAPI 5). I rather see this as an issue of tree policy than something that should be codified in PMS. Also, isn't it obvious that "arch ~arch" is redundant and equivalent to "arch"?
I think KEYWORDS="arch" does not imply "~arch" in all cases.
Well, it isn't obvious, though it is kinda implicit. I would look at it using the old 'opaque' meaning of keywords. Stable profiles have ACCEPT_KEYWORDS=foo, testing has 'foo ~foo'. Now, a stable ebuild having 'foo' is matched by both. A testing ebuild having '~foo' is matched by the latter. An ebuild having 'foo ~foo' is implicitly matched by both as well, since the first system matches 'foo' alone, and the second one matches both. Giving special meaning to 'foo' and '~foo', we made that a bit blurry.
If the current status quo shall remain unchanged, at the very least I would add a statement to PMS 7.3.2 "It is possible that the KEYWORDS variable indicates multiple levels of stability for a single architecture. The behavior of the package manager in this case is implementation defined."