kovidgoyal / kitty

Cross-platform, fast, feature-rich, GPU based terminal
https://sw.kovidgoyal.net/kitty/
GNU General Public License v3.0
24.57k stars 983 forks source link

New build issue #7702

Closed jonwilts closed 3 months ago

jonwilts commented 3 months ago

Describe the bug I regularly build kitty from source. Doing so today failed.

To Reproduce

dev@air (/home/dev) % cd ~/Code/github/kitty/
dev@air (.../github/kitty) % git pull
Already up to date.
dev@air (.../github/kitty) % ./dev.sh build
[123/123] Compiling kitty/gl-wrapper.c ... done
[5/5] Linking launcher ... done
kitty/kittens/hyperlinked_grep
# kitty/kittens/hyperlinked_grep
kittens/hyperlinked_grep/main.go:430:6: Options redeclared in this block
    kittens/hyperlinked_grep/cli_generated.go:20:6: other declaration of Options
kittens/hyperlinked_grep/main.go:433:6: create_cmd redeclared in this block
    kittens/hyperlinked_grep/cli_generated.go:5:6: other declaration of create_cmd
The following build command failed: /home/dev/Code/github/kitty/dependencies/linux-amd64/bin/python setup.py develop
exit status 1
dev@air (.../github/kitty) % /home/dev/Code/github/kitty/dependencies/linux-amd64/bin/python setup.py develop
Traceback (most recent call last):
  File "/home/dev/Code/github/kitty/setup.py", line 2207, in <module>
    main()
  File "/home/dev/Code/github/kitty/setup.py", line 2203, in main
    do_build(args)
  File "/home/dev/Code/github/kitty/setup.py", line 2159, in do_build
    build_launcher(args, launcher_dir=launcher_dir, bundle_type='develop')
  File "/home/dev/Code/github/kitty/setup.py", line 1289, in build_launcher
    ph = os.path.relpath(os.environ["DEVELOP_ROOT"], '.')
                         ~~~~~~~~~~^^^^^^^^^^^^^^^^
  File "<frozen os>", line 714, in __getitem__
KeyError: 'DEVELOP_ROOT'
dev@air (.../github/kitty) % 

I've searched the documentation for any mention of a DEVELOP_ROOT environment variable but no luck.

Environment details


kitty 0.35.2 (62bd6c88e9) created by Kovid Goyal
Linux air 6.10.3-zen1-2-zen #1 ZEN SMP PREEMPT_DYNAMIC Tue, 06 Aug 2024 07:47:21 +0000 x86_64
Arch Linux 6.10.3-zen1-2-zen (/dev/tty)

DISTRIB_ID="Arch"
DISTRIB_RELEASE="rolling"
DISTRIB_DESCRIPTION="Arch Linux"
Running under: Wayland (kwin 6.1.3) missing: single_pixel_buffer
OpenGL: '4.6 (Core Profile) Mesa 24.1.5-arch1.2' Detected version: 4.6
Frozen: False
Fonts:
  medium: FiraCodeNF-Ret: /usr/local/share/fonts/f/FiraCode_Nerd_Font_Retina.ttf:0
  bold: FiraCodeNF-Ret: /usr/local/share/fonts/f/FiraCode_Nerd_Font_Retina.ttf:0
  italic: FiraCodeNF-Ret: /usr/local/share/fonts/f/FiraCode_Nerd_Font_Retina.ttf:0
  bi: FiraCodeNF-Ret: /usr/local/share/fonts/f/FiraCode_Nerd_Font_Retina.ttf:0
Paths:
  kitty: /home/dev/Code/github/kitty/kitty/launcher/kitty
  base dir: /home/dev/Code/github/kitty
  extensions dir: /home/dev/Code/github/kitty/kitty
  system shell: /usr/bin/bash
Loaded config files:
  /home/dev/.config/kitty/kitty.conf

Config options different from defaults:
allow_remote_control       yes
background_blur            1
confirm_os_window_close    0
dynamic_background_opacity True
font_family                FiraCode Nerd Font
font_features:
{'FiraCodeNF-Ret': ('ss03',)}
font_size                  10.5
initial_window_height      (836, 'px')
initial_window_width       (1070, 'px')
linux_display_server       wayland
listen_on                  unix:@kitty{kitty_pid}
remember_window_size       False
shell                      /usr/bin/bash -l
shell_integration          frozenset({'disabled'})
tab_bar_edge               1
tab_bar_margin_height      TabBarMarginHeight(outer=5.0, inner=0)
tab_bar_min_tabs           1
tab_bar_style              powerline
wayland_enable_ime         False
window_padding_width       FloatEdges(left=5.0, top=5.0, right=5.0, bottom=5.0)
Added shortcuts:
    alt+left →  previous_tab
    alt+right →  next_tab
    alt+t →  new_tab
    alt+w →  close_tab
    shift+alt+left →  previous_window
    shift+alt+right →  next_window
    shift+alt+t →  new_window
    super+c →  copy_to_clipboard
    super+enter →  toggle_fullscreen
    super+v →  paste_from_clipboard
Colors:
    active_tab_background      #e5e9f0   
    active_tab_foreground      #2e3440   
    inactive_tab_background    #4c566a   
    inactive_tab_foreground    #adb8ca   

Important environment variables seen by the kitty process:
    PATH                                /usr/local/sbin:/usr/local/bin:/usr/bin:/opt/cuda/bin:/opt/cuda/nsight_compute:/opt/cuda/nsight_systems/bin:/var/lib/flatpak/exports/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/usr/lib/rustup/bin
    LANG                                en_US.UTF-8
    SHELL                               /usr/bin/bash
    DISPLAY                             :1
    WAYLAND_DISPLAY                     wayland-0
    USER                                dev
    XDG_DATA_DIRS                       /home/dev/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share
    XDG_RUNTIME_DIR                     /run/user/1000
    XDG_CONFIG_DIRS                     /home/dev/.config/kdedefaults:/etc/xdg
    XDG_CURRENT_DESKTOP                 KDE
    XDG_MENU_PREFIX                     plasma-
    XDG_SEAT                            seat0
    XDG_SEAT_PATH                       /org/freedesktop/DisplayManager/Seat0
    XDG_SESSION_CLASS                   user
    XDG_SESSION_DESKTOP                 KDE
    XDG_SESSION_ID                      2
    XDG_SESSION_PATH                    /org/freedesktop/DisplayManager/Session1
    XDG_SESSION_TYPE                    wayland
    XDG_VTNR                            1
neurocyte commented 3 months ago

You probably need to run ./dev.ssh deps to update the build dependencies. And then retry ./dev.sh build.

kovidgoyal commented 3 months ago

Do a make clean and the ./dev.sh build and you will be fine.

jonwilts commented 3 months ago

Thanks both.

@neurocyte - I did do a ./dev.sh deps beforehand, just forgot to add it when I was doing a fresh attempt which I could cut and paste into here!

@kovidgoyal - thank you, that solved it. Will make sure to do that each time.

kovidgoyal commented 3 months ago

On Wed, Aug 07, 2024 at 08:38:50AM -0700, jonwilts wrote:

@kovidgoyal - thank you, that solved it. Will make sure to do that each time.

It's rare that you need to do a clean, but sometimes it does happen.