Skip to content

Commit b3649db

Browse files
committed
improve logging messages for clarity
1 parent 0355f50 commit b3649db

File tree

3 files changed

+3
-5
lines changed

3 files changed

+3
-5
lines changed

backend/scraping/instagram_feed.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ def get_apify_input(username=None):
312312

313313
if username:
314314
usernames = [username]
315-
logger.info(f"Scraping @{username}")
315+
logger.info(f"Scraping @{username}...")
316316
else:
317317
usernames = []
318318
for url in FULL_URLS:

backend/scraping/logging_config.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ def setup_logging():
1919
logging.getLogger("botocore").setLevel(logging.WARNING)
2020
logging.getLogger("httpcore").setLevel(logging.WARNING)
2121
logging.getLogger("openai").setLevel(logging.WARNING)
22-
logging.getLogger("PIL").setLevel(logging.INFO)
22+
logging.getLogger("PIL").setLevel(logging.WARNING)
2323
logging.getLogger("apify_client").setLevel(logging.WARNING)
2424

25-
fmt = "%(asctime)s - %(name)s - %(levelname)s - %(message)s"
25+
fmt = "%(asctime)s - %(levelname)s - %(message)s"
2626
handlers = [
2727
logging.StreamHandler(sys.stdout),
2828
logging.FileHandler(LOG_FILE, encoding="utf-8"),

backend/scraping/process_single_user.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ def main():
1919
logger.error("No TARGET_USERNAME provided.")
2020
sys.exit(1)
2121

22-
logger.info(f"Scraping @{target_user}...")
2322
posts_data = run_apify_scraper(username=target_user)
2423
if not posts_data:
2524
logger.warning("No posts found.")
@@ -29,7 +28,6 @@ def main():
2928
import asyncio
3029
try:
3130
asyncio.run(process_scraped_posts(posts_data, cutoff_date))
32-
logger.info("Done.")
3331
except Exception as e:
3432
logger.error(f"Error during processing: {e}")
3533
sys.exit(1)

0 commit comments

Comments
 (0)