[Django] #24878: response.content TypeError: Type str doesn't support the buffer API

12 views
Skip to first unread message

Django

unread,
May 29, 2015, 6:40:41 PM5/29/15
to django-...@googlegroups.com
#24878: response.content TypeError: Type str doesn't support the buffer API
---------------------------------+--------------------
Reporter: LegoStormtroopr | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.8
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
---------------------------------+--------------------
Every test in my tests suite for {{{ some_string in response.context}}
fails with the same exception "TypeError: Type str doesn't support the
buffer API".

Fails for both Django 1.7 and Django 1.8

Example code:

{{{
response = self.client.get(self.wg1.get_absolute_url())
self.assertFalse("archive_modal" in response.content)
}}}


Corresponding traceback:

{{{
======================================================================
ERROR: test_manager_can_archive
(aristotle_mdr.tests.test_workgroups.WorkgroupMemberTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/aristotle-mdr/aristotle-metadata-
registry/aristotle_mdr/tests/test_workgroups.py", line 192, in
test_manager_can_archive
self.assertFalse("archive_modal" in response.content)
TypeError: Type str doesn't support the buffer API
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/24878>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
May 29, 2015, 9:26:45 PM5/29/15
to django-...@googlegroups.com
#24878: response.content TypeError: Type str doesn't support the buffer API
---------------------------------+--------------------------------------
Reporter: LegoStormtroopr | Owner: nobody
Type: Uncategorized | Status: closed
Component: Uncategorized | Version: 1.8
Severity: Normal | Resolution: invalid
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
---------------------------------+--------------------------------------
Changes (by timgraham):

* status: new => closed
* needs_better_patch: => 0
* resolution: => invalid
* needs_tests: => 0
* needs_docs: => 0


Comment:

Please see TicketClosingReasons/UseSupportChannels

--
Ticket URL: <https://code.djangoproject.com/ticket/24878#comment:1>

Reply all
Reply to author
Forward
0 new messages