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

bug: vscode extensions, some extensions not installing, inconsistent #5372

Open
2 tasks done
j4t1nd3r opened this issue May 4, 2024 · 1 comment
Open
2 tasks done
Assignees
Labels
bug triage Issues or feature request that have not been triaged yet

Comments

@j4t1nd3r
Copy link

j4t1nd3r commented May 4, 2024

Are you following the right branch?

  • My Nixpkgs and Home Manager versions are in sync

Is there an existing issue for this?

  • I have searched the existing issues

Issue description

link to repo

flake.nix:

{
  description = "nixos flake config";

  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
    nixos-hardware.url = "github:NixOS/nixos-hardware/master";
    home-manager = {
      url = "github:nix-community/home-manager";
      inputs.nixpkgs.follows = "nixpkgs";
    };
    plasma-manager = {
      url = "github:pjones/plasma-manager";
      inputs = {
        home-manager.follows = "home-manager";
        nixpkgs.follows = "nixpkgs";
      };
    };
  };

  outputs = { self, nixpkgs, nixos-hardware, plasma-manager, ... }@inputs:
  let
    system = "x86-64-linux";

    pkgs = import nixpkgs {
      inherit system; 

      config = {
        allowUnfree = true;
      };
    };

    in
    {
    nixosConfigurations = {
      fwk-nixos = nixpkgs.lib.nixosSystem {
        specialArgs = { inherit inputs system; };

        modules = [
        ./nixos/configuration.nix
        nixos-hardware.nixosModules.framework-16-7040-amd
        inputs.home-manager.nixosModules.default
        ];
      };
    };
  };
}

home.nix (irrelevant bits removed):

{ config, pkgs, plasma-manager, ... }:

{
  imports = [
    plasma-manager.homeManagerModules.plasma-manager
  ];

  home = {
    username = "jat";
    homeDirectory = "/home/jat";
    stateVersion = "23.11";

    packages = with pkgs; [
      vscode
     ...
    ];

    file = {
      ".config/Code/User/settings.json".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/nix-fwk-system/configs/vscode-settings.json"; # vscode settings.json
      ...
    };

    sessionVariables = {
      EDITOR = "code";
    };
  };

  # set allowunFree
  nixpkgs = {
    config = {
      allowUnfree = true;
    };
  };

  programs = {
    home-manager.enable = true;
    ...
    vscode = {
      enable = true;
      extensions = with pkgs.vscode-extensions; [
        jdinhlife.gruvbox
        bbenoist.nix
        github.vscode-pull-request-github
      ];
    };
  };
}

I run sudo nixos-rebuild switch --flake nix-fwk-system/#fwk-nixos
jdinhlife.gruvbox extension most of the time installs,
bbenoist.nix does not seem to ever install.
github.vscode-pull-request-github rarely does .

I can't figure out why this is the case.

cat ~/.vscode/extensions/extensions.json | jq '.[].identifier.id'
"jdinhlife.gruvbox"
"github.vscode-pull-request-github"

Side branch has extensions set as follows:

vscode = {
      enable = true;
      extensions = with pkgs.vscode-extensions; [
        bbenoist.nix
      ];

I manually uninstall all vscode extensions then run:

rm ~/.vscode/extensions/extensions.json
sudo nixos-rebuild switch --flake nix-fwk-system/#fwk-nixos --show-trace && cat ~/.vscode/extensions/extensions.json | jq '.[].identifier.id'
building the system configuration...
activating the configuration...
setting up /etc...
reloading user units for jat...
restarting sysinit-reactivation.target
cat ~/.vscode/extensions/extensions.json
[]

Any ideas or how to trouble shoot? adding --show-trace gives me no new information.

Maintainer CC

No response

System information

nix-shell -p nix-info --run "nix-info -m"
these 4 paths will be fetched (0.03 MiB download, 0.17 MiB unpacked):
  /nix/store/zfs2gv7x073znw6b250rgnbij300hva5-binutils-wrapper-2.41
  /nix/store/5p4cw60bx194ix8s5aq6rwwgqi1w9yir-expand-response-params
  /nix/store/4kwk49k8rc8cg8c387kbbjcrl8i0y693-gcc-wrapper-13.2.0
  /nix/store/9wnvhjyxjykwn5y06xc9a2h8rs5fbfia-stdenv-linux
copying path '/nix/store/5p4cw60bx194ix8s5aq6rwwgqi1w9yir-expand-response-params' from 'https://cache.nixos.org'...
copying path '/nix/store/zfs2gv7x073znw6b250rgnbij300hva5-binutils-wrapper-2.41' from 'https://cache.nixos.org'...
copying path '/nix/store/4kwk49k8rc8cg8c387kbbjcrl8i0y693-gcc-wrapper-13.2.0' from 'https://cache.nixos.org'...
copying path '/nix/store/9wnvhjyxjykwn5y06xc9a2h8rs5fbfia-stdenv-linux' from 'https://cache.nixos.org'...
 - system: `"x86_64-linux"`
 - host os: `Linux 6.8.7, NixOS, 24.05 (Uakari), 24.05.20240419.5c24cf2`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.2`
 - channels(root): `"nixos"`
 - nixpkgs: `/home/jat/.nix-defexpr/channels/nixpkgs`

Issue Persists moving back from kernel 6.8.7 to 6.6.28:

nix-shell -p nix-info --run "nix-info -m"
these 4 paths will be fetched (0.03 MiB download, 0.17 MiB unpacked):
  /nix/store/zfs2gv7x073znw6b250rgnbij300hva5-binutils-wrapper-2.41
  /nix/store/5p4cw60bx194ix8s5aq6rwwgqi1w9yir-expand-response-params
  /nix/store/4kwk49k8rc8cg8c387kbbjcrl8i0y693-gcc-wrapper-13.2.0
  /nix/store/9wnvhjyxjykwn5y06xc9a2h8rs5fbfia-stdenv-linux
copying path '/nix/store/5p4cw60bx194ix8s5aq6rwwgqi1w9yir-expand-response-params' from 'https://cache.nixos.org'...
copying path '/nix/store/zfs2gv7x073znw6b250rgnbij300hva5-binutils-wrapper-2.41' from 'https://cache.nixos.org'...
copying path '/nix/store/4kwk49k8rc8cg8c387kbbjcrl8i0y693-gcc-wrapper-13.2.0' from 'https://cache.nixos.org'...
copying path '/nix/store/9wnvhjyxjykwn5y06xc9a2h8rs5fbfia-stdenv-linux' from 'https://cache.nixos.org'...
 - system: `"x86_64-linux"`
 - host os: `Linux 6.6.28, NixOS, 24.05 (Uakari), 24.05.20240419.5c24cf2`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.2`
 - channels(root): `"nixos"`
 - nixpkgs: `/home/jat/.nix-defexpr/channels/nixpkgs`
@oneirocosm
Copy link

For what it's worth, I'm also seeing this on a mac running nix-darwin with home-manager

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug triage Issues or feature request that have not been triaged yet
Projects
None yet
Development

No branches or pull requests

5 participants