dnf problems with fc29
FedoraForum.org - Fedora Support Forums and Community
Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2007
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    dnf problems with fc29

    I used pip to upgrade to python 3.7. Now dnf is broken:
    # dnf list python
    Traceback (most recent call last):
    File "/usr/bin/dnf", line 57, in <module>
    from dnf.cli import main
    File "/usr/lib/python3.7/site-packages/dnf/__init__.py", line 30, in <module>
    import dnf.base
    File "/usr/lib/python3.7/site-packages/dnf/base.py", line 29, in <module>
    import libdnf.transaction
    ModuleNotFoundError: No module named 'libdnf'

    Any ideas?[

  2. #2
    Join Date
    Oct 2014
    Location
    Texas, USA
    Posts
    69
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: dnf problems with fc29

    I had a similar problem some time back, but luckily I was using dnf to do the update.

    dnf refused to update dnf because some python packages that were required for the newer dnf version had not fully synchronized in the mirrors. This is when dnf switched from using python2 to python3.
    Because I used dnf, the attempted update did not break dnf. Instead it required that I wait for the mirrors to sync, then properly did the update to dnf after the required python packages were updated and all dependencies were satisfied.

    Pip does not comply with the package dependencies for the system. Instead it only downloads/installs the python modules you ask for without regard for dependencies.

    I would suggest that you try booting from a live dvd or usb and then use dnf to reinstall dnf and python3. You will need to use the --installroot option so dnf can correctly install the packages into the real system instead of the live system. That command would be something like "dnf reinstall dnf python3 --installroot=/path/to/real/root --best --allowerasing". Reinstalling both python3 and dnf should fix the problem with broken/missing modules in python which dnf uses and depends on.

    For future reference, you should ALWAYS do a "dnf update -y" before doing anything that has a possibility of replacing/changing packages that could break the currently installed packages and for a version change to python (or any other interpreter) do the update using dnf before you use pip to update the modules.
    My system has both python 2.7.15 and python 3.7.2 installed (F29)

Similar Threads

  1. [SOLVED]
    After upgrade to FC29, tear on 3rd monitor
    By bobx001 in forum Hardware & Laptops
    Replies: 4
    Last Post: 26th February 2019, 12:51 AM
  2. [SOLVED]
    FC29 - HPLip woes
    By bobx001 in forum Using Fedora
    Replies: 1
    Last Post: 6th February 2019, 02:38 PM
  3. [FC29] no sound from a generic usb headset
    By wodel in forum Hardware & Laptops
    Replies: 1
    Last Post: 2nd January 2019, 03:09 PM
  4. [SOLVED]
    F29 (4.18.16-300.fc29.x86_64, Workstation): NFS fails
    By ThumbTack in forum Servers & Networking
    Replies: 4
    Last Post: 15th November 2018, 09:46 AM
  5. [SOLVED]
    [FC29] Upgrade 28 -> 29 SELinux alrert
    By Ex_Soft in forum Installation, Upgrades and Live Media
    Replies: 1
    Last Post: 7th November 2018, 06:49 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •