From a832a5ea8b5c7ff34ebf1a6bd87f5dc3dd58041a Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 11 Jan 2007 23:15:19 +0000 Subject: [PATCH] Allow catpkgsplit to be less strict for atoms that come from installed packages (for backward compatibility). svn path=/main/trunk/; revision=5577 --- pym/portage_versions.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pym/portage_versions.py b/pym/portage_versions.py index dffcdd3b1..b80e3739e 100644 --- a/pym/portage_versions.py +++ b/pym/portage_versions.py @@ -270,6 +270,7 @@ def catpkgsplit(mydata,silent=1): # Categories may contain a-zA-z0-9+_- but cannot start with - global _valid_category + import portage_dep try: if not catcache[mydata]: return None @@ -282,7 +283,8 @@ def catpkgsplit(mydata,silent=1): retval=["null"] p_split=pkgsplit(mydata,silent=silent) elif len(mysplit)==2: - if not _valid_category.match(mysplit[0]): + if portage_dep._dep_check_strict and \ + not _valid_category.match(mysplit[0]): raise InvalidData("Invalid category in %s" %mydata ) retval=[mysplit[0]] p_split=pkgsplit(mysplit[1],silent=silent) -- 2.26.2