Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deleting Request data does not update Content-length header. #61687

Closed
dwoz mannequin opened this issue Mar 19, 2013 · 4 comments
Closed

Deleting Request data does not update Content-length header. #61687

dwoz mannequin opened this issue Mar 19, 2013 · 4 comments
Labels
stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error

Comments

@dwoz
Copy link
Mannequin

dwoz mannequin commented Mar 19, 2013

BPO 17485
Nosy @orsenthil, @bitdancer
Files
  • patch.diff: Patch to resolve and test this issue
  • 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 = None
    closed_at = <Date 2013-03-20.04:17:49.603>
    created_at = <Date 2013-03-19.20:25:50.901>
    labels = ['type-bug', 'library']
    title = 'Deleting Request data does not update Content-length header.'
    updated_at = <Date 2014-03-10.22:11:19.380>
    user = 'https://bugs.python.org/dwoz'

    bugs.python.org fields:

    activity = <Date 2014-03-10.22:11:19.380>
    actor = 'python-dev'
    assignee = 'none'
    closed = True
    closed_date = <Date 2013-03-20.04:17:49.603>
    closer = 'r.david.murray'
    components = ['Library (Lib)']
    creation = <Date 2013-03-19.20:25:50.901>
    creator = 'dwoz'
    dependencies = []
    files = ['29485']
    hgrepos = []
    issue_num = 17485
    keywords = ['patch']
    message_count = 4.0
    messages = ['184668', '184731', '184734', '213094']
    nosy_count = 4.0
    nosy_names = ['orsenthil', 'r.david.murray', 'python-dev', 'dwoz']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue17485'
    versions = ['Python 3.4']

    @dwoz
    Copy link
    Mannequin Author

    dwoz mannequin commented Mar 19, 2013

    The patch to fix issue http://bugs.python.org/issue16464 neglects the deleter method of the Request.data property. This allows Request._data to get updated without removing the Content-length header.

    @dwoz dwoz mannequin added the stdlib Python modules in the Lib dir label Mar 19, 2013
    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Mar 20, 2013

    New changeset b1579eb4e1bc by R David Murray in branch 'default':
    bpo-17485: Delete the Content-Length header if the data attribute is deleted.
    http://hg.python.org/cpython/rev/b1579eb4e1bc

    @bitdancer
    Copy link
    Member

    Thanks, Daniel. I moved the test so that it would be run even if the network resource is not enabled.

    @bitdancer bitdancer added the type-bug An unexpected behavior, bug, or error label Mar 20, 2013
    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Mar 10, 2014

    New changeset e6d862886e5c by R David Murray in branch 'default':
    whatsnew: urllib Request objects are now reusable.
    http://hg.python.org/cpython/rev/e6d862886e5c

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant