user-scanner 1.0.4.0__py3-none-any.whl → 1.0.4.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- user_scanner/__main__.py +3 -0
- user_scanner/creator/producthunt.py +40 -0
- user_scanner/version.json +1 -1
- {user_scanner-1.0.4.0.dist-info → user_scanner-1.0.4.2.dist-info}/METADATA +2 -2
- {user_scanner-1.0.4.0.dist-info → user_scanner-1.0.4.2.dist-info}/RECORD +8 -7
- {user_scanner-1.0.4.0.dist-info → user_scanner-1.0.4.2.dist-info}/WHEEL +0 -0
- {user_scanner-1.0.4.0.dist-info → user_scanner-1.0.4.2.dist-info}/entry_points.txt +0 -0
- {user_scanner-1.0.4.0.dist-info → user_scanner-1.0.4.2.dist-info}/licenses/LICENSE +0 -0
user_scanner/__main__.py
CHANGED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import httpx
|
|
2
|
+
from httpx import ConnectError, TimeoutException
|
|
3
|
+
|
|
4
|
+
def validate_producthunt(user):
|
|
5
|
+
url = f"https://www.producthunt.com/@{user}"
|
|
6
|
+
|
|
7
|
+
headers = {
|
|
8
|
+
'User-Agent': "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36",
|
|
9
|
+
'Accept': "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7",
|
|
10
|
+
'Accept-Encoding': "gzip, deflate, br",
|
|
11
|
+
'Accept-Language': "en-US,en;q=0.9",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
try:
|
|
15
|
+
response = httpx.get(url, headers=headers, timeout = 3.0, follow_redirects=True)
|
|
16
|
+
status = response.status_code
|
|
17
|
+
|
|
18
|
+
if status == 200:
|
|
19
|
+
return 0
|
|
20
|
+
elif status == 404:
|
|
21
|
+
return 1
|
|
22
|
+
else:
|
|
23
|
+
return 2
|
|
24
|
+
|
|
25
|
+
except (ConnectError, TimeoutException):
|
|
26
|
+
return 2
|
|
27
|
+
except Exception:
|
|
28
|
+
return 2
|
|
29
|
+
|
|
30
|
+
if __name__ == "__main__":
|
|
31
|
+
user = input ("Username?: ").strip()
|
|
32
|
+
result = validate_producthunt(user)
|
|
33
|
+
|
|
34
|
+
if result == 1:
|
|
35
|
+
print("Available!")
|
|
36
|
+
elif result == 0:
|
|
37
|
+
print("Unavailable!")
|
|
38
|
+
else:
|
|
39
|
+
print("Error occured!")
|
|
40
|
+
|
user_scanner/version.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: user-scanner
|
|
3
|
-
Version: 1.0.4.
|
|
3
|
+
Version: 1.0.4.2
|
|
4
4
|
Summary: Check username availability across multiple popular platforms
|
|
5
5
|
Keywords: username,checker,availability,social,tech,python,user-scanner
|
|
6
6
|
Author-email: Kaif <kafcodec@gmail.com>
|
|
@@ -15,7 +15,7 @@ Project-URL: Homepage, https://github.com/kaifcodec/user-scanner
|
|
|
15
15
|
|
|
16
16
|

|
|
17
17
|
<p align="center">
|
|
18
|
-
<img src="https://img.shields.io/badge/Version-1.0.4.
|
|
18
|
+
<img src="https://img.shields.io/badge/Version-1.0.4.2-blueviolet?style=for-the-badge&logo=github" />
|
|
19
19
|
<img src="https://img.shields.io/github/issues/kaifcodec/user-scanner?style=for-the-badge&logo=github" />
|
|
20
20
|
<img src="https://img.shields.io/badge/Tested%20on-Termux-black?style=for-the-badge&logo=termux" />
|
|
21
21
|
<img src="https://img.shields.io/badge/Tested%20on-Windows-cyan?style=for-the-badge&logo=Windows" />
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
user_scanner/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
|
2
|
-
user_scanner/__main__.py,sha256=
|
|
3
|
-
user_scanner/version.json,sha256=
|
|
2
|
+
user_scanner/__main__.py,sha256=ZdGxMN0LgzafygRkiZ0wt5Xt8XosFwLs71gB6mh0_bY,3770
|
|
3
|
+
user_scanner/version.json,sha256=23jDI4lYTJ9lUMEGQ5o6zOlKkPZyH6HvYr0V2YHe0RU,49
|
|
4
4
|
user_scanner/cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
5
|
user_scanner/cli/banner.py,sha256=A3uMAwkyf-WHQH3ki3XlslAxAEMPQYZiIGeawnctZEA,1497
|
|
6
6
|
user_scanner/community/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -14,6 +14,7 @@ user_scanner/creator/itch_io.py,sha256=fgxIHIlw4Lk40L479MDsMTCLlRlMIzw1sTHLhxwQ8
|
|
|
14
14
|
user_scanner/creator/kaggle.py,sha256=pCq7QQ62wxunEmBIWNjKyWIH2ENXK76BM3zt4HWi0zM,927
|
|
15
15
|
user_scanner/creator/medium.py,sha256=dWNialp0QTo4GRq64afA00G3PDXVOLZM3mnO3WnmR8c,1008
|
|
16
16
|
user_scanner/creator/patreon.py,sha256=drjlB5XDFs1TW6J3W1LqBwZhc6PWtn-5nLBG8OtnFhU,1274
|
|
17
|
+
user_scanner/creator/producthunt.py,sha256=b9ZbOIfcFhBk34TCSoDEW5_4XLF4yGpJL7Vcg_zA54U,1164
|
|
17
18
|
user_scanner/dev/__init__.py,sha256=qUR0eLwN-gO6oKk-1cmCVT4G_AxUHHMgpV3wJ7URXi4,7
|
|
18
19
|
user_scanner/dev/codeberg.py,sha256=WuGisrD2-OVolXB1T_5Dn-J8Nx5BTX_Fh2MTsK-F7os,930
|
|
19
20
|
user_scanner/dev/cratesio.py,sha256=n1yJFJ2uWfRzpARSNSZ9s53iPm-5IiAxTOMTq0hOVis,999
|
|
@@ -43,8 +44,8 @@ user_scanner/social/x.py,sha256=NetPGmPnWEKv6za9E_Ekah9bAeeFlEeY3qbTJQo7AqE,1560
|
|
|
43
44
|
user_scanner/social/youtube.py,sha256=zuyWCy5FtEilaIcUZ4dTCctRR9deFnwwWJkf-h_1K0E,1943
|
|
44
45
|
user_scanner/utils/update.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
45
46
|
user_scanner/utils/version.py,sha256=ou6CF7ndVwEYvSpO4Se-B-71AvVezZcaZJpYFgDQsqM,621
|
|
46
|
-
user_scanner-1.0.4.
|
|
47
|
-
user_scanner-1.0.4.
|
|
48
|
-
user_scanner-1.0.4.
|
|
49
|
-
user_scanner-1.0.4.
|
|
50
|
-
user_scanner-1.0.4.
|
|
47
|
+
user_scanner-1.0.4.2.dist-info/entry_points.txt,sha256=XqU3kssYZ0vXaPy5qYUOTCu4u-48Xie7QWFpBCYc7Nc,59
|
|
48
|
+
user_scanner-1.0.4.2.dist-info/licenses/LICENSE,sha256=XH1QyQG68zo1opDIZHTHcTAbe9XMzewvTaFTukcN9vc,1061
|
|
49
|
+
user_scanner-1.0.4.2.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
|
|
50
|
+
user_scanner-1.0.4.2.dist-info/METADATA,sha256=6DQ_7krs1bZs-k2U_BSOCRCgpbPnZYzGhKkuTDRmAT0,4970
|
|
51
|
+
user_scanner-1.0.4.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|