aiosmtpd icon indicating copy to clipboard operation
aiosmtpd copied to clipboard

Add SMTP constructor keyword 'stream_reader_class', default asyncio.S…

Open davidmcnabnz opened this issue 4 years ago • 0 comments

…treamReader, allowing user subclass

What do these changes do?

Allows a caller to specify their own subclass of asyncio.StreamReader

Are there changes in behavior for the user?

This will not affect behaviour for users who do not provide a 'stream_reader_class' SMTP constructor keyword. But for callers who do provide their own subclass, this gives the ability to override methods of asyncio.StreamReader, such as .readuntil()

Related issue number

#285

Fixes #285

Checklist

  • [ ] I think the code is well written
  • [ ] Unit tests for the changes exist
  • [ ] tox testenvs have been executed in the following environments:
    • [ ] Linux (Ubuntu 18.04, Ubuntu 20.04, Arch): {py36,py37,py38,py39}-{nocov,cov,diffcov}, qa, docs
    • [ ] Windows (7, 10): {py36,py37,py38,py39}-{nocov,cov,diffcov}
    • [ ] WSL 1.0 (Ubuntu 18.04): {py36,py37,py38,py39}-{nocov,cov,diffcov}, pypy3-{nocov,cov}, qa, docs
    • [ ] FreeBSD (12.2, 12.1, 11.4): {py36,pypy3}-{nocov,cov,diffcov}, qa
    • [ ] Cygwin: py36-{nocov,cov,diffcov}, qa, docs
  • [ ] Documentation reflects the changes
  • [ ] Add a news fragment into the NEWS.rst file
    • Add under the "aiosmtpd-next" section, creating one if necessary
      • You may create subsections to group the changes, if you like
    • Use full sentences with correct case and punctuation
    • Refer to relevant Issue if applicable

davidmcnabnz avatar Oct 19 '21 06:10 davidmcnabnz