After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 458731 - sabayon-apply crashed with TypeError in debug_log_dump_as_list()
sabayon-apply crashed with TypeError in debug_log_dump_as_list()
Status: RESOLVED FIXED
Product: sabayon
Classification: Deprecated
Component: general
2.19.x
Other All
: Normal critical
: ---
Assigned To: Maintainers of sabayon
Maintainers of sabayon
Depends on:
Blocks:
 
 
Reported: 2007-07-20 18:22 UTC by Colin Watson
Modified: 2007-08-14 01:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
set admin log filename earlier; remember to import sabayon.config too (3.30 KB, patch)
2007-07-20 18:24 UTC, Colin Watson
none Details | Review

Description Colin Watson 2007-07-20 18:22:34 UTC
Steps to reproduce:
Run 'sabayon-apply --help', or anything else that raises an exception before managing to set the admin log filename. Likewise for sabayon-session.

Stack trace:
Traceback (most recent call last):
  • File "/usr/sbin/sabayon-apply", line 117 in <module>
    util.get_admin_log_config_filename ())
  • File "/var/lib/python-support/python2.5/sabayon/errors.py", line 104 in errors_exit_with_fatal_exception
    debuglog.debug_log_dump_to_file (log_config_filename, sys.stderr)
  • File "/var/lib/python-support/python2.5/sabayon/debuglog.py", line 352 in debug_log_dump_to_file
    list = debug_log_dump_as_list (config_filename)
  • File "/var/lib/python-support/python2.5/sabayon/debuglog.py", line 335 in debug_log_dump_as_list
    raise TypeError ("config_filename must be a string")
TypeError: config_filename must be a string

Other information:
Comment 1 Colin Watson 2007-07-20 18:22:56 UTC
See also https://bugs.launchpad.net/ubuntu/+source/sabayon/+bug/127103 where this was originally filed.
Comment 2 Colin Watson 2007-07-20 18:24:16 UTC
Created attachment 92061 [details] [review]
set admin log filename earlier; remember to import sabayon.config too
Comment 3 Colin Watson 2007-07-20 18:26:27 UTC
2007-07-20  Colin Watson  <cjwatson@ubuntu.com>

        * admin-tool/sabayon-apply: Import sabayon.config. Set admin log
          filename earlier so that we don't crash trying to handle
          exceptions.

        * admin-tool/sabayon-session: Likewise.
Comment 4 Federico Mena Quintero 2007-08-14 01:03:46 UTC
Thanks for catching this and for the patch!  I took a simpler solution; start the toplevel "try" block right after the call to option_parser.parse_args().  This way the "except" clause won't run if the option parser does a sys.exit() after being passed --help.

2007-08-13  Federico Mena Quintero  <federico@novell.com>

	* configure.ac: Bumped version number to 2.19.2.

	* admin-tool/sabayon-apply: Import our config module.

	* admin-tool/sabayon-session: Likewise.

	* admin-tool/sabayon-apply (main): Start the toplevel "try" block
	right after the call to option_parser.parse_args(); if it exits
	due to being passed --help, we don't want our exception handler to
	be called.  Thanks to Colin Watson <cjwatson@debian.org> for
	catching this.  Fixes http://bugzilla.gnome.org/show_bug.cgi?id=458731

	* admin-tool/sabayon-session (main): Likewise.
	(main): Removed leftover "print" statements for debugging.