Bug 172192 - Option --connect is required
Summary: Option --connect is required
Alias: None
Product: Fedora
Classification: Fedora
Component: pykickstart   
(Show other bugs)
Version: rawhide
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Chris Lumens
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2005-11-01 14:03 UTC by James Laska
Modified: 2013-09-02 06:07 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-11-01 15:43:50 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description James Laska 2005-11-01 14:03:02 UTC
# TREE rawhide-20051101
# ARCH x86_64

File "/usr/lib/python2.4/site-packages/pykickstart/parser.py", line 905, in
   self.handleCommand(lineno, args)
File "/usr/lib/python2.4/site-packages/pykickstart/parser.py", line 803, in
File "/usr/lib/python2.4/site-packages/pykickstart/parser.py", line 676, in doVnc
   (opts, extra) = op.parse_args(args=args)
File "/usr/lib64/python2.4/optparse.py", line 1280, in parse_args
   return self.check_values(values, args)
File "/usr/lib/python2.4/site-packages/pykickstart/parser.py", line 97, in
  raise KickstartValueError, formatErrorMsg(self.lineno, "Option %s is required"
% option)
pykickstart.parser.KickstartValueError: The following problem occured in line 19
of the kickstart file:

Option --connect is required

install exited abnormally
sending termination signals...done

Should the --connect option be added as required?  

--- pykickstart/parser.py       2005-11-01 08:55:22.000000000 -0500
+++ /tmp/parser.py      2005-11-01 08:55:20.000000000 -0500
@@ -670,7 +670,7 @@

         op = KSOptionParser(lineno=self.lineno)
         op.add_option("--connect", action="callback", callback=connect_cb,
-                      nargs=1, type="string", required=1)
+                      nargs=1, type="string", required=0)
         op.add_option("--password", dest="password")

         (opts, extra) = op.parse_args(args=args)

Additionally, it seems like the installation should present a traceback dialog
instead of rebooting the system.  The traceback dialog would allow the user to
store the traceback on another system for further perusal.  The error message
could be massaged a bit for readability:

While processing your kickstart file, and error was encountered on line 19: 

     17 network --device eth0 --bootproto dhcp
     18 reboot
     19 vnc
     20 skipx
     21 nfs --server curly.devel.redhat.com --dir

Option --connect is required by the vnc keyword.


Comment 1 Chris Lumens 2005-11-01 15:43:50 UTC
Fixed.  This was because of me not seeing that you can specify these parameters
on the boot command line as well.  Keep trying out kickstart - there are bound
to be more small bugs like this in there.

Regarding popping up an execption dialog - because of how anaconda is set up, we
have a special kickstart parser that looks for VNC parameters extremely early
on.  We don't even know what sort of interface will be used at this point, so
any kickstart errors when looking for VNC parameters will cause this sort of
traceback.  Not really much we can do about it.

I would like to make more useful kickstart errors.  Putting the line number on
was a pretty good step forward, I think.  I don't currently have the sort of
context available to do what you'd like, but I'll put it on my list.

Note You need to log in before you can comment on or make changes to this bug.