end-4 / dots-hyprland

i hate minimalism so...
https://end-4.github.io/dots-hyprland-wiki/en/
GNU General Public License v3.0
3.71k stars 255 forks source link

Colorscheme bug #345

Closed aleandro6804 closed 5 months ago

aleandro6804 commented 5 months ago

https://github.com/end-4/dots-hyprland/assets/79479582/31dd77ca-f949-4018-a92c-af0c8811eeb4

(the background is bugged because of OBS)

Also, the only way to "fix" this is to run the installation script again.

I tried looking into the files (even if i know 0 about css and style formats) and i think i found what could be the problem: in the ~/.config/hypr/hyprland/colors.conf all the colors are not expressed in RGB but with rgba( {{ $name }}FF ); so there was a problem in applying colors in the file.

I looked in the ~/.config/ags/scripts/color_generation/ and tried to run "applycolor.sh" but i got an error saying "Theme parsing error: gtk.css:97:41: Expected a valid selector" (whole error below).

Due to my lack of knowledge i had to stop here, can anybody help me?

output of applycolors.sh ```plain 20 │ $t_surface: transparentize($surface, $transparentize_surface_amount); │ ^^^^^^^^ ╵ scss/_colors.scss 20:28 @import scss/main.scss 9:9 root stylesheet (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:5753): Gtk-WARNING **: 23:14:48.535: Theme parsing error: gtk.css:122:58: Expected a valid selector [Gradience] INFO: Preset Material3_Generated applied successfully for Gtk 3 and Gtk 4 applications. [Gradience] INFO: In order for changes to take full effect, you need to log out. ```
clsty commented 5 months ago

Just in case, are you using multi-monitors?

I actually had same problem as you and I tried to fix it in #332 , but it's not worky again after 0f5cca7797ab5417702bd804a0fd2d77f6b25ddc . I'm using multi-monitor.

update: Oh, I just tested again and now its worky.

aleandro6804 commented 5 months ago

Nope, only one

end-4 commented 5 months ago

Does switching again fix it? Does using a different wallpaper help? Can you check if ~/.config/ags/scss/_material.scss has variables n stuff?

aleandro6804 commented 5 months ago

Neither switching again nor changing wallpaper fix the problem. I saw that file and after a "fresh install" it's normal, when i change the theme it gets empty (the only entries are darkmode and transparent)

midn8hustlr commented 5 months ago
~/.config/ags/scripts/color_generation/colorgen.sh "${imgpath}" --apply --smart

Can you run this script and log the outputs. Also there is a file generated after this script

~/.cache/ags/user/colorbackend.txt
~/.cache/ags/user/colormode.txt

Can you post the contents of these files?

catmeowjiao commented 5 months ago

my output(i also have this problem):

Click to expand ```Traceback (most recent call last): File "/home/meow/.config/ags/scripts/color_generation/generate_colors_material.py", line 9, in from materialyoucolor.hct import Hct ModuleNotFoundError: No module named 'materialyoucolor' ➜ ~ Error: Undefined variable. ╷ 10 │ @if $darkmode == True { │ ^^^^^^^^^ ╵ scss/_colors.scss 10:5 @import scss/main.scss 9:9 root stylesheet (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.433: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.433: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.433: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.433: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.433: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:6612): Gtk-WARNING **: 21:39:26.434: Theme parsing error: gtk.css:122:58: Expected a valid selector undefined (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:6631): Gtk-WARNING **: 21:39:26.572: Theme parsing error: gtk.css:122:58: Expected a valid selector Gtk.CssProviderError: style.css:9:5Invalid name of pseudo-class [Gradience] INFO: Preset Material3_Generated applied successfully for Gtk 3 and Gtk 4 applications. [Gradience] INFO: In order for changes to take full effect, you need to log out. ```

colorbackend.txt:

material

colormode.txt

dark
opaque
vibrant
catmeowjiao commented 5 months ago

@end-4 @clsty @midn8hustlr

aleandro6804 commented 5 months ago

I can't run EXACTLY that script because it gaves me an error saying that i can't use the brackets{}

$  ~/.config/ags/scripts/color_generation/colorgen.sh "${imgpath}" --apply --smart

fish: Variables cannot be bracketed. In fish, please use "$imgpath".
~/.config/ags/scripts/color_generation/colorgen.sh "${imgpath}" --apply --smart
                                                     ^

Using the command without brackets, i get this:

Click to expand ``` $ ~/.config/ags/scripts/color_generation/colorgen.sh "$imgpath" --apply --smart Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/PIL/Image.py", line 3251, in open fp.seek(0) ^^^^^^^ AttributeError: 'str' object has no attribute 'seek' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/aleandro/.config/ags/scripts/color_generation/generate_colors_material.py", line 50, in img = Image.open(args.path) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/PIL/Image.py", line 3253, in open fp = io.BytesIO(fp.read()) ^^^^^^^ AttributeError: 'str' object has no attribute 'read'  105ms ••    (!!!! these symbols are the terminal GUI, it "ends" the command and instantly later i get other errors with no input asked) •  Error: Undefined variable. ╷ 20 │ $t_surface: transparentize($surface, $transparentize_surface_amount); │ ^^^^^^^^ ╵ scss/_colors.scss 20:28 @import scss/main.scss 9:9 root stylesheet (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:7510): Gtk-WARNING **: 14:39:24.559: Theme parsing error: gtk.css:122:58: Expected a valid selector undefined [Gradience] INFO: Preset Material3_Generated applied successfully for Gtk 3 and Gtk 4 applications. [Gradience] INFO: In order for changes to take full effect, you need to log out. (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:7527): Gtk-WARNING **: 14:39:24.649: Theme parsing error: gtk.css:122:58: Expected a valid selector ```

Also, the contents of the two file you said are:

colorbackend.txt: material

colormode.txt: light opaque monochorme

clsty commented 5 months ago

@aleandro6804 You need to re-run the same command under bash, not fish.

Type bash to run bash first, then run that command.

@end-4 And I actually worried about this... Personally I will not recommend fish for beginners. Or maybe we need some warning message somewhere.

catmeowjiao commented 5 months ago

@aleandro6804 You need to re-run the same command under bash, not fish.

Type bash to run bash first, then run that command.

yes

catmeowjiao commented 5 months ago

if you have this problem,please re-install to use default colorscheme.

aleandro6804 commented 5 months ago

Oh, i'm sorry.

Results from bash:

Click to expand ``` ~/.config/ags/scripts/color_generation/colorgen.sh "${imgpath}" --apply --smart Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/PIL/Image.py", line 3251, in open fp.seek(0) ^^^^^^^ AttributeError: 'str' object has no attribute 'seek' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/aleandro/.config/ags/scripts/color_generation/generate_colors_material.py", line 50, in img = Image.open(args.path) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/PIL/Image.py", line 3253, in open fp = io.BytesIO(fp.read()) ^^^^^^^ AttributeError: 'str' object has no attribute 'read' [aleandro@archlinux ~]$ Error: Undefined variable. ╷ 20 │ $t_surface: transparentize($surface, $transparentize_surface_amount); │ ^^^^^^^^ ╵ scss/_colors.scss 20:28 @import scss/main.scss 9:9 root stylesheet (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:2956): Gtk-WARNING **: 14:58:02.836: Theme parsing error: gtk.css:122:58: Expected a valid selector undefined [Gradience] INFO: Preset Material3_Generated applied successfully for Gtk 3 and Gtk 4 applications. [Gradience] INFO: In order for changes to take full effect, you need to log out. (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:95:30: '' is not a valid color name (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:95:44: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:96:46: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:97:41: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:98:47: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:99:49: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:100:44: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:105:41: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:106:43: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:107:47: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:108:49: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:109:42: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:110:44: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:112:60: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:113:62: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:116:45: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:117:55: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:119:55: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:120:57: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:121:56: Expected a valid selector (com.github.Aylur.ags:2983): Gtk-WARNING **: 14:58:02.933: Theme parsing error: gtk.css:122:58: Expected a valid selector (com.github.Aylur.ags:2547): Gjs-Console-CRITICAL **: 14:58:02.957: CSS ERROR: Invalid name of pseudo-class at line 8 in /home/aleandro/.cache/ags/user/generated/style.css Gtk.CssProviderError: style.css:9:5Invalid name of pseudo-class ^C ```

colorbackend.txt: material

colormode.txt: light opaque monochorme

midn8hustlr commented 5 months ago

hey sorry I forgot to mention this put any image path in your system instead of "${imgpath}" And run the following two commands

~/.config/ags/scripts/color_generation/colorgen.sh ~/walls/interior/image.jpg --apply --smart
~/.config/ags/scripts/color_generation/generate_colors_material.py --path ~/walls/interior/image.jpg --cache '.cache/ags/user/color.txt'

Replace image with your image put the logs and the contents of ~/.cache/ags/user/color.txt also

aleandro6804 commented 5 months ago

Ok, something happened.

with the first command:

[aleandro@archlinux ~]$ ~/.config/ags/scripts/color_generation/colorgen.sh /home/aleandro/Downloads/image-test.jpg --apply --smart
[aleandro@archlinux ~]$ undefined
undefined
[Gradience] INFO: Preset Material3_Generated applied successfully for Gtk 3 and Gtk 4 applications.
[Gradience] INFO: In order for changes to take full effect, you need to log out.

After this, everything works (it applied the colors and i can change the colorscheme)

with the second one:

Click to expand ``` [aleandro@archlinux ~]$ ~/.config/ags/scripts/color_generation/generate_colors_material.py --path /home/aleandro/Downloads/image-test.jpg --cache '.cache/ags/user/color.txt' $darkmode: True; $transparent: False; $primary_paletteKeyColor: #B3FE00; $secondary_paletteKeyColor: #667E5B; $tertiary_paletteKeyColor: #52825C; $neutral_paletteKeyColor: #747969; $neutral_variant_paletteKeyColor: #767C68; $background: #111509; $onBackground: #E1E5D1; $surface: #111509; $surfaceDim: #111509; $surfaceBright: #363B2D; $surfaceContainerLowest: #FFFFFF; $surfaceContainerLow: #191D11; $surfaceContainer: #1D2115; $surfaceContainerHigh: #272C1F; $surfaceContainerHighest: #323629; $onSurface: #E1E5D1; $surfaceVariant: #434937; $onSurfaceVariant: #C3C9B2; $inverseSurface: #E1E5D1; $inverseOnSurface: #2E3225; $outline: #8D937E; $outlineVariant: #434937; $shadow: #000000; $scrim: #000000; $surfaceTint: #99DA00; $primary: #99DA00; $onPrimary: #233600; $primaryContainer: #354E00; $onPrimaryContainer: #AFF800; $inversePrimary: #476800; $secondary: #B4CEA5; $onSecondary: #203619; $secondaryContainer: #364D2D; $onSecondaryContainer: #CFEBC0; $tertiary: #9FD3A7; $onTertiary: #05391A; $tertiaryContainer: #6B9C74; $onTertiaryContainer: #000000; $error: #FFB4AB; $onError: #690005; $errorContainer: #93000A; $onErrorContainer: #FFDAD6; $primaryFixed: #AFF800; $primaryFixedDim: #99DA00; $onPrimaryFixed: #131F00; $onPrimaryFixedVariant: #354E00; $secondaryFixed: #CFEBC0; $secondaryFixedDim: #B4CEA5; $onSecondaryFixed: #0C2006; $onSecondaryFixedVariant: #364D2D; $tertiaryFixed: #BBEFC2; $tertiaryFixedDim: #9FD3A7; $onTertiaryFixed: #00210C; $onTertiaryFixedVariant: #21502F; ```

