Skip to content

fix(gateway): preserve venv python in systemd unit - #8234

Closed
inside-ziwu wants to merge 1 commit into
NousResearch:mainfrom
inside-ziwu:fix/systemd-unit-preserve-venv-python
Closed

fix(gateway): preserve venv python in systemd unit#8234
inside-ziwu wants to merge 1 commit into
NousResearch:mainfrom
inside-ziwu:fix/systemd-unit-preserve-venv-python

Conversation

@inside-ziwu

@inside-ziwu inside-ziwu commented Apr 12, 2026

Copy link
Copy Markdown

Summary

  • preserve the project venv Python entrypoint when generating the systemd system service unit
  • avoid resolving the venv interpreter symlink to the underlying base interpreter

Problem

The generated system service unit could point at the underlying uv-managed interpreter instead of the project venv entrypoint. That can bypass the expected environment and break startup with missing dependencies.

Testing

  • generated the systemd unit locally and verified the Python path stays on the project venv entrypoint
  • verified the existing home-prefix remapping behavior remains unchanged for other paths

@inside-ziwu
inside-ziwu force-pushed the fix/systemd-unit-preserve-venv-python branch from 69d11ce to 5b77068 Compare April 12, 2026 15:11
@teknium1

Copy link
Copy Markdown
Contributor

Already fixed on main via PR #8861 (salvage of #7735 by @akhater). The current code drops .resolve() entirely and uses .expanduser() for lexical-only expansion, preserving venv symlinks. Thanks for the contribution!

@teknium1 teknium1 closed this Apr 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants