portage (i don't know since when) up to at least 2.1-r2 can sync with an empty portage tree, it will thow a few error messages but sync and refresh an completely empty tree, whereas portage 2.1.1 fails with an error and makes one fetch a portage snapshot form a mirror, install this one first and then can sync again error message: Traceback (most recent call last): File "/usr/bin/emerge", line 4012, in ? emerge_main() File "/usr/bin/emerge", line 3731, in emerge_main settings, trees, mtimedb = load_emerge_config() File "/usr/bin/emerge", line 3642, in load_emerge_config trees = portage.create_trees(trees=trees, **kwargs) File "/usr/lib/portage/pym/portage.py", line 6736, in create_trees config_incrementals=portage_const.INCREMENTALS) File "/usr/lib/portage/pym/portage.py", line 955, in __init__ for k, v in rawpusemask.iteritems(): AttributeError: 'NoneType' object has no attribute 'iteritems' this possibility was nice to empty out one's portage tree which had already 'splattered' throughout the whole partition and get a new one nicely in one place, which done from time to time made sync'ing, portage operations and even the whole system somewhat faster again. dirk.
Created attachment 94110 [details, diff] fix the AttributeError This is fixed in svn r4240. If you save the patch as /tmp/AttributeError.patch, then you can apply it as follows: cd /usr/lib/portage patch -p0 < /tmp/AttributeError.patch
simple temporary fix: mkdir -p /etc/portage/profile
This has been released in 2.1.1_pre5-r1.