Hi, I'm running the following to determine the packages that belong to a user and it returns empty: portageq -n --no-filters --maintainer-email 'itumaykin+gentoo@gmail.com' --repo gentoo If I change the code to do an exact string match, it works fine. We should either do that, or escape regex-sensitive characters properly.
The --help output says that it accepts regexes: Package matching options: --maintainer-email MAINTAINER_EMAIL comma-separated list of maintainer email regexes to search for So, the assumption is that you'll escape special characters yourself. If we change the behavior, then we'll be breaking compatibility with previous versions (and also with pkgcore's pquery that the --maintainer-email option was copied from). If we use re.escape(), then people won't be able to use regexes anymore. I suppose we could add a new option which automatically escapes regexes for you, like --maintainer-email-no-regex or something like that.
Maybe we should add a --no-regex flag that would affect the behavior of the --maintainer-email arguments.
I like the '--no-regex' flag, although it's not evidently clear that it applies to '--maintainer-email'. I'll change it up and submit another patch.
This is in the master branch: https://gitweb.gentoo.org/proj/portage.git/commit/?id=aa57d60d9c77a46f542475dcf448c83af40e73e1
Fixed in portage-2.3.5.