Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 540012 - app-portage/layman-2.3.0 - ReposConf: ConfigHandler.read(); Failed to read "/etc/portage/repos.conf/layman.conf
Summary: app-portage/layman-2.3.0 - ReposConf: ConfigHandler.read(); Failed to read "/...
Status: IN_PROGRESS
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Third-Party Tools (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Layman Overlay Manager project
URL:
Whiteboard:
Keywords: InVCS
: 550150 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-02-13 19:32 UTC by Piotr Karbowski
Modified: 2016-01-02 01:24 UTC (History)
7 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Piotr Karbowski archtester Gentoo Infrastructure gentoo-dev Security 2015-02-13 19:32:58 UTC
The 2.3.0 version of layman seems to crash hard on adding and removing overlays if /etc/portage/repos.conf/layman.conf does not exist.

+ layman -L
+ sed 's@check_official : Yes@check_official : No@g' -i /etc/layman/layman.cfg
+ layman -a foo-overlay
Cloning into '/var/lib/layman/foo-overlay'...

 * Adding overlay...
 * Running Git... # ( cd /var/lib/layman  && /usr/bin/git clone git://github.com/slashbeast/foo-overlay.git /var/lib/layman/foo-overlay )
 * Running Git... # ( cd /var/lib/layman/foo-overlay  && /usr/bin/git config user.name "layman" )
 * Running Git... # ( cd /var/lib/layman/foo-overlay  && /usr/bin/git config user.email "layman@localhost" )
 * ReposConf: ConfigHandler.read(); Failed to read "/etc/portage/repos.conf/layman.conf".
 * File not found.

 * CLI: Errors occurred processing action add
 * ReposConf: ConfigHandler.read(); Failed to read "/etc/portage/repos.conf/layman.conf".
 * File not found.
 * Exception caught installing repository 'foo-overlay' : ConfigHandler instance has no attribute 'repo_conf'



Reproducible: Always
Comment 1 Thomas Capricelli 2015-02-16 23:21:16 UTC
same here. I guess it's kinda related to the recent repos.conf news, but not sure how.

It's quite severe here : after doing "layman -d kde", /var/lib/layman/kde was indeed removed, but not from the installed.xml file. So that layman -a would not work anymore and the whole system is broken. I'm still searching how to fix it.
Comment 2 Thomas Capricelli 2015-02-16 23:33:49 UTC
for info: locally masking >=2.3.0 fixes it here.
Comment 3 Brian Dolbec gentoo-dev 2015-02-17 05:10:27 UTC
fixed in commit:

https://github.com/gentoo/layman/commit/afece9a3634defccebd86d161d21e5475f3fea3c

expect a layman version bump soon.
Comment 4 Juergen Rose 2015-02-17 14:05:42 UTC
I have a similar error. At a new gentoo installation I wanted to add an overlay.
'layman -a sunrise' sunrise complains about missing /etc/portage/repos.conf/layman.conf. I really have an empty /etc/portage/repos.conf directory, which I already created manually. Should this file /etc/portage/repos.conf/layman.conf be created manually or automatically by 'layman -a'?



sysresccd src # layman -l


sysresccd src # layman -a sunrise

 * Adding overlay...
 * Running Git... # ( cd /var/lib/layman  && /usr/bin/git clone git://git.overlays.gentoo.org/proj/sunrise-reviewed.git /var/lib/layman/sunrise )
Cloning into '/var/lib/layman/sunrise'...
remote: Counting objects: 96034, done.
remote: Compressing objects: 100% (42030/42030), done.
remote: Total 96034 (delta 52362), reused 95991 (delta 52319)
Receiving objects: 100% (96034/96034), 31.30 MiB | 121.00 KiB/s, done.
Resolving deltas: 100% (52362/52362), done.
Checking connectivity... done.
 * Running Git... # ( cd /var/lib/layman/sunrise  && /usr/bin/git config user.name "layman" )
 * Running Git... # ( cd /var/lib/layman/sunrise  && /usr/bin/git config user.email "layman@localhost" )
 * ReposConf: ConfigHandler.read(); Failed to read "/etc/portage/repos.conf/layman.conf".
 * File not found.

 * CLI: Errors occurred processing action add
 * ReposConf: ConfigHandler.read(); Failed to read "/etc/portage/repos.conf/layman.conf".
 * File not found.
 * Exception caught installing repository 'sunrise' : 'ConfigHandler' object has no attribute 'repo_conf'
Comment 5 Brian Dolbec gentoo-dev 2015-02-17 16:42:34 UTC
For your error if you run "layman-updater -R"  it will make the file with the installed overlay that you added.  It should work normally now.

I have it fixed now in git.
Comment 6 Juergen Rose 2015-02-18 08:46:50 UTC
(In reply to Brian Dolbec from comment #5)
> For your error if you run "layman-updater -R"  it will make the file with
> the installed overlay that you added.  It should work normally now.
> 
> I have it fixed now in git.

Thanks, that helped a little bit. I have now cat /var/lib/layman/make.conf.
But there is a further problem. I added four reposiories:

sysresccd src # layman -l

 * sage-on-gentoo            [Git       ] (git://github.com/cschwan/sage-on-gentoo.git                                                                               )
 * science                   [Git       ] (git://git.overlays.gentoo.org/proj/sci.git                                                                                )
 * sunrise                   [Git       ] (git://git.overlays.gentoo.org/proj/sunrise-reviewed.git                                                                   )
 * x11                       [Git       ] (git://git.overlays.gentoo.org/proj/x11                                                                                    )

I find them all in /etc/portage/repos.conf/layman.conf, but only two are present in /var/lib/layman/make.conf:

sysresccd src # cat /var/lib/layman/make.conf
PORTDIR_OVERLAY="
/var/lib/layman/science
/var/lib/layman/sunrise
$PORTDIR_OVERLAY
"
Comment 7 Brian Dolbec gentoo-dev 2015-02-18 08:55:26 UTC
There is no need for the make.conf file.  You can delete it.  The new repos.conf/ file passes all the info to portage.

It is possible for layman to make both it's make.conf and repos.conf/layman.conf files, but only one is needed.  The make.conf file is the old method.
Comment 8 Juergen Rose 2015-02-18 16:53:05 UTC
(In reply to Brian Dolbec from comment #7)
> There is no need for the make.conf file.  You can delete it.  The new
> repos.conf/ file passes all the info to portage.
> 
> It is possible for layman to make both it's make.conf and
> repos.conf/layman.conf files, but only one is needed.  The make.conf file is
> the old method.

OK, thanks for the information.
Comment 9 Brian Dolbec gentoo-dev 2015-05-22 13:37:13 UTC
*** Bug 550150 has been marked as a duplicate of this bug. ***
Comment 10 Fabio Rossi 2015-10-19 08:50:14 UTC
When do you expect to release a version of layman > 2.3.0 which includes the fix from the git repository?