Spaces:
Paused
Paused
Commit ·
12c8076
1
Parent(s): 3bae73c
cloudscraper
Browse files- requirements.txt +1 -0
- rule34.py +6 -2
requirements.txt
CHANGED
|
@@ -2,6 +2,7 @@ streamlit
|
|
| 2 |
streamlit_option_menu
|
| 3 |
pytube
|
| 4 |
youtube-dl
|
|
|
|
| 5 |
moviepy
|
| 6 |
tqdm
|
| 7 |
selenium
|
|
|
|
| 2 |
streamlit_option_menu
|
| 3 |
pytube
|
| 4 |
youtube-dl
|
| 5 |
+
cloudscraper
|
| 6 |
moviepy
|
| 7 |
tqdm
|
| 8 |
selenium
|
rule34.py
CHANGED
|
@@ -1,10 +1,14 @@
|
|
| 1 |
from bs4 import BeautifulSoup
|
| 2 |
import json
|
| 3 |
from others import *
|
|
|
|
|
|
|
| 4 |
|
| 5 |
-
def get_info_rule34(
|
| 6 |
-
|
|
|
|
| 7 |
soup = BeautifulSoup(response.text, 'html.parser')
|
|
|
|
| 8 |
# Mencari judul video di elemen dengan class title_video
|
| 9 |
title = soup.find(class_="title_video")
|
| 10 |
if title:
|
|
|
|
| 1 |
from bs4 import BeautifulSoup
|
| 2 |
import json
|
| 3 |
from others import *
|
| 4 |
+
import cloudscraper
|
| 5 |
+
scraper = cloudscraper.create_scraper()
|
| 6 |
|
| 7 |
+
def get_info_rule34(link):
|
| 8 |
+
|
| 9 |
+
response = scraper.get(link)
|
| 10 |
soup = BeautifulSoup(response.text, 'html.parser')
|
| 11 |
+
|
| 12 |
# Mencari judul video di elemen dengan class title_video
|
| 13 |
title = soup.find(class_="title_video")
|
| 14 |
if title:
|