Skip to content

ResourceWarning when urlopen() forgets the HTTPConnection object #63723

@vadmium

Description

@vadmium
BPO 19524
Nosy @warsaw, @orsenthil, @pitrou, @vadmium, @serhiy-storchaka
Files
  • urllib-close-test.diff
  • urlopen-sock-close.diff
  • issue19524.diff
  • test+except-close.patch: Tests + close if exception, on top of existing fix test_urllib2net is triggering a ResourceWarning #56901
  • test2.patch: Test for close after valid & invalid responses
  • close3.4.patch: Close if exception, for 3.4
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/serhiy-storchaka'
    closed_at = <Date 2014-09-06.18:57:39.795>
    created_at = <Date 2013-11-08.03:45:17.035>
    labels = ['type-bug', 'library']
    title = 'ResourceWarning when urlopen() forgets the HTTPConnection object'
    updated_at = <Date 2016-05-16.18:26:27.710>
    user = 'https://github.com/vadmium'

    bugs.python.org fields:

    activity = <Date 2016-05-16.18:26:27.710>
    actor = 'serhiy.storchaka'
    assignee = 'serhiy.storchaka'
    closed = True
    closed_date = <Date 2014-09-06.18:57:39.795>
    closer = 'serhiy.storchaka'
    components = ['Library (Lib)']
    creation = <Date 2013-11-08.03:45:17.035>
    creator = 'martin.panter'
    dependencies = []
    files = ['33004', '33005', '33187', '33319', '35980', '35981']
    hgrepos = []
    issue_num = 19524
    keywords = ['patch']
    message_count = 16.0
    messages = ['202404', '205366', '206481', '206491', '206508', '206662', '207056', '207373', '223257', '223316', '226502', '226503', '265681', '265687', '265689', '265715']
    nosy_count = 6.0
    nosy_names = ['barry', 'orsenthil', 'pitrou', 'python-dev', 'martin.panter', 'serhiy.storchaka']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue19524'
    versions = ['Python 3.4', 'Python 3.5']

    Metadata

    Metadata

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions