Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Required modules for --title missing, despite "Requirement already satisfied" #50

Open
Ravannos opened this issue Jan 7, 2025 · 3 comments

Comments

@Ravannos
Copy link

Ravannos commented Jan 7, 2025

Option for --title is disabled despite installing the requirements in requirements.txt
Best I can figure is that the version number stated in the txt is older than the ones I have installed. However, I am unsure if the updated versions break the code.
Downloads works just fine, just not with --title option
Advice very much appreciated

PS D:\{{--NOICE--}}\[-Downloaders-]\4chan-downloader> pip install -r requirements.txt
WARNING: Ignoring invalid distribution ~ip (C:\Python312\Lib\site-packages)
WARNING: Ignoring invalid distribution ~ip (C:\Python312\Lib\site-packages)
Requirement already satisfied: beautifulsoup4>=4.12.2 in c:\python312\lib\site-packages (from -r requirements.txt (line 1)) (4.12.3)
Requirement already satisfied: Django>=4.2.1 in c:\python312\lib\site-packages (from -r requirements.txt (line 2)) (5.1.4)
Requirement already satisfied: soupsieve>1.2 in c:\python312\lib\site-packages (from beautifulsoup4>=4.12.2->-r requirements.txt (line 1)) (2.6)
Requirement already satisfied: asgiref<4,>=3.8.1 in c:\python312\lib\site-packages (from Django>=4.2.1->-r requirements.txt (line 2)) (3.8.1)
Requirement already satisfied: sqlparse>=0.3.1 in c:\python312\lib\site-packages (from Django>=4.2.1->-r requirements.txt (line 2)) (0.5.3)
Requirement already satisfied: tzdata in c:\python312\lib\site-packages (from Django>=4.2.1->-r requirements.txt (line 2)) (2024.2)
WARNING: Ignoring invalid distribution ~ip (C:\Python312\Lib\site-packages)
WARNING: Ignoring invalid distribution ~ip (C:\Python312\Lib\site-packages)
PS D:\{{--NOICE--}}\[-Downloaders-]\4chan-downloader> python3 inb4404.py -c -d --title https://boards.4chan.org/v/thread/699432664
[2025-01-07 10:30:33 PM] Could not import the required modules! Disabling --title option...
@Exceen
Copy link
Owner

Exceen commented Jan 7, 2025

execute python3 -m pip install bs4 django and try the script again please

@Ravannos
Copy link
Author

Ravannos commented Jan 8, 2025

This has worked. Thanks for the assistance. The --title option now works as intended.
If it's not too much trouble, I'd like to ask why adding -m fixed it. A cursory google search says it's a module option of a sorts. But other than that, I do not know why -m worked while one without it doesn't.
Once again, thanks for the help.

@Exceen
Copy link
Owner

Exceen commented Jan 8, 2025

This has worked. Thanks for the assistance. The --title option now works as intended. If it's not too much trouble, I'd like to ask why adding -m fixed it. A cursory google search says it's a module option of a sorts. But other than that, I do not know why -m worked while one without it doesn't. Once again, thanks for the help.

it shouldn't make a difference as long as you have only one python version installed. it's very common to have multiple versions installed though. pip might point to the 3.9 version while python3 points to the 3.10 version.

pip is a module of python, not a separate program. pip is basically just an alias

in your case you probably installed the packages for python3.12 but python3 points to a different version, so the packages are not installed for the version you use to run the script

personally I'd recommend to always use python3 -m pip and never use pip directly because of that

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

No branches or pull requests

2 participants