Pulls random images from https://prnt.sc
Project description
prntscraper
-
prntscraper will allow you to scrape images from the prnt.sc website as they have predictable subheadings we can freely attempt to get random images or images in a sequential order from a specified amount to a max limit and download them into a folder. This is a security issue from their end as It's highly common people store sensitive information that could easily be stolen if these images are found by the wrong people.
-
DISCLAIMER I am not responsible for the information that may be found with this package.
Installation
This module is compatible with Python3+.
- Install latest version from git repository using pip:
$ pip install git+https://github.com/ItzBlinkzy/prntscraper.git
- Install from PyPI:
$ pip install prntscraper
How to use
- When setting this up make sure you have a folder called "images" in the same directory as the file importing the module.
from prntscraper.scraper import PrntScraper
# Get random images and store them in ./images folder
my_scraper = PrntScraper()
result = my_scraper.get_random_images()
print(result)
# Take inputted images and store them in ./images folder.
my_scraper = PrntScraper()
result = my_scraper.get_input_images()
print(result)
# Get the count of all the images in the ./images folder.
my_scraper = PrntScraper()
result = my_scraper.folder_size()
print(result)
Outputs:
get_random_images()
How many images would you like?: 5
Downloaded https://prnt.sc/odchh5
Downloaded https://prnt.sc/2n833q
Downloaded https://prnt.sc/n2w4x9
Downloaded https://prnt.sc/cy2cgi
Downloaded https://prnt.sc/w0a6bn
Successfully downloaded 5 images. Look at ./images folder.
get_input_images()
Enter any two random letters in the alphabet. Example [gy]: vk
Enter a Point below 9999 to start from: 100
Enter an End Point below 9999 to end: 105
Downloaded https://prnt.sc/vk0100
Downloaded https://prnt.sc/vk0101
Downloaded https://prnt.sc/vk0102
Downloaded https://prnt.sc/vk0103
Downloaded https://prnt.sc/vk0104
Downloaded https://prnt.sc/vk0105
Successfully downloaded 6 images. Look at ./images folder.
folder_size()
There are currently 11 images in the folder.
Pretty simple right?
Issues
Feel free to open an issue or make a pull request if you have any problems using this module.
Credits
- ItzBlinkzy
- You can be here too if you'd like to contribute.
Repo
* https://github.com/ItzBlinkzy/prntscraper/
License
GNU General Public License v3
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file prntscraper-2.2.3-py3-none-any.whl.
File metadata
- Download URL: prntscraper-2.2.3-py3-none-any.whl
- Upload date:
- Size: 16.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/52.0.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.9.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eaff44f13e6074231ab2e587f85cefd4538bb4935e294543d1889eba224a5bb2
|
|
| MD5 |
0ff2c002fefccb0011764bdf5f78661d
|
|
| BLAKE2b-256 |
3d8b3ec2bc293113a7ed0ce2f778f49d25b7bfaa3108c104c5cd0ee2388876f1
|