def METHOD_NAME(session: DbSession, owner: str) -> Tuple[int, int]:
    select_stmt = (
        select(
            func.count().label("nb_files"),
            func.sum(StoredFileDb.size).label("total_size"),
        )
        .select_from(MessageFilePinDb)
        .join(StoredFileDb, MessageFilePinDb.file_hash == StoredFileDb.hash)
        .where(MessageFilePinDb.owner == owner)
    )
    result = session.execute(select_stmt).one()
    return result.nb_files, result.total_size