-
Notifications
You must be signed in to change notification settings - Fork 17
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
After updating it via AUR #48
Comments
if i am using |
I am getting a similar error when trying to install with yay on artix `> Generate a colorscheme. ... Generating a colorscheme.
======================================================================
Traceback (most recent call last): ======================================================================
Traceback (most recent call last): Ran 31 tests in 0.086s FAILED (errors=2) |
Same issue here , but I did not install it with the AUR , I used the pipx command to install pywal16 . It's exactly the same error . I also had to copy the wal file in the sbin directory . |
@eylles check this issue once |
So weird, according to that the regular expression search What is the output of running I know arch should be on imagemagick 7 but no idea if it does already ship with the new policy to not allow writing to std out. To change the policy run: If that does nothing i'll work on this tomorrow, but it won't be an easy matter since i'm on devuan testing and need to do upgrade packages next month. |
Changing policy didn't help! |
I see... welp, will have to look if something changed on the latest python version shipped on arch, or write a new regex search. |
Dumb question, does this also happen with dylan's pywal? be it 3.3.0 or pywal-git? That way at least i'd know if it was sonething i changed or is something that pywal has been dragging for years waiting to implode. |
Just tried it and those 2 do not give an error when installing |
@CapybaraWarrior do either of those give the runtime error with the traceback to:
|
You mean python-pywal and pywal-git? They install fine with yay and work without any error. Sorry, I should have said that they install and work without error instead of just that they install. |
Just for completeness sake, you installed either python-pywal or pywal-git from the aur, ran It is very important as there have been 7 changes to backends/wal.py since pywal's 3.3.0 to pywal16's 3.5.3, and since this is an arch specific (it seems, as no other distro has suffered from this yet) it helps to know at which commit does it begin to happen. And no, i don't mean the aur install bug, that is something that should be reported to the aur maintainer, i mean the runtime traceback error as that is also reported by users instally the pypi package. |
I tried it again with the options you mentioned and python-pywal gave no errors when I gave it an image and it worked, -v said 3.3.0 and then I ran -c and removed python-pywal and installed pywal-git. For python-git -v said 3.3.1 but it worked as well and there was this: But otherwise no diffreence |
Great, that DOES help a lot, just as a question, you can do clone the repo and do a For now while i prepare the branch anyone willing to help please install pipx from your package manager and make sure you uninstalled both pywal and pywal16. |
So after testing some releases and installing them with pipx, all work and give no error when producing 9 colors but when I used --cols16 on version 3.5.3 I got this: raceback (most recent call last): |
Using version 3.5.2 works perfectly after installing with pipx |
Thanks, now at least i know it was a change in 3.5.3 that caused this, give me some mins and i will have a branch to test. |
Hotfix if anyone wants it: in |
okay, before merging anything to master i need to know that this branch fixes the issue https://github.com/eylles/pywal16/tree/arch-fix i think the correct command with pipx is |
nice, to speak about the solution. def try_gen_in_range(img, magick_command):
for i in range(0, 20, 1):
raw_colors = imagemagick(16 + i, img, magick_command)
if len(raw_colors) > 16:
break
if i == 19:
logging.error("Imagemagick couldn't generate a suitable palette.")
sys.exit(1)
else:
logging.warning("Imagemagick couldn't generate a palette.")
logging.warning("Trying a larger palette size %s", 16 + i)
return raw_colors
def gen_colors(img):
"""Format the output from imagemagick into a list
of hex colors."""
magick_command = has_im()
raw_colors = try_gen_in_range(img, magick_command)
try:
out = [re.search("#.{6}", str(col)).group(0) for col in raw_colors[1:]]
except AttributeError:
if magick_command == ["magick", "convert"]:
logging.warning("magick convert failed, using only magick")
magick_command = ["magick"]
raw_colors = try_gen_in_range(img, magick_command)
out = [re.search("#.{6}",
str(col)).group(0) for col in raw_colors[1:]]
return out had to move the generation of colors in a for loop for continuous large palettes into it's own function. used a try except to catch the attribute error from the regex to then try the magick command without the "convert" part. the idea is this won't affect distros that do got imagemagick 7 but is an older version than what arch ships so it will just work on those. |
Does aur have any |
as everyone can see, i marked everything else as a milestone for 3.6.0 and released 3.5.4, please feel free to flood the aur maintainer for the latest release version. if anyone wonders, yes constant email spam and flood is one of the reasons dylan's email is still the one publically associated with pywal16, but the main reason is i am lazy. |
The text was updated successfully, but these errors were encountered: