[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#78526: www.debian.org: Add a WWW frontend to the BTS

Package: www.debian.org
Version: 20001201
Severity: wishlist

(as sent to the debian-www mailing list)

        Even though we currently have 'bug' and 'reportbug' as a way to
easily make users send bugs to the BTS, having dinner with other Debian
developers (or wannabes) in the last Hispalinux Congress in Madrid, Spain,
one of the people present (Jaime Villate) made the following, and
interesting, proposition.

        Users tend to view the use of mail like a personal tool, whileas
they are used to see the web as a way to communicate with other companies
through form submission. Debian does not have a WWW interface to file
should it be made?

        Some might think that if we used cgi posts (or whatever form
available) the BTS would not be able to track the user that sent the BTS
could lead to spam in the BTS, or unavailability to track the problems
further (since developers could not ask for more information)... then
the inspiration: use ACTION=mailto:XXX@bugs.debian.org

        We could program a daemon (or even add this functionality to
submit@bugs) that would receive the information sent by the user in the
following form:
and resend it with the nice:


        That we all love :) and keeping the user's email in the bug. The
would receive (by email) the notification of the opening of the bug and
further changes.

        Since currently many browsers have built in mail capabilities if
properly configured and users use them at the same time, this might not
seem a bad idea. Is it?

        I would love to see discussion on this issue and maybe help with
the implementation (with a little help of Perl :) So, what do other
developers think?

        Best regards


Proof of concept:
        HTML form -> (user sends email) -> automatic gatherer ---------->BTS
        (like deb-test.html)            (parse_email | parse_query )


<FORM ACTION="mailto:jfs-local@dat.etsit.upm.es?subject=bug";>
Package: <INPUT TYPE=text NAME=package SIZE=20><BR>
Version: <INPUT TYPE=text NAME=version SIZE=20><BR>
Priority: <SELECT NAME=priority>
<OPTION VALUE="normal" SELECTED>normal
<OPTION VALUE="wishlist">wishlist
<OPTION VALUE="important">important
<OPTION VALUE="critical">critical
Description: <TEXTAREA COLS=60 ROWS=10 NAME=description>Insert your description here</TEXTAREA><BR>
<INPUT TYPE=submit NAME=send>


# Reads a mail from stdin and calls another script 

$query_started = 0;
while ($line=<STDIN>) {
	if ( $line =~ /^From\s+/ ) {
		parsemail() if $query_started;
		print "Receiving an email\n" if $debug;
		$e_mail = "";
		$query = "";
		$query_started = 0;

	$e_mail=$1 if $line =~ /^From: (.*)$/;
	$query = $query.$line if $query_started;
	$query_started = 1 if $line =~ /^$/;
parsemail() if $query_started;

exit 0;

sub parsemail {
	print "Now will call script with:\n" if $debug;
	print "e-mail: $e_mail\n" if $debug;
	print "query: $query\n" if $debug;
	if ($pid=fork) {
	} else {
		die "cannot fork: $!" unless defined $pid;
		$return=`./parse_query.pl -m $e_mail "$query"`;

	return 0;


# Receive a QUERY_STRING from the command line (as ARGV) and print contents
# can be used with script that reads on stdin mails and calls this one with
# the available options

use Getopt::Std;
use CGI::Request;

# Retrieve options from command line

$e_mail = $opt_m;
$SENDTO = ""; 
# put a valid email here (for example  submit@bugs.debian.org)

# read to environment
# process it
$req= new CGI::Request;
@names = $req->params;
open (MAIL,"| mail $SENDTO") or die ("Could not send mail: $!");
# TODO: send as if sent by the original user
foreach $name (@names) {
	@values = $req->param($name);
	foreach $value (@values) {
		print MAIL "\t$value\n";
close MAIL;
exit 0;

-- System Information
Debian Release: 2.2
Kernel Version: Linux avalon 2.2.14 #3 jue feb 17 11:56:30 CET 2000 i686 unknown

Reply to: