Fred808 commited on
Commit
2778998
·
verified ·
1 Parent(s): 58bbf6e

Update utils/instaloader_utils.py

Browse files
Files changed (1) hide show
  1. utils/instaloader_utils.py +0 -13
utils/instaloader_utils.py CHANGED
@@ -6,19 +6,6 @@ import instaloader.exceptions
6
  L = instaloader.Instaloader()
7
 
8
 
9
- # Login to Instagram (replace with your credentials)
10
- INSTAGRAM_USERNAME = "pex7242" # Replace with your Instagram username
11
- INSTAGRAM_PASSWORD = "aestheticos" # Replace with your Instagram password
12
-
13
- try:
14
- L.login(INSTAGRAM_USERNAME, INSTAGRAM_PASSWORD)
15
- print("Logged in successfully.")
16
- except instaloader.exceptions.BadCredentialsException:
17
- raise Exception("Invalid Instagram credentials. Please check your username and password.")
18
- except instaloader.exceptions.ConnectionException:
19
- raise Exception("Connection failed. Check your internet connection.")
20
- except Exception as e:
21
- raise Exception(f"Unexpected login error: {str(e)}")
22
 
23
  async def fetch_user_posts(username: str, max_posts: int = 20):
24
  try:
 
6
  L = instaloader.Instaloader()
7
 
8
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
 
10
  async def fetch_user_posts(username: str, max_posts: int = 20):
11
  try: