srevinsaju / guiscrcpy

A full fledged GUI integration for the award winning open-source android screen mirroring system -- scrcpy located on https://github.com/genymobile/scrcpy/ by @rom1v
https://guiscrcpy.srev.in
GNU General Public License v3.0
2.83k stars 211 forks source link

[BUG] Crash On Manjaro #354

Open neurodiverseEsoteric opened 1 year ago

neurodiverseEsoteric commented 1 year ago

Describe the bug A clear and concise description of what the bug is.

Error: Unhandled exception

Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/guiscrcpy/ui/pyside2/main.py", line 31, in setupUi
    MainWindow.setSizePolicy(sizePolicy)
TypeError: arguments did not match any overloaded call:
  setSizePolicy(self, a0: QSizePolicy): argument 1 has unexpected type 'PySide2.QtWidgets.QSizePolicy'
  setSizePolicy(self, hor: QSizePolicy.Policy, ver: QSizePolicy.Policy): argument 1 has unexpected type 'PySide2.QtWidgets.QSizePolicy'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/guiscrcpy/cli.py", line 157, in cli
    bootstrap(
  File "/usr/lib/python3.10/site-packages/guiscrcpy/launcher.py", line 1287, in bootstrap
    guiscrcpy = InterfaceGuiscrcpy(
  File "/usr/lib/python3.10/site-packages/guiscrcpy/launcher.py", line 111, in __init__
    self.setupUi(self)
  File "/usr/lib/python3.10/site-packages/guiscrcpy/ui/pyside2/main.py", line 33, in setupUi
    MainWindow.setSizePolicy(QSizePolicy.MinimumExpanding, QSizePolicy.MinimumExpanding)
TypeError: arguments did not match any overloaded call:
  setSizePolicy(self, a0: QSizePolicy): argument 1 has unexpected type 'PySide2.QtWidgets.QSizePolicy.Policy'
  setSizePolicy(self, hor: QSizePolicy.Policy, ver: QSizePolicy.Policy): argument 1 has unexpected type 'PySide2.QtWidgets.QSizePolicy.Policy'

To Reproduce Steps to reproduce the behavior:

  1. Go to '...' -Start Menu
  2. Click on '....' -Favorites Tab
  3. Scroll down to '....' -guiscrcpy
  4. See error -after clicking on guiscrcpy app launcher

Expected behavior quiscrcpy launches as it always used to do

Screenshots If applicable, add screenshots to help explain your problem. (Also remove the unnecessary geometry restrictions; I had to do so manually using a KWin rule in order to see the entire lines of the traceback... Screenshot_20230110_135053

Desktop (please complete the following information):

Additional context Add any other context about the problem here.

yochananmarqos commented 1 year ago

You need to run this command to launch it from the terminal:

env QT_API=pyside2 guiscrcpy

That same command is launched when using the menu shortcut.

ivanhercaz commented 10 months ago

Same report here with Manjaro:

OS: Manjaro Linux x86_64 
Host: 81Y4 IdeaPad Gaming 3 15IMH05 
Kernel: 6.5.5-1-MANJARO 
Uptime: 5 hours, 40 mins 
Packages: 2229 (pacman), 46 (nix-user), 13 (flatpak), 5 (snap) 
Shell: bash 5.1.16 
Resolution: 1920x1080, 1920x1080 
WM: i3 
Theme: Matcha-dark-azul [GTK3] 
Icons: Adwaita [GTK3] 
Terminal: kitty 
CPU: Intel i7-10750H (12) @ 5.000GHz 
GPU: NVIDIA GeForce GTX 1650 Mobile / Max-Q 
GPU: Intel CometLake-H GT2 [UHD Graphics] 
Memory: 9036MiB / 15862MiB

And guiscrcpy:

guiscrcpy vv2023.1.1

== PyQt5 Version ==
PYQT_VERSION = 331529
PYQT_VERSION_STR = 5.15.9
QOpenGLVersionProfile = <class 'PyQt5.QtGui.QOpenGLVersionProfile'>
QOperatingSystemVersion = <class 'PyQt5.QtCore.QOperatingSystemVersion'>
QT_VERSION = 331528
QT_VERSION_STR = 5.15.8
QVersionNumber = <class 'PyQt5.QtCore.QVersionNumber'>

== CairoSVG version ==
CairoSVG == 2.7.0

As indicates @yochananmarqos (thank you!), it is solved using env QT_API=pyside2 guiscrcpy as the menu shortcut (same with Rofi in run mode as it is like running in the terminal).