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

Unminimize doesnt work u_u i think is for a pyhton update #4

Open
edenac opened this issue Jul 23, 2022 · 7 comments
Open

Unminimize doesnt work u_u i think is for a pyhton update #4

edenac opened this issue Jul 23, 2022 · 7 comments

Comments

@edenac
Copy link

edenac commented Jul 23, 2022

➜ Qminimize -u
Traceback (most recent call last):
File "/usr/bin/Qminimize", line 97, in
main()
File "/usr/bin/Qminimize", line 81, in main
window_class = get_wm_class()
File "/usr/bin/Qminimize", line 24, in get_wm_class
win = EWMH().getClientList()
File "/home/edenac/.local/lib/python3.10/site-packages/ewmh/ewmh.py", line 70, in init
self.display = _display or display.Display()
File "/home/edenac/.local/lib/python3.10/site-packages/Xlib/display.py", line 89, in init
self.display = _BaseDisplay(display)
File "/home/edenac/.local/lib/python3.10/site-packages/Xlib/display.py", line 71, in init
protocol_display.Display.init(self, *args, **keys)
File "/home/edenac/.local/lib/python3.10/site-packages/Xlib/protocol/display.py", line 166, in init
raise error.DisplayConnectionError(self.display_name, r.reason)
Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'Invalid MIT-MAGIC-COOKIE-1 key'

or u can give me a tip ? i love this feature :'c

@mchisolm0
Copy link

I also have a problem with unminimizing, though I just got Qminimize today and our errors seem to be different. If mine is unrelated, I can delete this comment.

➜ Qminimize -u
Traceback (most recent call last):
File "/home/mchisolm0/.local/bin/Qminimize", line 97, in
main()
File "/home/mchisolm0/.local/bin/Qminimize", line 84, in main
string = minimized_windows_list(minimized_icons)
File "/home/mchisolm0/.local/bin/Qminimize", line 69, in minimized_windows_list
string += "{} {}\0icon\x1f{}".format(c.window[i].info()["name"], str(c.window[i].info()["id"]), minimized_icons[cont])
IndexError: list index out of range

@StarTroop
Copy link

I've also had issues since the last commit (449f265). I've been using the older version in the meantime. I'm confused why we all are getting different errors with the current version:
Traceback (most recent call last): File "/home/alex/.local/bin/Qminimize", line 97, in <module> main() File "/home/alex/.local/bin/Qminimize", line 82, in main icons = parse_icons() File "/home/alex/.local/bin/Qminimize", line 39, in parse_icons config.read(file) File "/usr/lib/python3.10/configparser.py", line 698, in read self._read(fp, filename) File "/usr/lib/python3.10/configparser.py", line 1097, in _read raise DuplicateOptionError(sectname, optname, configparser.DuplicateOptionError: While reading from '/usr/share/applications/discord.desktop' [line 11]: option 'path' in section 'Desktop Entry' already exists

@mchisolm0
Copy link

@StarTroop, have you opened the discord.desktop file it mentions in the error? That looks like the first error I got, and the file had two 'path' entries at the bottom of the file. Not sure if this is right, but I deleted the duplicate line. Discord still runs fine and stopped getting the error when I try to minimize.

Now I only get the error when I try pulling up to unminimize.

@StarTroop
Copy link

StarTroop commented Jul 24, 2022

@mchisolm0 I'd rather not edit the desktop file directly because it's managed by my distro (actually, on Arch it's a symlink to the real file in /opt/discord), but making a local file to overwrite it doesn't help I suppose because Qminimize is checking /usr/share/applications specifically.
To remove it as a variable, I uninstalled Discord. Now the current version of Qminimize seems to be working, though I think a reload of the Qtile config was necessary to solve some quirk with already-minimised windows.
Does Qminimize not work for you at all? As in, Rofi fails to launch? I'm noticing now that running Qminimize -u through the terminal will output an error message only if Qminimize is closed without unminimising any windows, but otherwise it's working properly. The messages are of course invisible when using a keybind, so I think my issue is essentially resolved and unrelated to OP. Maybe I should create a new issue to request that user desktop entries be parsed to override the system entries.
Edit: Actually, behaviour still seems to be a bit quirky. I need to do some testing after my next reboot, but it seems that a reload of the Qtile config is necessary after any window is minimised for it to appear in the Rofi menu, but it seems to be inconsistent, perhaps on a per-workspace basis.

@edenac I suggest giving details about your system such as your distribution and versions of the required python modules.

@edenac
Copy link
Author

edenac commented Jul 26, 2022

for sure @StarTroop , actually im working on this specification

  • arcolinux - Kernel: 5.18.13-arch1-1
  • Qtile
  • WM: LG3D
  • python 3.10.5

but yes as i thought, i think that the issue is due to a python update because it was working good but i updated my system and it doesnt work since that. (minimize is working but unminimize nope as @mchisolm0 say)
I usually handle my workflow with super + f for toggle maximize that i want to use (i suggest you try this btw) but im curiously about Qminimize when i realized that it doesnt work anymore D:

  • my dotfile is on home/.config/qtile/config.py

this is my config for toggle maximize and unmaximize, it is to usefull and i recomendd it
Key([mod], "m", lazy.window.toggle_maximize(), desc="Toggle maximize"),

btw , when a i was looking for a solution i saw an old issue that dealt with the same thing, and they just said that was a known issue and they waited for the solution by qtile.
This is the issue 👇

thanks a lot for your help guys 😁
@mchisolm0 @StarTroop

@edenac edenac closed this as completed Jul 26, 2022
@edenac edenac reopened this Jul 26, 2022
@StarTroop
Copy link

How have you installed python? If you install it from Arch repos, the libraries shouldn't be in ~/.local. I'm not an expert in python, but perhaps you should try installing python, python-fuzzywuzzy, and python-ewmh with pacman and see if you still have the error.

@mchisolm0
Copy link

@StarTroop I, too, only had trouble with the unminimize. I am on Manjaro Linux (not at computer atm, so can’t give more details). Hmmm…I expect I would have installed those with pip or pip3. I don’t think I checked to see if pacman could get them. When I get back on, I may see if that can solve it.

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

3 participants