Control: tags -1 debian-bug.el: reportbug fails without a valid email address 
in environmental variables DEBEMAIL, REPORTBUGEMAIL, or EMAIL

Hi Łukasz,

Łukasz Stelmach <[email protected]> writes:

> Package: elpa-debian-el
> Version: 37.19.1
> Severity: important
>
> Dear Maintainer,
>  
> I was trying to report a bug in the inkscape package via emacs' debian-bug
> command. But the report wasn't properly prefilled as it used to be.
>  
> I debugged debian-bug.el and found out that reportbug called on line
> 766[1] returns "1" and fails to return any output. I called the very
> same command from a shell and it succeded (there was some reasonable
> output). However when I set the HOME environment variable to an empty
> string "", reportbug printed the following error message:
>  
>     Unable to identify a valid from address, please run 'reportbug 
> --configure'
>  
> The lisp code didn't handle this situation properly and didn't show any
> error message.
>  
> To work around this problem, I set EMAIL environment to my e-mail addres
>  
>     (setenv "EMAIL" "[email protected]")
>  
> before running debian-bug.
>
> [1] 
> https://salsa.debian.org/emacsen-team/debian-el/-/blob/master/debian-bug.el?ref_type=heads#L766
>

Thanks for your report! As you have identified, the actual cause is that
without a valid email address in environmental variable DEBEMAIL,
REPORTBUGEMAIL, or EMAIL, reportbug will fail to run. So HOME is not the
real cause here. I have adjusted the bug title accordingly.

I prepared a fix to check for a valid email in those envvars and fail
early if cannot find one. It should appear in experimental soon. Please
help test.

(We can also invoke reportbug with "--email", but I think this may
invite people to set email in too many different places, where some only
work for debian-bug and some only for reportbug, which will make
debugging even harder. envvars are simple and work for both. Suggestions
welcome.)

> -- System Information:
> Debian Release: 13.3
>   APT prefers stable-updates
>   APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 
> 'stable')
> Architecture: amd64 (x86_64)
> Foreign Architectures: i386
>
> Kernel: Linux 6.12.69+deb13-amd64 (SMP w/4 CPU threads; PREEMPT)
> Locale: LANG=pl_PL.UTF-8, LC_CTYPE=pl_PL.UTF-8 (charmap=UTF-8), LANGUAGE not 
> set
> Shell: /bin/sh linked to /usr/bin/dash
> Init: systemd (via /run/systemd/system)
> LSM: AppArmor: enabled
>
> Versions of packages elpa-debian-el depends on:
> ii  bzip2           1.0.8-6
> ii  dh-elpa-helper  2.1.9
> ii  emacsen-common  3.0.8
> ii  reportbug       13.2.0
> ii  xz-utils        5.8.1-1
> ii  zstd            1.5.7+dfsg-1
>
> Versions of packages elpa-debian-el recommends:
> ii  emacs              1:30.1+1-6
> ii  emacs-gtk [emacs]  1:30.1+1-6
> ii  wget               1.25.0-2
>
> elpa-debian-el suggests no packages.
>
> -- no debconf information
>

-- 
Regards,
Xiyue Deng

Attachment: signature.asc
Description: PGP signature

Reply via email to