On Tue, 2015-12-01 at 10:44 -0500, Mike Frysinger wrote:
> On 24 Nov 2015 15:41, Joakim Tjernlund wrote:
> > Emerging on my embedded gentoo ppc target I see this:
> >   ....
> >   dev-lang/python-exec-2.0.1-r1::x-portage
> >   sys-apps/install-xattr-0.5::x-portage
> >   sys-libs/timezone-data-2015f::x-portage
> > 
> > Where does the name x-portage come from? I do not have a repo
> > named x-portage, it is still named gentoo.
> 
> it has no name so one is auto-created using the path.

Ahh, this must be the repos.conf/repo_name conflict/mess.
I have a name in repos.conf but I have deleted the profiles/repo_name file in
the repo.

This inconsistency could use some portage (and related tools) love. There is 
also a bug
https://bugs.gentoo.org/show_bug.cgi?id=563874

> pym/portage/repository/config.py:
>     @staticmethod
>     def _read_valid_repo_name(repo_path):
>         name, missing = RepoConfig._read_repo_name(repo_path)
>         # We must ensure that the name conforms to PMS 3.1.5
>         # in order to avoid InvalidAtom exceptions when we
>         # use it to generate atoms. 
>         name = _gen_valid_repo(name)
>         if not name:
>             # name only contains invalid characters
>             name = "x-" + os.path.basename(repo_path) 
>             name = _gen_valid_repo(name)
>             # If basename only contains whitespace then the
>             # end result is name = 'x-'.
>         return name, missing
> 
>     @staticmethod
>     def _read_repo_name(repo_path):
>         """
>         Read repo_name from repo_path.
>         Returns repo_name, missing.
>         """
>         repo_name_path = os.path.join(repo_path, REPO_NAME_LOC)
>         f = None
>         try:
>             f = io.open(
>                 _unicode_encode(repo_name_path,
>                 encoding=_encodings['fs'], errors='strict'),
>                 mode='r', encoding=_encodings['repo.content'],
>                 errors='replace')
>             return f.readline().strip(), False
>         except EnvironmentError:
>             return "x-" + os.path.basename(repo_path), True
>         finally:
>             if f is not None:
>                 f.close()
> -mike

Reply via email to