Opened 3 years ago

Closed 12 months ago

#9091 defect closed fixed (fixed)

iweb.IRequest.{method,uri} documented as str, but are bytes

Reported by: Tom Most Owned by: Wim Lewis <wiml@…>
Priority: normal Milestone:
Component: web Keywords:
Cc: Branch:
Author:

Description

IRequest.method and IRequest.uri are documented as having type `str`:

Attribute method A str giving the HTTP method that was used.
Attribute uri A str giving the full encoded URI which was requested (including query arguments).

However, in Python 3, they are bytes. I have not verified, but the same likely applies to path. The file-like object content should probably also be documented as binary mode.

Change History (1)

comment:1 Changed 12 months ago by Wim Lewis <wiml@…>

Owner: set to Wim Lewis <wiml@…>
Resolution: fixed
Status: newclosed

In fb05f93f:

Merge pull request #1113 from twisted/5533-irequest-postpath-attribute

Author: wiml
Reviewer: glyph
Fixes: ticket:5533 ticket:9091 ticket:9458

Add the prepath and postpath attributes to IRequest; fix other docstrings.

Note: See TracTickets for help on using tickets.