• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

galthran-wq / telegram-scraper-service / 22133380794

18 Feb 2026 09:07AM UTC coverage: 62.301% (-3.4%) from 65.657%
22133380794

Pull #4

github

web-flow
Merge 520317f93 into 1148f909b
Pull Request #4: photos

28 of 71 new or added lines in 5 files covered. (39.44%)

352 of 565 relevant lines covered (62.3%)

0.62 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

47.37
/src/api/endpoints/users.py
1
import structlog
1✔
2
from fastapi import APIRouter, HTTPException, Query
1✔
3

4
from src.core.retry import with_retry
1✔
5
from src.schemas.telegram import UserProfilePhotosResponse
1✔
6
from src.services.telegram import get_user_profile_photos
1✔
7

8
logger = structlog.get_logger()
1✔
9

10
router = APIRouter(prefix="/api/users", tags=["users"])
1✔
11

12

13
@router.get("/{user}/photos", response_model=UserProfilePhotosResponse)
1✔
14
async def user_photos(
1✔
15
    user: str,
16
    limit: int = Query(10, ge=1, le=50),
17
) -> UserProfilePhotosResponse:
NEW
18
    try:
×
NEW
19
        photos = await with_retry(get_user_profile_photos, user, limit=limit)
×
NEW
20
        return UserProfilePhotosResponse(user_id=user, photos=photos, count=len(photos))
×
NEW
21
    except HTTPException:
×
NEW
22
        raise
×
NEW
23
    except ValueError as e:
×
NEW
24
        raise HTTPException(status_code=404, detail=str(e)) from None
×
NEW
25
    except Exception as e:
×
NEW
26
        logger.error("user_photos_error", user=user, error=str(e))
×
NEW
27
        raise HTTPException(status_code=500, detail=str(e)) from e
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc