This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients vstinner
Date 2017-08-18.22:06:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1503093990.84.0.706116318866.issue31235@psf.upfronthosting.co.za>
In-reply-to
Content
Traceback from tracemalloc:

10-STABLE-amd64% ./python -X tracemalloc=10 -m test -v test_logging --fail-env-changed 

(...)

/usr/home/haypo/cpython/Lib/test/support/__init__.py:1515: ResourceWarning: unclosed <socket.socket fd=6, family=AddressFamily.AF_INET, type=536870913, proto=0, laddr=('127.0.0.1', 26785), raddr=('127.0.0.1', 26788)>
  gc.collect()
Object allocated at (most recent call first):
  File "/usr/home/haypo/cpython/Lib/socket.py", lineno 210
    sock = socket(self.family, type, self.proto, fileno=fd)
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 348
    conn, addr = self.socket.accept()
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 492
    pair = self.accept()
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 417
    self.handle_accept()
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 83
    obj.handle_read_event()
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 150
    read(obj)
  File "/usr/home/haypo/cpython/Lib/asyncore.py", lineno 203
    poll_fun(timeout, map)
  File "/usr/home/haypo/cpython/Lib/test/test_logging.py", lineno 782
    asyncore.loop(poll_interval, map=self._map)
  File "/usr/home/haypo/cpython/Lib/threading.py", lineno 865
    self._target(*self._args, **self._kwargs)
  File "/usr/home/haypo/cpython/Lib/threading.py", lineno 917
    self.run()

So it seems like the socket was created in TestSMTPServer.serve_forever() of test_logging, which is used by SMTPHandlerTest.test_basic().
History
Date User Action Args
2017-08-18 22:06:30vstinnersetrecipients: + vstinner
2017-08-18 22:06:30vstinnersetmessageid: <1503093990.84.0.706116318866.issue31235@psf.upfronthosting.co.za>
2017-08-18 22:06:30vstinnerlinkissue31235 messages
2017-08-18 22:06:30vstinnercreate