#14501 closed (worksforme)
Django runserver + Chrome/Safari + AJAX POST quirk
Reported by: | davemckenna01 | Owned by: | nobody |
---|---|---|---|
Component: | Uncategorized | Version: | 1.1 |
Severity: | Keywords: | runserver post view ajax chrome safari | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
Only with Safari and Chrome on Windows on my local machine using the django runserver, some views were randomly not returning a response to ajax POST requests. Sometimes they would, sometimes they would not.
The solution was this:
The data I was passing in to the view via POST was just one key/val pair: "action=remove". Now, I wasn't actually using this data in my view. Once I assigned the data to a var in my view, (i.e. foo = request.POSTaction), the view would return a response to ajax requests every time.
Am I missing something - or does that seem like a crazy weird bug?
Change History (3)
comment:1 by , 14 years ago
comment:2 by , 14 years ago
Resolution: | → worksforme |
---|---|
Status: | new → closed |
I cannot reproduce this bug. I'm using Chrome on Windows XP with Django trunk and Python 2.6.5, sending an AJAX request using
jQuery
'sjQuery.post
method, not doing anything with the data in my view, and I'm getting a response every time.Off the top of my head possible causes for such an elusive bug might include an issue in your Python version (Python swallowing exceptions has been known to happen), or a race condition somewhere.
If you can isolate the problem any further or provide a concretely reproducible test case, feel free to re-open.