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

I suppress sema-duplicated-attrname, but this doesn't disable the recoloring #619

Closed
stereomato opened this issue Nov 17, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@stereomato
Copy link

Describe the bug
See title. I expect suppressing that to also disable the recoloring of text.

Logs (Required)

E[13:41:30.728] 22081: nixos eval expr: -32001: attribute '�[35;1mservices.xserver.desktopManager.gnome.enable�[0m' already defined at �[35;1m/nix/store/xy5mc6jlsqd3m2zdhkx90j9h7zw51xnb-source/machines/common/desktop-environment.nix:47:2�[0m
I[13:41:30.763] 22081: <-- reply(3)
I[13:41:30.763] 22081: --> notify $/progress
E[13:41:30.763] 22081: nixos eval expr: -32001: attribute '�[35;1mservices.xserver.desktopManager.gnome.enable�[0m' already defined at �[35;1m/nix/store/xy5mc6jlsqd3m2zdhkx90j9h7zw51xnb-source/machines/common/desktop-environment.nix:47:2�[0m
I[13:41:30.946] 22081: <-- textDocument/didOpen

Configuration

"nixd": {
            "formatting": {
                // This is the default if ommited.
                "command": [ "nixfmt" ]
            },
            "options": {
                // By default, this entriy will be read from `import <nixpkgs> { }`
                // You can write arbitary nix expression here, to produce valid "options" declaration result.
                // Tip: for flake-based configuration, utilize `builtins.getFlake`
                "nixos": {
                    "expr": "(builtins.getFlake \"/home/stereomato/Documents/Software Development/Repositories/Personal/nixos-setup\").nixosConfigurations.Taihou.options"
                },
                //"home-manager": {
                //    "expr": "(builtins.getFlake \"/home/stereomato/Documents/Software Development/Repositories/Personal/nixos-setup\").homeConfigurations.\"stereomato@Taihou\".options"
                //}
            },
            "diagnostic": {
                "suppress": [
                    "sema-duplicated-attrname"
                ]
            }
        },

To Reproduce

services = {};
services = {};

That¿s enough to trigger the behavior. The 2nd services isn't the same color as the first, instead being red.

Expected behavior
The color is not changed when sema-duplicated-attrname is supressed

Screenshots
image

Additional context
I just switched to nixd and I like what I see!

@stereomato stereomato added the bug Something isn't working label Nov 17, 2024
@inclyc
Copy link
Member

inclyc commented Nov 17, 2024

Coloring stuff is fixed in 2.5.1.
See #616

You can export

NIXD_FLAGS=--semantic-tokens=false

to workaround it.

@inclyc inclyc closed this as completed Nov 17, 2024
@stereomato
Copy link
Author

oof, didn't see. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants