Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't run v0.7.6 with latest PyQt5 version #1011

Closed
JackDinn opened this issue Jun 8, 2021 · 11 comments
Closed

Can't run v0.7.6 with latest PyQt5 version #1011

JackDinn opened this issue Jun 8, 2021 · 11 comments

Comments

@JackDinn
Copy link

JackDinn commented Jun 8, 2021

I just had a vorta update
[2021-06-08T17:20:16+0100] [ALPM] upgraded vorta (0.7.5-1 -> 0.7.6-1)

Now it won't run and i can't figure out exactly what iv got to do?

❰greg❙~❱✔≻ vorta
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 568, in _build_master
    ws.require(__requires__)
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 886, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 777, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (PyQt5 5.15.4 (/usr/lib/python3.9/site-packages), Requirement.parse('pyqt5<=5.15.3'), {'vorta'})

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/vorta", line 33, in <module>
    sys.exit(load_entry_point('vorta==0.7.5', 'gui_scripts', 'vorta')())
  File "/usr/bin/vorta", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/usr/lib/python3.9/importlib/metadata.py", line 77, in load
    module = import_module(match.group('module'))
  File "/usr/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 855, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/usr/lib/python3.9/site-packages/vorta/__main__.py", line 10, in <module>
    from vorta.models import init_db
  File "/usr/lib/python3.9/site-packages/vorta/models.py", line 17, in <module>
    from vorta.utils import slugify
  File "/usr/lib/python3.9/site-packages/vorta/utils.py", line 21, in <module>
    from vorta.borg._compatibility import BorgCompatibility
  File "/usr/lib/python3.9/site-packages/vorta/borg/_compatibility.py", line 1, in <module>
    from pkg_resources import parse_version
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3243, in <module>
    def _initialize_master_working_set():
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3226, in _call_aside
    f(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3255, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 570, in _build_master
    return cls._build_from_requirements(__requires__)
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 583, in _build_from_requirements
    dists = ws.resolve(reqs, Environment())
  File "/usr/lib/python3.9/site-packages/pkg_resources/__init__.py", line 772, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'pyqt5<=5.15.3' distribution was not found and is required by vorta
❰greg❙~❱✘≻ 

I thought it might be pyqt5 but i have the latest version:-
1 extra/python-pyqt5 5.15.4-1 (4.2 MiB 26.7 MiB) [pyqt5] (Installed)

Kernel: 5.10.41-1-MANJARO x86_64 bits: 64 compiler: gcc v: 11.1.0
parameters: BOOT_IMAGE=/boot/vmlinuz-5.10-x86_64
root=UUID=bfe48f69-800c-4332-b8ea-0df162b1710d rw quiet apparmor=1
security=apparmor udev.log_priority=3
Desktop: KDE Plasma 5.21.5 tk: Qt 5.15.2 wm: kwin_x11 vt: 1 dm: SDDM
Distro: Manjaro Linux base: Arch Linux

@snuffop
Copy link

snuffop commented Jun 8, 2021

+1

@m3nu
Copy link
Contributor

m3nu commented Jun 8, 2021

I thought it might be pyqt5 but i have the latest version:-
1 extra/python-pyqt5 5.15.4-1 (4.2 MiB 26.7 MiB) [pyqt5] (Installed)

PyInstaller doesn't support the latest PyQt5 version yet. So I had to restrict it to the one before. Please use that.

@m3nu m3nu changed the title Cant run after update Can't run v0.7.6 with latest PyQt5 version Jun 8, 2021
@JackDinn
Copy link
Author

JackDinn commented Jun 8, 2021

Sorry, i dont know how?

@m3nu
Copy link
Contributor

m3nu commented Jun 8, 2021

This works on a fresh install. Sorry for the trouble. Sometimes we have to limit the version of Qt. It's not the first time.

$ pip uninstall PyQt5-Qt5 PyQt5-Qt PyQt5
$ pip install 'pyqt5<=5.15.3'

@m3nu m3nu pinned this issue Jun 8, 2021
@JackDinn
Copy link
Author

JackDinn commented Jun 8, 2021

Well yes it did work for vorta, thank you for that :)

It has made a bit of a mess to all my own pyqt GUI's for my app's/scripts, its made all the controls (buttons and tabs) go grey. I can live with the different themes for them, they are not to much different. I have tinkered with KDE theming, but I can't figure how to get them back how they were, i don't have the time atm, just glad vorta is working again.
Screenshot_20210608_184433

@JackDinn JackDinn closed this as completed Jun 8, 2021
@snuffop
Copy link

snuffop commented Jun 9, 2021

The problem here is calibre and qutebrowser work fine and requre the latest 5.15.4 yet vorta fails..

@m3nu
Copy link
Contributor

m3nu commented Jun 9, 2021

I got a segmentation fault using PyQt5 5.15.4. If you know how to avoid this, please share it with us or open a pull request, @snuffop 🙏

@m3nu m3nu reopened this Jun 9, 2021
@Eeems
Copy link

Eeems commented Jun 9, 2021

For those wondering about PyQt5 5.15.4 support in pyinstaller, it's been merged (pyinstaller/pyinstaller#5631) but there hasn't been a new release that includes it yet.

@damentz
Copy link

damentz commented Jun 10, 2021

I modified Vorta's requires.txt [1] file to not require pyqt5<=5.15.3 on my system, and it runs fine with 5.15.4. Maybe the segmentation fault is coming from something else?

For reference, I run Arch, all latest packages as of this post.

[1] /usr/lib/python3.9/site-packages/vorta-0.7.5-py3.9.egg-info/requires.txt

@jose1711
Copy link

No segfaults with 5.15.4 either (Arch here as well). @damentz Thanks for sharing!

@m3nu m3nu mentioned this issue Jun 20, 2021
m3nu added a commit to m3nu/vorta that referenced this issue Jun 21, 2021
@m3nu m3nu closed this as completed in 5d54150 Jun 21, 2021
@m3nu
Copy link
Contributor

m3nu commented Jun 21, 2021

Did a new release which pins PyQt5 only for PyInstaller builds, since it's not strictly needed for other deployments.

https://github.com/borgbase/vorta/releases/tag/v0.7.7

@m3nu m3nu unpinned this issue Nov 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants