We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 23364cc commit 0ae7a7cCopy full SHA for 0ae7a7c
MANIFEST.in
@@ -1 +1 @@
1
-include LICENSE README.md cfscrape/user_agents.json
+include LICENSE README.md
cfscrape/__init__.py
@@ -1,6 +1,5 @@
# -*- coding: utf-8 -*-
2
3
-import json
4
import logging
5
import random
6
import re
@@ -19,14 +18,11 @@
19
18
20
from urllib3.util.ssl_ import create_urllib3_context, DEFAULT_CIPHERS
21
22
-__version__ = "2.0.5"
+from .user_agents import USER_AGENTS
23
24
-USER_AGENTS_PATH = os.path.join(os.path.dirname(__file__), "user_agents.json")
+__version__ = "2.0.6"
25
26
-with open(USER_AGENTS_PATH) as f:
27
- user_agents = json.load(f)
28
-
29
-DEFAULT_USER_AGENT = random.choice(user_agents)
+DEFAULT_USER_AGENT = random.choice(USER_AGENTS)
30
31
DEFAULT_HEADERS = OrderedDict(
32
(
cfscrape/user_agents.json
0 commit comments