Red Hat Bugzilla – Bug 1262247
change in behavior of dnf api - read_comps needs root privileges
Last modified: 2016-07-19 13:51:35 EDT
The behavior of function read_comps() from Base class was changed with the recent update of dnf-1.1.1, now read_comps(), while executing, tries to open file /var/lib/dnf/groups.json in write mode and as such fails with exception if not run under the user with proper privileges.
> $ ls -l /var/lib/dnf/groups.json
-rw-r--r--. 1 root root 3228 Sep 11 10:57 /var/lib/dnf/groups.json
395 with open(self._dbfile, 'w') as db:
396 json.dump(self.db.dct, db)
This is new in dnf-1.1.1 (when compared to dnf-1.1.0).
We can execute converting of db in %postin dnf scriplet.
This package has changed ownership in the Fedora Package Database. Reassigning to the new owner of this component.
Fedora 22 changed to end-of-life (EOL) status on 2016-07-19. Fedora 22 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.
If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
Thank you for reporting this bug and we are sorry it could not be fixed.