nntplib body question
Paul Rubin
http
Wed Jun 4 00:51:35 EDT 2003
martin at v.loewis.de (Martin v. Löwis) writes:
> > is there any way to load only the first x lines of a post body via nntplib?
> > with read callbacks or something similar?
>
> To my knowledge, the NNTP protocol does not support such a query. So
> regardless of what the API is, you always have to fetch the entire
> body, and throw away all lines you don't want.
Well, you could drop the connection after you've read enough lines.
If it's a several megabyte message and you want just a few lines, that
may be a win.
More information about the Python-list
mailing list