Skip to content

[BUG] Nixos: caelestia cli error when used as hm module with shell #512

Description

@nappairam

Step 1. Before you submit

  • I have read the above instructions and am sure that this is supposed to be posted here.
  • I've successfully updated to the latest versions following the updating guide.
  • I've successfully updated the system packages to the latest.
  • I've ticked the checkboxes without reading their contents

Step 2. Version info

Version info
❯ caelestia -v
Packages: not on Arch
 
fatal: not a git repository: '/home/maari/.config/.git'
Caelestia: not installed
 
Quickshell: not in PATH
 
Local copy of shell found:
    Unable to determine last merged upstream commit.
fatal: not a git repository: '/home/maari/.config/quickshell/caelestia/.git'
Traceback (most recent call last):
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/bin/.caelestia-wrapped", line 9, in <module>
    sys.exit(main())
             ~~~~^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/__init__.py", line 8, in main
    print_version()
    ~~~~~~~~~~~~~^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/utils/version.py", line 64, in print_version
    shell_ver = subprocess.check_output(
        ["git", "--git-dir", local_shell_dir / ".git", "rev-list", "--format=%B", "--max-count=1", "HEAD"],
        text=True,
    )
  File "/nix/store/iyff8129iampdw13nlfqalzhxy8y1hi9-python3-3.13.6/lib/python3.13/subprocess.py", line 472, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
           ~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
               **kwargs).stdout
               ^^^^^^^^^
  File "/nix/store/iyff8129iampdw13nlfqalzhxy8y1hi9-python3-3.13.6/lib/python3.13/subprocess.py", line 577, in run
    raise CalledProcessError(retcode, process.args,
                             output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', '--git-dir', PosixPath('/home/maari/.config/quickshell/caelestia/.git'), 'rev-list', '--format=%B', '--max-count=1', 'HEAD']' returned non-zero exit status 128.
 

Step 3. Describe the issue

I am using caelestia shell as a home manager module
https://gitlab.com/mariappan/nix-config/-/blob/main/modules/homemanager/linux/features/caelestia.nix
https://gitlab.com/mariappan/nix-config/-/blob/main/overlays/default.nix#L19

It used to work perfectly until last week. This week when I tried to update flake, it started failing.
I have attached the logs which may be useful. please let me know if any other details required.

Logs
❯ caelestia shell ipc call drawers toggle launcher
Traceback (most recent call last):
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/bin/.caelestia-wrapped", line 9, in <module>
    sys.exit(main())
             ~~~~^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/__init__.py", line 10, in main
    args.cls(args).run()
    ~~~~~~~~~~~~~~~~~~^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/subcommands/shell.py", line 25, in run
    self.message(*self.args.message)
    ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/subcommands/shell.py", line 60, in message
    print(self.shell("ipc", "call", *args), end="")
          ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/ghb920w5bhjvlrdg9b2ha75gz23vbch5-caelestia-cli-db1e0da5bbd259f1218b4ae54d0327b0c4a46f78/lib/python3.13/site-packages/caelestia/subcommands/shell.py", line 41, in shell
    return subprocess.check_output(["caelestia-shell", *args], text=True)
           ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/iyff8129iampdw13nlfqalzhxy8y1hi9-python3-3.13.6/lib/python3.13/subprocess.py", line 472, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
           ~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
               **kwargs).stdout
               ^^^^^^^^^
  File "/nix/store/iyff8129iampdw13nlfqalzhxy8y1hi9-python3-3.13.6/lib/python3.13/subprocess.py", line 577, in run
    raise CalledProcessError(retcode, process.args,
                             output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['caelestia-shell', 'ipc', 'call', 'ipc', 'call', 'drawers', 'toggle', 'launcher']' returned non-zero exit status 255.


❯ caelestia-shell ipc call lock lock
No running instances for "/nix/store/jas49nilf6qj95fi2kkpw25jhax2p4c3-caelestia-shell-1.0.0/share/caelestia-shell/shell.qml"


❯ readlink -f /etc/profiles/per-user/maari/bin/caelestia-shell
/nix/store/jas49nilf6qj95fi2kkpw25jhax2p4c3-caelestia-shell-1.0.0/bin/caelestia-shell


❯ ls /nix/store/jas49nilf6qj95fi2kkpw25jhax2p4c3-caelestia-shell-1.0.0/share/caelestia-shell/
 assets   components   config   LICENSE   modules   services   shell.qml   utils


❯ ps aux | grep quickshell
maari      60746  3.0  0.9 1628776 313912 ?      Ssl  13:16   0:01 /nix/store/2dn8dknrfx6ajaczxdfrrbh9fr86aflr-quickshell-wrapped-0.2.0/bin/quickshell -p /nix/store/6bc5dijwmvqxg41jgldbbmmzz3pqby4w-caelestia-shell-54921ee354827aac71a435ad9fe903b8667901fc/share/caelestia-shell
maari      62254  0.0  0.0   6812  2876 pts/2    S+   13:17   0:00 /nix/store/5ygilvgz6l47fw3x5ylb0cz1afgc3737-gnugrep-3.12/bin/grep --color=auto quickshell

Reminder

  • I agree that it's usually impossible for others to help me without my logs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions