Open bphd opened 2 years ago
Thank you for filing the issue, the AUR package is not maintained by me and some people have issues setting up cassowary without the instructions presented in GitHub !
The connection should not have begun if no IP address was configured and i will look into the issue. For the layout issue, can be please share the version of PyQt installed on your system. And also share the log files if they have been created !
python-pyqt6 6.3.1-1 python-pyqt5 5.15.7-1 python-qtpy 2.1.0-1
I don't know if Cassowary produces log files I don't find any unit or user-unit related to Cassowary
Though by grepping cassowary in journals, I get that
cassowary_linux_bg_service.desktop[]: client_.init_connection()
cassowary_linux_bg_service.desktop[]: [] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> disabled
cassowary_linux_bg_service.desktop[]: [] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> Refreshing config to update to probable config changes !
cassowary_linux_bg_service.desktop[]: [] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> VM watcher active !
cassowary_linux_bg_service.desktop[]: [] | [ ERROR ] : [ __init__ -> start_bg_client ] --> Ignored exception: 'Traceback (most recent call last):
cassowary_linux_bg_service.desktop[]: File "/usr/lib/python3.10/site-packages/cassowary/client.py", line 50, in init_connection
cassowary_linux_bg_service.desktop[]: File "/usr/lib/python3.10/site-packages/cassowary/__init__.py", line 31, in start_bg_client
cassowary_linux_bg_service.desktop[]: [] | [ INFO ] : [ client -> init_connection ] --> Attempting to connect to server
cassowary_linux_bg_service.desktop[]: [] | [ INFO ] : [ __init__ -> start_bg_client ] --> Connecting to server....
cassowary_linux_bg_service.desktop[]: OSError: [Errno 113] No route to host
cassowary_linux_bg_service.desktop[]: ', reconnecting to server after 5 seconds
cassowary_linux_bg_service.desktop[]: self.server.connect((self.__host, self.__port))
plasmashell[]: kf.kio.core: Url QUrl("file:///home//.local/share/applications/cassowary_linux.desktop") already represents a local file, cancelling job.
python[]: File "/usr/lib/python3.10/site-packages/cassowary/client.py", line 50, in init_connection
python[]: File "/usr/lib/python3.10/site-packages/cassowary/__init__.py", line 31, in start_bg_client
sudo[]: : TTY= ; PWD=/home/ ; USER=root ; COMMAND=/usr/bin/chattr +a /usr/lib/python3.10/site-packages/cassowary/client.py
sudo[]: : TTY= ; PWD=/home/ ; USER=root ; COMMAND=/usr/bin/chattr -a /usr/lib/python3.10/site-packages/cassowary/client.py
sudo[]: : TTY= ; PWD=/home/ ; USER=root ; COMMAND=/usr/bin/cp /usr/lib/python3.10/site-packages/cassowary/client.py /usr/lib/python3.10/site-packages/cassowary/client.py.bak
sudo[]: : TTY= ; PWD=/home/ ; USER=root ; COMMAND=/usr/bin/vim /usr/lib/python3.10/site-packages/cassowary/client.py
systemd[]: app-cassowary_linux-.scope: Consumed 19min 13.417s CPU time.
systemd[]: app-cassowary_linux-.scope: Consumed .s CPU time.
systemd[]: Started Cassowary Background Service.
systemd[]: Started Cassowary Linux - cassowary.
systemd[]: Starting Cassowary Background Service...
systemd[]: Stopped Cassowary Background Service.
systemd[]: Stopping Cassowary Background Service...
systemd-xdg-autostart-generator[]: Configuration file /home//.config/autostart/cassowary_linux_bg_service.desktop is marked executable. Please remove executable permission bits. Proceeding anyway.
systemd-xdg-autostart-generator[]: /home//.config/autostart/cassowary_linux_bg_service.desktop:12: Unknown key name 'TerminalOptions' in section 'Desktop Entry', ignoring.
The chattr
was after changing the timeouts for them to not be touched
python-pyqt6 6.3.1-1 python-pyqt5 5.15.7-1 python-qtpy 2.1.0-1
I don't know if Cassowary produces log files I don't find any unit or user-unit related to Cassowary
Log file should be at /home/$USER/.config/casualrdh/
on linux
and
%userprofile%/.config/casualrdh/
on windows system
The contents of this logfile
client_.init_connection()
ConnectionResetError: [Errno 104] Connection reset by peer
[] | [ DEBUG ] : [ client -> init_connection ] --> Starting sender and receiver threads
[] | [ DEBUG ] : [ client -> __receive ] --> Stopping receive sub-threadd... (True)
[] | [ DEBUG ] : [ client -> __send ] --> Sending message to server
[] | [ DEBUG ] : [ client -> __send ] --> Stopping send sub-thread.d... (True)
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> An app was already opened, the black window should not appear now !
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> App window seems to be created or timeout. Creating marker & Waiting 2 seconds - .
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> Created a marker -> One session done
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> Opening & closing a test window to trigger login or try to fix black screen bug on first launch
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> Test window opened and closed !
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> Trying to fix black window bug by opening a test window before requested application - .CMDLINE: xfreerdp /d:"" /u:"" /p:"Edit It Yourself" /v:"192.168.1.1" +clipboard /a:drive,root,/ +decorations /cert-ignore /sound /scale:100 /dynamic-resolution /span /wm-class:"cassowaryApp-echo" /app:"ipconfig.exe"
[] | [ DEBUG ] : [ helper -> fix_black_window ] --> Trying to fix black window bug by opening a test window before requested application - .CMDLINE: xfreerdp /d:"" /u:"" /p:"" /v:"" +clipboard /a:drive,root,/ +decorations /cert-ignore /sound /scale:100 /dynamic-resolution /span /wm-class:"cassowaryApp-echo" /app:"ipconfig.exe"
[] | [ DEBUG ] : [ helper -> full_rdp ] --> Creating a full RDP session with commandline : {rdc} /d:"{domain}" /u:"{user}" /p:"{passd}" /v:{ip} /a:drive,root,{share_root} +auto-reconnect +clipboard /cert-ignore /audio-mode:1 /scale:{scale} /wm-class:"cassowaryApp-FULLSESSION" /dynamic-resolution /{mflag} {rdflag} 1> /dev/null 2>&1 &
[] | [ DEBUG ] : [ helper -> full_rdp ] --> Full RDP session ended !
[] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> disabled
[] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> Refreshing config to update to probable config changes !
[] | [ DEBUG ] : [ helper -> vm_suspension_handler ] --> VM watcher active !
[] | [ DEBUG ] : [ helper -> vm_wake ] --> Attempting to resume VM
[] | [ DEBUG ] : [ helper -> vm_wake ] --> VM name is blank, maybe not a vm skipping vm resume process !
[] | [ DEBUG ] : [ __init__ -> main ] --> Starting configuration GUI
[] | [ DEBUG ] : [ main_ui -> __reconnect ] --> Forced reconnection attempt, no active application or explicitly forced
dom = conn.lookupByName(cfgvars.config["vm_name"])
dom = conn.lookupByName(name)
[] | [ ERROR ] : [ client -> __receive ] --> Error receiving messages, Exception- [Errno 104] Connection reset by peer, Traceback : Traceback (most recent call last):
[] | [ ERROR ] : [ helper -> ip_by_vm_name ] --> Cannot get ip for '' -> Traceback (most recent call last):
[] | [ ERROR ] : [ helper -> vm_wake ] --> Could not suspend vm '' -> Traceback (most recent call last):
[] | [ ERROR ] : [ __init__ -> start_bg_client ] --> Ignored exception: 'Traceback (most recent call last):
File "/usr/lib/python3.10/site-packages/cassowary/base/helper.py", line 35, in ip_by_vm_name
File "/usr/lib/python3.10/site-packages/cassowary/base/helper.py", line 392, in vm_wake
File "/usr/lib/python3.10/site-packages/cassowary/client.py", line 50, in init_connection
File "/usr/lib/python3.10/site-packages/cassowary/client.py", line 68, in __receive
File "/usr/lib/python3.10/site-packages/cassowary/__init__.py", line 31, in start_bg_client
File "/usr/lib/python3.10/site-packages/libvirt.py", line 4942, in lookupByName
[] | [ INFO ] : [ client -> init_connection ] --> Attempting to connect to server
[] | [ INFO ] : [ client -> init_connection ] --> Connected to server at :7220
[] | [ INFO ] : [ __init__ -> start_bg_client ] --> Connecting to server....
libvirt.libvirtError: Domain not found: no domain with matching name ''
OSError: [Errno 113] No route to host
raise libvirtError('virDomainLookupByName() failed')
recent_msg = self.server.recv(16000)
', reconnecting to server after 5 seconds
self.server.connect((self.__host, self.__port))
[] | [ WARNING ] : [ helper -> ip_by_vm_name ] --> Could not get proper ip address for domain ''
Can you also share logfile in windows system, the windows component seems to be refusing connection !
Also a output of netstat
command in windows would be helpful !
Logs of the guest
[] | [ DEBUG ] : [ cmd_dirs -> __get_shared_drives ] --> Getting shared local drives using net share
[] | [ DEBUG ] : [ cmd_dirs -> __init__ ] --> Looks like this is not a RDP session, share for root folder not found
[] | [ DEBUG ] : [ server -> __init__ ] --> [ClientID:\] New client connected
[] | [ DEBUG ] : [ server -> __receive ] --> [ClientID:\] Receiver is exiting
[] | [ DEBUG ] : [ server -> __send ] --> [ClientID:\] Got message in queue. MSG_ID:
[] | [ DEBUG ] : [ server -> __send ] --> [ClientID:\] Sender is exiting
[] | [ DEBUG ] : [ server -> start_server ] --> Client Thread '' has stopped listening, removing it
[] | [ ERROR ] : [ server -> __receive ] --> [ClientID:\] Received a deformed message. Message body : 'b'{"id": "", "type": "request", "command": ["get-drive-shares"]}~~!enm!~~{"id": "", "type": "request", "command": ["get-installed-apps"]}~~!enm!~~'', Traceback : Traceback (most recent call last):
File "json\decoder.py", line 340, in decode
File "json\__init__.py", line 348, in loads
File "server.py", line 115, in __receive
[] | [ INFO ] : [ server -> __receive ] --> [ClientID:\] Received a request : MSG_ID:
[] | [ INFO ] : [ server -> __receive ] --> [ClientID:\] Request handled by : dircommands
[] | [ INFO ] : [ server -> __receive ] --> [ClientID:\] Request handled by : generalcommands
[] | [ INFO ] : [ server -> __send ] --> [ClientID:\] Sent message to client. MSG_ID:
json.decoder.JSONDecodeError: Extra data: line 1 column 67 (char 66)
netstat
Active Connections
Proto Local Address Foreign Address State
TCP $IP1:49689 $IP2:https ESTABLISHED
TCP $IP1:49908 $IP3:https ESTABLISHED
And it's worse when widened
To reproduce, you just have to
cassowary -a
And besides, it's totally not intuitive if you begin your journey by installing from AUR. No instructions at all. I've went to the manual and found something talking about GUI. I said why not. Then I was stuck in a window telling me that a connection to an IP was timed out, considering that I still haven't configured anything, it's kind of weird. At least if both this message and the configuration panel can be openend at the same time, it would have been less confusing
=> 1. Make the GUI more "user friendly" by telling something more significant at opening than a prompt asking you to aknowledge the state of connection to a server. Maybe a pop up explaining rapidly what to do.
=> 2. Do not require closing of this prompt to open the main GUI. Because the user don't understand why nothing happens and can be stuck from here
=> 3. Add in the manual instructions to setup Cassowary
Describe the bug A Description of what the bug is.
To Reproduce Steps to reproduce the behavior:
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
System information:
python3 -m cassowary -h
to find version ]"C:\Program Files\cassowary\cassowary.exe" -h
to find version]Additional context Add any other context about the problem here.