Skip to content

redfish-sel: UnboundLocalError: local variable 'sel_path' referenced before assignment #779

@mburgholte

Description

@mburgholte

This issue respects the following points:

Which variant of the Monitoring Plugins do you use?

  • .rpm/.deb package from repo.linuxfabrik.ch
  • Compiled for Linux (.tar/.zip from download.linuxfabrik.ch)
  • Compiled for Windows (from download.linuxfabrik.ch)
  • Source Code from GitHub

Bug description

I use the plugin on several machines. The following error only appears on one of them.

Traceback (most recent call last):
File "redfish-sel.py", line 206, in 'module'
File "redfish-sel.py", line 180, in main
UnboundLocalError: local variable 'sel_path' referenced before assignment

Steps to reproduce - Plugin call

/usr/lib64/nagios/plugins/redfish-sel --url https://10.123.45.138:443 --username XXXX --password XXXX

Steps to reproduce - Data

No response

Environment

5.4.0-156-generic #173-Ubuntu SMP Tue Jul 11 07:25:22 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

Plugin Version

redfish-sel: v2024031401 by Linuxfabrik GmbH, Zurich/Switzerland

Python version

Python 2.7.18

List of Python modules

BaseHTTPServer abc httplib sgmllib
Bastion aifc ihooks sha
CDROM antigravity imaplib shelve
CGIHTTPServer anydbm imghdr shlex
Canvas argparse imp shutil
ConfigParser array importlib signal
Cookie ast imputil site
Crypto asynchat inspect sitecustomize
DLFCN asyncore io smtpd
Dialog atexit itertools smtplib
DocXMLRPCServer audiodev json sndhdr
FileDialog audioop keyword socket
FixTk base64 lib2to3 spwd
HTMLParser bdb linecache sqlite3
IN binascii linuxaudiodev sre
MimeWriter binhex locale sre_compile
Queue bisect logging sre_constants
ScrolledText bsddb lsb_release sre_parse
SimpleDialog bz2 macpath ssl
SimpleHTTPServer cPickle macurl2path stat
SimpleXMLRPCServer cProfile mailbox statvfs
SocketServer cStringIO mailcap string
StringIO calendar markupbase stringold
TYPES cgi marshal stringprep
Tix cgitb math strop
Tkconstants chunk md5 struct
Tkdnd cmath mhlib subprocess
Tkinter cmd mimetools sunau
UserDict code mimetypes sunaudio
UserList codecs mimify symbol
UserString codeop mmap symtable
_LWPCookieJar collections modulefinder sys
_MozillaCookieJar colorsys multifile sysconfig
builtin commands multiprocessing syslog
future compileall mutex tabnanny
_abcoll compiler netrc tarfile
_ast contextlib new telnetlib
_bisect cookielib nis tempfile
_bsddb copy nntplib termios
_codecs copy_reg ntpath test
_codecs_cn crypt nturl2path textwrap
_codecs_hk csv numbers this
_codecs_iso2022 ctypes opcode thread
_codecs_jp curses operator threading
_codecs_kr datetime optparse time
_codecs_tw dbhash os timeit
_collections dbm os2emxpath tkColorChooser
_csv decimal ossaudiodev tkCommonDialog
_ctypes difflib parser tkFileDialog
_ctypes_test dircache pdb tkFont
_curses dis pickle tkMessageBox
_curses_panel distutils pickletools tkSimpleDialog
_elementtree doctest pipes toaiff
_functools dumbdbm pkgutil token
_hashlib dummy_thread platform tokenize
_heapq dummy_threading plistlib trace
_hotshot email popen2 traceback
_io encodings poplib ttk
_json ensurepip posix tty
_locale errno posixfile turtle
_lsprof exceptions posixpath types
_md5 fcntl pprint unicodedata
_multibytecodec filecmp profile unittest
_multiprocessing fileinput pstats urllib
_osx_support fnmatch pty urllib2
_pyio formatter pwd urlparse
_random fpformat py_compile user
_sha fractions pyclbr uu
_sha256 ftplib pydoc uuid
_sha512 functools pydoc_data warnings
_socket future_builtins pyexpat wave
_sqlite3 gc quopri weakref
_sre genericpath random webbrowser
_ssl getopt re whichdb
_strptime getpass readline wsgiref
_struct gettext repr xdrlib
_symtable glob resource xml
_sysconfigdata grp rexec xmllib
_sysconfigdata_nd gzip rfc822 xmlrpclib
_testcapi hashlib rlcompleter xxsubtype
_threading_local heapq robotparser zipfile
_tkinter hmac runpy zipimport
_warnings hotshot sched zlib
_weakref htmlentitydefs select
_weakrefset htmllib sets

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions