Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 80932 - Curses interface of bittorrent doesn't work
Summary: Curses interface of bittorrent doesn't work
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Gentoo net-p2p team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-02-05 17:47 UTC by David Held
Modified: 2005-09-10 09:34 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to 3.4.2-r2 to add ncurses support. (bittorrent-3.4.2-r2.ncurses.patch,511 bytes, patch)
2005-02-05 18:27 UTC, David Tomaschik
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Held 2005-02-05 17:47:19 UTC
I've tried bittorrent-3.4.2, bittorrent-3.4.2-r1, bittorrent-3.4.2-r2 and they all show the same same results. When I try to use btdownloadcurses.py I see the following:

Textmode GUI initialization failed, cannot proceed.

This download interface requires the standard Python module "curses", which is unfortunately not available for the native Windows port of Python. It is however available for the Cygwin port of Python, running on all Win32 systems (www.cygwin.com).

You may still use "btdownloadheadless.py" to download.
Traceback (most recent call last):
  File "/usr/bin/btdownloadcurses.py", line 228, in ?
    scrh, scrw = scrwin.getmaxyx()
NameError: global name 'scrwin' is not defined

Using btdownloadheadless.py works.

Reproducible: Always
Steps to Reproduce:




Portage 2.0.51-r15 (default-linux/x86/2004.3, gcc-3.3.5,
glibc-2.3.4.20040808-r1, 2.6.10 i686)
=================================================================
System uname: 2.6.10 i686 Intel(R) Pentium(R) M processor 1.70GHz
Gentoo Base System version 1.6.9
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Jan 21 2005, 20:17:38)]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r1
sys-devel/libtool:   1.5.10-r4
virtual/os-headers:  2.4.22
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=pentium3 -O3 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=pentium3 -O3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache digest distlocks sandbox sfperms userpriv"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X acpi alsa avi berkdb bindist bitmap-fonts cdr crypt cups dvd encode
esd f77 fam font-server foomaticdb fortran gdbm gif gnome gpm gtk gtk2 gtkhtml
icq imap imlib jpeg libg++ libwww maildir mikmod mmx motif mozilla moznocompose
moznoirc moznomail mpeg msn ncurses nls oggvorbis opengl oscar oss pam pcmcia
pda pdflib perl png python qt quicktime readline rtc samba sdl spell sqlite sse
ssl svga tcpd tiff truetype truetype-fonts trusted type1-fonts usb videos
vim-with-x wifi xml2 xmms xosd xv xvid zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
Comment 1 David Tomaschik 2005-02-05 18:13:27 UTC
Python and bittorrent have no dependency on curses.  The bittorrent ebuild should either be configured to depend on curses, or depend on the curses use flag to install (or not) the btdownloadcurses.py script.  Patch forthcoming.
Comment 2 David Tomaschik 2005-02-05 18:27:17 UTC
Created attachment 50503 [details, diff]
Patch to 3.4.2-r2 to add ncurses support.

This patch should provide for optional ncurses support in bittorrent based on
the status of the user's ncurses USE variable.
Comment 3 David Held 2005-02-05 20:50:00 UTC
This patch makes sense and it should have the ncurses dependency, however, this is not sufficient.

20:49 drheld@bork:~ $ emerge -pv ncurses

These are the packages that I would merge, in order:

Calculating dependencies ...done!
[ebuild   R   ] sys-libs/ncurses-5.4-r5  -bootstrap -build -debug -doc +gpm -nocxx (-uclibc) -unicode 0 kB 

I've had ncurses installed all along but it still doesn't work.
Comment 4 David Tomaschik 2005-02-06 06:43:50 UTC
Can you give me an ls of the /usr/lib/python*/curses/ directory?  (or inform that it does not exist).  These are the python modules that should be responsible for curses, it would be good to know if they exist on your system.
Comment 5 David Held 2005-02-06 11:25:26 UTC
11:24 drheld@bork:~ $ ls /usr/lib/python2.3/curses/
__init__.py   __init__.pyo  ascii.pyc  has_key.py   has_key.pyo  panel.pyc  textpad.py   textpad.pyo  wrapper.pyc
__init__.pyc  ascii.py      ascii.pyo  has_key.pyc  panel.py     panel.pyo  textpad.pyc  wrapper.py   wrapper.pyo
Comment 6 David Held 2005-02-06 12:00:28 UTC
I managed to figure out where this problem was coming from. The file 
/usr/lib/python2.3/lib-dynload/_curses_panel.so was missing. In the same directory, however, the _curses.so was present.

Checking my python install, I confirmed that the ncurses use flag had been present when python was emerged.

11:56 bork /var/db/pkg/dev-lang/python-2.3.4 # cat USE |grep -c ncurses
1

Re-emerging python, however, solved the problem.
Comment 7 Alan 2005-04-23 08:10:45 UTC
I'm missing _curses_panel.so, too. But in my case, re-emerging python (with +ncurses) did NOT install it.
Comment 8 Marcin Kryczek (RETIRED) gentoo-dev 2005-08-10 16:13:16 UTC
(In reply to comment #7)

Alan: have you managed to get this file? if not - which version of python are 
you currently using?


Comment 9 Karol Wojtaszek (RETIRED) gentoo-dev 2005-09-10 09:34:22 UTC
Please, reopen if problem still occur.