In ~/.cache/ags/user/color.txt also the content is: #83a548

midn8hustlr commented 5 months ago

I don't see any issues with your outputs It should have worked with the colorscheme widget itself (if switching scheme for the first time and then switching dark mode couple of times fixes the problem) Never mind, if its working its good @catmeowjiao please install aur package as recommended by clsty

yay -Syu python-materialyoucolor-git
clsty commented 5 months ago

@catmeowjiao You don't need to @ all of us because end-4 and I are devs and we already subscribed (watched) this repo, so we sure will see it. Though your problem seems to be missing materialyoucolor. Have you installed the AUR package python-materialyoucolor-git?

aleandro6804 commented 5 months ago

i have one question: for what i understood, the script takes an image in input and creates colorschemes based on the image's colors.

I noticed that, on another laptop, when i change the background image, also the colorschemes available changes (so i assume it automatically recognize the background image and uses it).

I tried now (on the bugged pc) to change the background but the colorschemes available are the same as before (the image-test.jpg).

There is a way to fix this?

P.S. Thanks for all the help you gave me <3

midn8hustlr commented 5 months ago

If you are switching wallpaper via the cheetsheet (SUPER + /) command (Change wallpaper+colorscheme) then the colorscheme should change automatically, atleast that's whats the intended behavior is You can check if the hex value in ~/.cache/ags/user/color.txt is changing with switching the wallpaper This file contains the color extracted from the wallpaper

aleandro6804 commented 5 months ago

Oh thank you very much <3 @catmeowjiao have you solved? can i close this?

catmeowjiao commented 5 months ago

i have an error when install python-materialyoucolor-git

* Getting build dependencies for wheel...
Downloading required files...
Traceback (most recent call last):
  File "/usr/lib/python3.11/urllib/request.py", line 1348, in do_open
    h.request(req.get_method(), req.selector, req.data, headers,
  File "/usr/lib/python3.11/http/client.py", line 1298, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "/usr/lib/python3.11/http/client.py", line 1344, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "/usr/lib/python3.11/http/client.py", line 1293, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/lib/python3.11/http/client.py", line 1052, in _send_output
    self.send(msg)
  File "/usr/lib/python3.11/http/client.py", line 990, in send
    self.connect()
  File "/usr/lib/python3.11/http/client.py", line 1463, in connect
    super().connect()
  File "/usr/lib/python3.11/http/client.py", line 956, in connect
    self.sock = self._create_connection(
                ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/socket.py", line 851, in create_connection
    raise exceptions[0]
  File "/usr/lib/python3.11/socket.py", line 836, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
    main()
  File "/usr/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
    json_out['return_val'] = hook(**hook_input['kwargs'])
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
    return hook(config_settings)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 325, in get_requires_for_build_wheel
    return self._get_build_requires(config_settings, requirements=['wheel'])
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 295, in _get_build_requires
    self.run_setup()
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 480, in run_setup
    super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
    exec(code, locals())
  File "<string>", line 554, in <module>
  File "/usr/lib/python3.11/urllib/request.py", line 216, in urlopen
    return opener.open(url, data, timeout)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/urllib/request.py", line 519, in open
    response = self._open(req, data)
               ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/urllib/request.py", line 536, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/urllib/request.py", line 496, in _call_chain
    result = func(*args)
             ^^^^^^^^^^^
  File "/usr/lib/python3.11/urllib/request.py", line 1391, in https_open
    return self.do_open(http.client.HTTPSConnection, req,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/urllib/request.py", line 1351, in do_open
    raise URLError(err)
urllib.error.URLError: <urlopen error [Errno 111] Connection refused>

ERROR Backend subprocess exited when trying to invoke get_requires_for_build_wheel
catmeowjiao commented 5 months ago

Oh, this error is due to the website being intercepted by Great Firewall. I previously removed the proxy setting in/etc/environment to fix a bug in the color scheme, and now it can work.

aleandro6804 commented 5 months ago

Perfect, closing