Code

Opened 3 years ago

Closed 3 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: master
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)

0001-PyPy-compatibility-in-runserver-s-reload-module.patch (1.3 KB) - added by anonymous 3 years ago.

Download all attachments as: .zip

Change History (4)

comment:1 Changed 3 years ago by anonymous

  • Has patch set
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

comment:2 Changed 3 years ago by Alex

  • Triage Stage changed from Unreviewed to Design decision needed

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.

comment:3 Changed 3 years ago by Alex

  • Resolution set to invalid
  • Status changed from new to 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.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.