From b206a1eb6364e519741ceb89e3f3b63910b4e1ef Mon Sep 17 00:00:00 2001 From: Raju Komati Date: Fri, 28 Apr 2023 02:27:06 +0530 Subject: update openai_rev module add test file with simple use --- testing/poe_account_create_test.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'testing/poe_account_create_test.py') diff --git a/testing/poe_account_create_test.py b/testing/poe_account_create_test.py index 24751c4a..7072597f 100644 --- a/testing/poe_account_create_test.py +++ b/testing/poe_account_create_test.py @@ -1,17 +1,20 @@ from hashlib import md5 from json import dumps from re import findall +from typing import Optional -from quora import extract_formkey -from quora.mail import Emailnator from tls_client import Session as TLS from twocaptcha import TwoCaptcha +from openai_rev.quora import extract_formkey +from openai_rev.quora.mail import Emailnator + solver = TwoCaptcha('72747bf24a9d89b4dcc1b24875efd358') class Account: - def create(proxy: None or str = None, logging: bool = False, enable_bot_creation: bool = False): + @staticmethod + def create(proxy: Optional[str] = None, logging: bool = False, enable_bot_creation: bool = False): client = TLS(client_identifier='chrome110') client.proxies = {'http': f'http://{proxy}', 'https': f'http://{proxy}'} if proxy else None -- cgit v1.2.3