Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #63715

Bug#925943: nfs-common: nfsiostat crashes due to using reserved word 'list' as variable name

From Matthew Ruffell <matthew.ruffell@canonical.com>
Newsgroups linux.debian.bugs.dist, linux.debian.kernel
Subject Bug#925943: nfs-common: nfsiostat crashes due to using reserved word 'list' as variable name
Date 2019-03-29 00:00 +0100
Message-ID <xGMa5-340-1@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Cross-posted to 2 groups.

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Package: nfs-utils
Version: 1:1.3.4-2.3
Severity: normal
Tags: patch
User: ubuntu-devel@lists.ubuntu.com
Usertags: origin-ubuntu disco ubuntu-patch

Dear Maintainer,

nfsiostat, in nfs-common-1.3.4-2, is broken in bionic, cosmic and disco.

When you run the command nfsiostat, either as root or a regular user, the following traceback is printed:

$ nfsiostat
Traceback (most recent call last):
  File "/usr/sbin/nfsiostat", line 640, in <module>
    iostat_command(prog)
  File "/usr/sbin/nfsiostat", line 593, in iostat_command
    devices = list_nfs_mounts(origdevices, mountstats)
  File "/usr/sbin/nfsiostat", line 495, in list_nfs_mounts
    for device, descr in list(mountstats.items()):
TypeError: 'list' object is not callable

This is caused by the 'list' reserved word being used as a variable name in list_nfs_mounts(), 
and is explained here: https://askubuntu.com/questions/1123319/nfsiostat-failing-on-18-04/1123336#1123336?s=a1e9150fbf284e849efe6fe084e7c7b8

I have sent a patch upstream to fix this, and it was commited in:
http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=commitdiff;h=c4c14011b70375050d7bba7c57e2eaf4c715dc7c

In Ubuntu, the attached patch was applied to achieve the following:

  * nfsiostat-replace-list-reserved-word.patch: fix nfsiostat crash due to
    using 'list' as a variable name. (LP: #1821261)

Please land this patch in debian to aid with the SRU process.

Thanks for considering the patch.

-- System Information:
Debian Release: buster/sid
  APT prefers cosmic-updates
  APT policy: (500, 'cosmic-updates'), (500, 'cosmic-security'), (500, 'cosmic'), (100, 'cosmic-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.18.0-16-generic (SMP w/4 CPU cores)
Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8), LANGUAGE=en_NZ:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Back to linux.debian.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Bug#925943: nfs-common: nfsiostat crashes due to using reserved word 'list' as variable name Matthew Ruffell <matthew.ruffell@canonical.com> - 2019-03-29 00:00 +0100
  Bug#925943: marked as done (nfs-common: nfsiostat crashes due to  using reserved word 'list' as variable name) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2020-03-13 15:00 +0100

csiph-web