Skip to content
This repository was archived by the owner on Nov 5, 2023. It is now read-only.

Commit 62ae98b

Browse files
Remove deprecated methods
1 parent ecd94b9 commit 62ae98b

File tree

1 file changed

+1
-21
lines changed

1 file changed

+1
-21
lines changed

pubproxpy/fetcher.py

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
from datetime import datetime as dt
99
import json
1010
import os
11-
import sys
1211
from time import sleep
1312
from urllib.parse import urlencode
1413

@@ -183,7 +182,7 @@ def _format_params(self, params):
183182
def drain(self):
184183
"""Returns any proxies remaining in the current list
185184
"""
186-
return self.get_proxies(len(self._proxies))
185+
return self.get(len(self._proxies))
187186

188187
def get(self, amount=1):
189188
"""Attempts to get `amount` proxies matching the specified params
@@ -210,25 +209,6 @@ def get(self, amount=1):
210209

211210
return temp
212211

213-
def get_proxy(self):
214-
"""
215-
!DEPRECATED!
216-
Attempts to get a single proxy matching the specified params
217-
"""
218-
return self.get_proxies(1)[0]
219-
220-
def get_proxies(self, amount):
221-
"""
222-
!DEPRECATED!
223-
Attempts to get `amount` proxies matching the specified params
224-
"""
225-
print(
226-
"DEPRECATED: this method is deprecated in favor of `.get(...)` and"
227-
" will be removed in the next major version of the library (2.0)",
228-
file=sys.stderr,
229-
)
230-
return self.get(amount)
231-
232212
def _fetch(self):
233213
"""Attempts to get the proxies from pubproxy.com, will `sleep` to
234214
prevent getting rate-limited

0 commit comments

Comments
 (0)