IOError with getpass() in django
Hi, I reposted as I noticed, that my inital subject line doesn't really indicate what's the issue. ------------------------------------------------------------------- I wanted to make my very first test with pypy by using django and sqlite3 on a Linux host (Ubuntu 12.04) when running ./manage.py syncdb I'm asked to enter a password and pypy aborts as soon as I press enter.
File "/home/klausf/mypypy/site-packages/django/contrib/auth/management/commands/createsuperuser.py", line 109, in handle password = getpass.getpass() File "/usr/lib/pypy/lib-python/2.7/getpass.py", line 74, in unix_getpass stream.flush() # issue7208 IOError: [Errno 29] Illegal seek: '<fdopen>'
Version info: Python 2.7.2 (1.8+dfsg-2, Feb 19 2012, 19:18:08) [PyPy 1.8.0 with GCC 4.6.2] Django version: 1.3.1 I even found a bug, which seems related ( https://bugs.pypy.org/issue872 ) However I don't understand the impact and what this means exactly. Should I try to install another pypy (and if yes, how can I install it next to an existing one on Ubuntu 12.04)? Thanks in advance for your help.
On Wed, May 30, 2012 at 11:42 PM, Gelonida N <gelonida@gmail.com> wrote:
Hi,
I reposted as I noticed, that my inital subject line doesn't really indicate what's the issue. ------------------------------**------------------------------**-------
I wanted to make my very first test with pypy by using django and sqlite3 on a Linux host (Ubuntu 12.04)
when running ./manage.py syncdb I'm asked to enter a password and pypy aborts as soon as I press enter.
File "/home/klausf/mypypy/site-**packages/django/contrib/auth/**
management/commands/**createsuperuser.py", line 109, in handle password = getpass.getpass() File "/usr/lib/pypy/lib-python/2.7/**getpass.py", line 74, in unix_getpass stream.flush() # issue7208 IOError: [Errno 29] Illegal seek: '<fdopen>'
Version info: Python 2.7.2 (1.8+dfsg-2, Feb 19 2012, 19:18:08) [PyPy 1.8.0 with GCC 4.6.2]
Django version: 1.3.1
I even found a bug, which seems related ( https://bugs.pypy.org/issue872 )
However I don't understand the impact and what this means exactly. Should I try to install another pypy (and if yes, how can I install it next to an existing one on Ubuntu 12.04)?
Thanks in advance for your help.
No, it's a bug and we did not fix it yet. I'll have a look some time today.
On 05/31/2012 09:15 AM, Maciej Fijalkowski wrote:
On Wed, May 30, 2012 at 11:42 PM, Gelonida N <gelonida@gmail.com <mailto:gelonida@gmail.com>> wrote:
I wanted to make my very first test with pypy by using django and sqlite3 on a Linux host (Ubuntu 12.04)
when running ./manage.py syncdb I'm asked to enter a password and pypy aborts as soon as I press enter.
File "/home/gelonida/mypypy/site-__packages/django/contrib/auth/__management/commands/__createsuperuser.py", line 109, in handle password = getpass.getpass() File "/usr/lib/pypy/lib-python/2.7/__getpass.py", line 74, in unix_getpass stream.flush() # issue7208 IOError: [Errno 29] Illegal seek: '<fdopen>'
Version info: Python 2.7.2 (1.8+dfsg-2, Feb 19 2012, 19:18:08) [PyPy 1.8.0 with GCC 4.6.2]
Django version: 1.3.1
I even found a bug, which seems related ( https://bugs.pypy.org/issue872 )
However I don't understand the impact and what this means exactly. Should I try to install another pypy (and if yes, how can I install it next to an existing one on Ubuntu 12.04)?
Thanks in advance for your help.
No, it's a bug and we did not fix it yet. I'll have a look some time today.
Thanks for your answer. Shouldn't this affect all users trying to use Django on a new project? I didn't find any way by means of command line arguments to avoid the call to getpass() How do others work around it? What I did in the end was, that I just called the first "./manage.py syncdb" with ordinary CPython. Subsequent calls won't call getpass() anymore and should thus be fine.
Hi all, I finally fixed the bug, by ignoring flush() entirely in case they don't manage to do lseek(). A bientôt, Armin. On 5/31/12, Gelonida N <gelonida@gmail.com> wrote:
On 05/31/2012 09:15 AM, Maciej Fijalkowski wrote:
On Wed, May 30, 2012 at 11:42 PM, Gelonida N <gelonida@gmail.com <mailto:gelonida@gmail.com>> wrote:
I wanted to make my very first test with pypy by using django and sqlite3 on a Linux host (Ubuntu 12.04)
when running ./manage.py syncdb I'm asked to enter a password and pypy aborts as soon as I press enter.
File
"/home/gelonida/mypypy/site-__packages/django/contrib/auth/__management/commands/__createsuperuser.py", line 109, in handle password = getpass.getpass() File "/usr/lib/pypy/lib-python/2.7/__getpass.py", line 74, in unix_getpass stream.flush() # issue7208 IOError: [Errno 29] Illegal seek: '<fdopen>'
Version info: Python 2.7.2 (1.8+dfsg-2, Feb 19 2012, 19:18:08) [PyPy 1.8.0 with GCC 4.6.2]
Django version: 1.3.1
I even found a bug, which seems related ( https://bugs.pypy.org/issue872 )
However I don't understand the impact and what this means exactly. Should I try to install another pypy (and if yes, how can I install it next to an existing one on Ubuntu 12.04)?
Thanks in advance for your help.
No, it's a bug and we did not fix it yet. I'll have a look some time today.
Thanks for your answer. Shouldn't this affect all users trying to use Django on a new project? I didn't find any way by means of command line arguments to avoid the call to getpass()
How do others work around it?
What I did in the end was, that I just called the first "./manage.py syncdb" with ordinary CPython.
Subsequent calls won't call getpass() anymore and should thus be fine.
_______________________________________________ pypy-dev mailing list pypy-dev@python.org http://mail.python.org/mailman/listinfo/pypy-dev
participants (3)
-
Armin Rigo -
Gelonida N -
Maciej Fijalkowski