0

I am looking to upgrade from Fedora 27 however, DNF has broken somehow.

$ dnf upgrade
Traceback (most recent call last):
  File "/bin/dnf", line 58, in <module>
    main.user_main(sys.argv[1:], exit_code=True)
  File "/usr/lib/python3.6/site-packages/dnf/cli/main.py", line 179, in user_main
    errcode = main(args)
  File "/usr/lib/python3.6/site-packages/dnf/cli/main.py", line 64, in main
    return _main(base, args, cli_class, option_parser_class)
  File "/usr/lib/python3.6/site-packages/dnf/cli/main.py", line 99, in _main
    return cli_run(cli, base)
  File "/usr/lib/python3.6/site-packages/dnf/cli/main.py", line 115, in cli_run
    cli.run()
  File "/usr/lib/python3.6/site-packages/dnf/cli/cli.py", line 1013, in run
    self._process_demands()
  File "/usr/lib/python3.6/site-packages/dnf/cli/cli.py", line 766, in _process_demands
    load_available_repos=self.demands.available_repos)
  File "/usr/lib/python3.6/site-packages/dnf/base.py", line 353, in fill_sack
    self._add_repo_to_sack(r)
  File "/usr/lib/python3.6/site-packages/dnf/base.py", line 122, in _add_repo_to_sack
    hrepo.filelists_fn = repo._filelists_fn
TypeError: Expected a string or a unicode object

Here are the versions of the packages I have installed:

$ rpm -q dnf python3-dnf python3 python3-rpm
dnf-2.7.5-2.fc27.noarch
python3-dnf-2.7.5-2.fc27.noarch
python3-3.6.6-1.fc27.x86_64
python3-rpm-4.14.2.1-1.fc27.x86_64

I have tried re-installing the dnf package from koji (https://koji.fedoraproject.org/koji/buildinfo?buildID=1006088), but it didn't make a difference. I am not sure what else I can try. I haven't used dnf in a while since it became EOL but now I would like to upgrade, and it has surprised me with this error. Is it possible to track down what has occurred so I can fix dnf and eventually upgrade?

0

So I asked this question on the Fedora Project forum, see the full conversation here: https://ask.fedoraproject.org/t/fedora-27-dnf-throwing-python-error-cannot-upgrade/1463

tl;dr - I had to disable a PlexRepo then run dnf clean all then dnf upgrade --refresh. Doing those commands without disabling the PlexRepo would throw the error, so there must have been a problem with that repository.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.