mathoudebine / mathoudebine/turing-smart-screen-python

Add instructions when using systemctl services and python virtualenv

Open Beginner friendly
#557 2 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rich Text Format
Stars
2.3k
Forks
412
Avg merge
21h 10m
Merged PRs (30d)
7

Description

When using python virtual environments to install the dependencies you need to modify the ExecStart value so it uses the correct set of libraries, but this is not specified in the how to start guide, even though it is recommended in previous steps to use them.

So, the tools/turing-smart-screen-python.service file should look something like this:

...


; If you want to put the program in your home directory instead, remove 'ProtectHome=read-only' line below
WorkingDirectory=/opt/turing-smart-screen-python/

ExecStart=/opt/turing-smart-screen-python/.venv/bin/python3 main.py

; Always restart the script
Restart=always

...

Or the proper route if you have it under the $HOME directory.

Maybe for some more experienced user this is simply logical but for people who never set services in a project using virtualenvs can be quite a headache.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read the System monitor: how to start guide's Linux systemd section and compare it with tools/turing-smart-screen-python.service. Document how a Python virtual environment changes ExecStart, including the /opt example and the $HOME case, then verify that the instructions match the service file and existing startup steps.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, documentation
Issue type
Documentation
Difficulty
1/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.