2005-08-21 21:00:01

by Edd Dumbill

[permalink] [raw]
Subject: [Bluez-users] [Fwd: Bug#322732: bluez-utils: rfcomm bind fails with obscure error message]

A suggestion from a Debian user.

-------- Forwarded Message --------
> From: Peter Hicks <[email protected]>
> Reply-To: Peter Hicks <[email protected]>,
> [email protected]
> To: Debian Bug Tracking System <[email protected]>
> Subject: Bug#322732: bluez-utils: rfcomm bind fails with obscure error
> message
> Date: Fri, 12 Aug 2005 15:16:03 +0100
>
> Package: bluez-utils
> Version: 2.18-1
> Severity: wishlist
>
> Hello
>
> When the 'rfcomm' kernel module isn't compiled with CONFIG_BT_RFCOMM_TTY
> enabled, 'rfcomm bind' will fail with an obscure error message, "Can't
> create device: Operation not supported". It does this when it's trying to
> bind to a device in /dev.
>
> Could this be changed to report something more useful, such as "Check
> rfcomm.ko is compiled with TTY support"?
>
>
> Peter.



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users


2005-08-22 14:20:19

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] [Fwd: Bug#322732: bluez-utils: rfcomm bind fails with obscure error message]

Hi Fred,

> > > > When the 'rfcomm' kernel module isn't compiled with
> > > > CONFIG_BT_RFCOMM_TTY enabled, 'rfcomm bind' will fail with an obscure
> > > > error message, "Can't create device: Operation not supported". It does
> > > > this when it's trying to bind to a device in /dev.
> >
> > this error message is correct. It follows the errno error code that
> > comes back from the kernel.
>
> There is a difference between "correct" and "helpful" ;)
> You might at least consider pointing users to the manpage along with the
> generic error message for diagnosis of the error, because not too many will
> actually try the manpage.
> Error codes are for scripts, error messages are for people. If you need the
> manpage to figure out what's wrong, then you could just as well print the
> error code only. Listing the error codes in the manpage should be only
> necessary to list all *possible* errors, so that scripts can handle all of
> them for instance.

the command line tools are still the Unix world and an error which is
called "Operation not supported" is from my perspective a clear error
that the tool in use or the kernel lacks support for something. And in
this specific case he compiled the kernel by itself and not included
support for RFCOMM TTY in the rfcomm.ko module.

Said this, I don't like additional switch or if statements to add a lot
of user friendly error messages to make the users feel better. For
command line tools it is fine to expect people to open a manual page to
investigate further. For graphical tools this is different, but the last
time I checked rfcomm is still command line only ;)

Regards

Marcel




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-08-22 12:48:10

by Fred Schaettgen

[permalink] [raw]
Subject: Re: [Bluez-users] [Fwd: Bug#322732: bluez-utils: rfcomm bind fails with obscure error message]

On Monday, 22. August 2005 13:12, Marcel Holtmann wrote:
> Hi Edd,
>
> > > When the 'rfcomm' kernel module isn't compiled with
> > > CONFIG_BT_RFCOMM_TTY enabled, 'rfcomm bind' will fail with an obscure
> > > error message, "Can't create device: Operation not supported". It does
> > > this when it's trying to bind to a device in /dev.
>
> this error message is correct. It follows the errno error code that
> comes back from the kernel.

There is a difference between "correct" and "helpful" ;)
You might at least consider pointing users to the manpage along with the
generic error message for diagnosis of the error, because not too many will
actually try the manpage.
Error codes are for scripts, error messages are for people. If you need the
manpage to figure out what's wrong, then you could just as well print the
error code only. Listing the error codes in the manpage should be only
necessary to list all *possible* errors, so that scripts can handle all of
them for instance.

regards
Fred

--
Fred Schaettgen
[email protected]


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-08-22 11:12:29

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] [Fwd: Bug#322732: bluez-utils: rfcomm bind fails with obscure error message]

Hi Edd,

> > When the 'rfcomm' kernel module isn't compiled with CONFIG_BT_RFCOMM_TTY
> > enabled, 'rfcomm bind' will fail with an obscure error message, "Can't
> > create device: Operation not supported". It does this when it's trying to
> > bind to a device in /dev.

this error message is correct. It follows the errno error code that
comes back from the kernel.

> > Could this be changed to report something more useful, such as "Check
> > rfcomm.ko is compiled with TTY support"?

What about a patch for the RFCOMM manual page that explains this
problem?

Regards

Marcel




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users