How do I fix a broken dnf Fedora28
After playing with conda and possibly reconfiguring python3, I find that dnf no longer works.
$ dnf
Traceback (most recent call last):
File "/usr/bin/dnf", line 57, in <module>
from dnf.cli import main
ModuleNotFoundError: No module named 'dnf'
I have tried using yum and rpm to reinstall dnf. They seem to point back to dnf. I have tried using the gnome software package to delete and install dnfdragora. I see no reference to dnf or dnf-core.
Have I exhausted the easy options?
My next step is to try rebuilding dnf from the github source https://github.com/rpm-software-manag... but the first step
sudo dnf builddep dnf.spec
doesn't look promising, but I will try it anyway. Maybe I can reroute the installation from a LiveCD?
I made some progress but no luck yet, from
I found I can reach the repositories at
and https://fedora.mirror.constant.com/fe... I was able to find and download the four rpm packages
and I am able to run rpm (unlike what I said above)
(cont)
and I am able to run rpm (unlike what I said above)
but I got warnings like /sbin/ldconfig: libraries libstdc++.so.6.0.24 and libstdc++.so.6.0.25 in directory /lib have same soname but different type.
(I may not be completely upto date.)
but running dnf still gives the error:
No module named 'dnf'
I'm beginning to think I have to reinstall Fedora.
as stated above I reinstalled dnf. I downloaded the python3 rpm, and a few of the python3-dnf rpms. but before I could install them with rpm, I ran into other problems. I think Gnome went unstable. I could not enter a password to unfreeze the screen. It looked like only one character was processed at a time. Then, after using power button to shut down, the system stopped booting - so I did a reinstall anyway
I think I will create a dedicated conda user and not install anaconda with sudo. Conda and dnf do not play well together.