Python dependencies for each user. Unknowns Error 1 for dependencies quickfix
- Dominant language
- Python
- Stars
- 7.8k
- Forks
- 412
- PR merge metrics
- No merged PRs in 30d
Description
When authenticating in different places, different users are used (gdm, sudo, gnome authentication dialog). Each of these users needs all valid python requirements. This causes dependency issues, because in different contexts, different modules are available. Here is a quickfix, to get all dependencies in line.
You'll want an elevated prompt:
```bash
sudo su -
```
Go to howdy directory, create python venv and activate it
```bash
cd /lib64/security/howdy
python3 -m venv .venv
source .venv/bin/activate
```
Install dependencies:
```bash
pip install dlib opencv-python
```
and finally edit pam.py
```diff
- status = subprocess.call(["/usr/bin/python3 " + os.path.dirname(os.path.abspath(__file__)) + "/compare.py " + pamh.get_user() + " &> /dev/null"], shell=True)
+ status = subprocess.call(["/lib64/security/howdy/.venv/bin/python " + os.path.dirname(os.path.abspath(__file__)) + "/compare.py " + pamh.get_user() + " &> /dev/null"], shell=True)
```
I created this issue, because I had a lot of errors, and they all just boiled down to broken dependencies
----
I've searched for similar issues already, and my issue has not been reported yet.
Linux distribution: Fedora 40
Howdy version: 2.6.1
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with pam.py and compare.py, then reproduce the dependency failure across the gdm, sudo, and GNOME authentication contexts using the commands in the issue. Check how the project currently locates Python and its dependencies; the work is done when each authentication user can access the required modules without the reported Unknowns Error 1.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux, opencv, python
- Domain
- authentication, operating-systems, security
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100