Opened 13 years ago
Closed 13 years ago
#16657 closed Bug (invalid)
PyPy compat: call termios functions on file descriptors, not file objects
Reported by: | anonymous | Owned by: | nobody |
---|---|---|---|
Component: | Core (Management commands) | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Design decision needed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description
This patch fixes an incompatibility between Django dev and pypy 1.6. The functions from termios are documented to use file descriptors, although CPython accepts both file descriptors and file objects. Django's file object is confusingly named fd.
Attachments (1)
Change History (4)
by , 13 years ago
Attachment: | 0001-PyPy-compatibility-in-runserver-s-reload-module.patch added |
---|
comment:1 by , 13 years ago
Has patch: | set |
---|
comment:2 by , 13 years ago
Triage Stage: | Unreviewed → Design decision needed |
---|
comment:3 by , 13 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Just found in the CPython docs, right at the top "All functions in this module take a file descriptor fd as their first argument. This can be an integer file descriptor, such as returned by sys.stdin.fileno(), or a file object, such as sys.stdin itself." Going to close this and fix in PyPy itself.
Is there a compelling reason not to consider this a bug in PyPy (despite the documentation flail upstream)? I suspect it's as simple of a change there as it is for us.