Skip to content

Commit

Permalink
Fix weibo jeader dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
aturret authored Nov 7, 2023
1 parent 47ae53b commit db40eb0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/services/weibo/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import jmespath
from bs4 import BeautifulSoup
from lxml import html
from fake_useragent import UserAgent

from app.models.metadata_item import MetadataItem, MediaFile, MessageType
from app.utils.config import CHROME_USER_AGENT
Expand All @@ -32,7 +33,7 @@ def __init__(
data: Optional[Any] = None,
method: Optional[str] = "api",
scraper: Optional[str] = "requests",
user_agent: Optional[dict] = CHROME_USER_AGENT,
user_agent: Optional[dict] = UserAgent().random,
cookies: Optional[str] = WEIBO_COOKIES,
):
# basic info
Expand Down

0 comments on commit db40eb0

Please sign in to comment.