without DEBEMAIL invalid mail address put in changelog
Bug #458768 reported by
Robert Collins
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bzr-builder |
Fix Released
|
High
|
James Westby |
Bug Description
bzr dailydeb ...
< Changed-By: bzr-builder <email address hidden>
---
> Changed-By: Bob The Builder </var/mail/
affects bzr-builder
done
The first line was from 0.1-0ubuntu1, the second from trunk.
-Rob
Related branches
lp:~james-w/bzr-builder/trunk-old
(Merged)
Changed in bzr-builder: | |
status: | Triaged → Fix Committed |
assignee: | nobody → James Westby (james-w) |
Changed in bzr-builder: | |
milestone: | none → 0.3 |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
What's the bug? That /var/mail/ bobthebuilder is used?
Here's the code, which is a translation of what dch does.
Can you confirm that dch does something different in that
environment?
def get_maintainer(): r"^(.*) \s+<(.* )>$")
"""
Create maintainer string using the same algorithm as in dch
"""
env = os.environ
regex = re.compile(
# Split email and name env['DEBEMAIL' ])
env[' DEBFULLNAME' ] = match_obj.group(1)
env[ 'DEBEMAIL' ] = match_obj.group(2)
match_ obj = regex.match( env['EMAIL' ])
env[ 'DEBFULLNAME' ] = match_obj.group(1)
env[' EMAIL'] = match_obj.group(2)
if 'DEBEMAIL' in env:
match_obj = regex.match(
if match_obj:
if not 'DEBFULLNAME' in env:
if 'DEBEMAIL' not in env or 'DEBFULLNAME' not in env:
if 'EMAIL' in env:
if match_obj:
if not 'DEBFULLNAME' in env:
# Get maintainer's name
maintainer = re.sub(r',.*', '', pwd.getpwuid( os.getuid( )).pw_gecos)
maintainer = "bzr-builder"
if 'DEBFULLNAME' in env:
maintainer = env['DEBFULLNAME']
elif 'NAME' in env:
maintainer = env['NAME']
else:
# Use password database if no data in environment variables
try:
except KeyError, AttributeError:
# TBD: Use last changelog entry value
# Get maintainer's mail address exists( '/etc/mailname' ): etc/mailname' )
addr = f.readline( ).strip( )
finally:
f.close( ) os.getuid( )).pw_name
addr = None
addr = "%s@%s" % (user, addr)
if 'DEBEMAIL' in env:
email = env['DEBEMAIL']
elif 'MAIL' in env:
email = env['MAIL']
else:
addr = None
if os.path.
f = open('/
try:
if not addr:
addr = socket.getfqdn()
if addr:
user = pwd.getpwuid(
if not user:
else:
if addr:
email = addr
else:
# TBD: Use last changelog entry value
email = "<email address hidden>"
return (maintainer, email)
I can't really see how you get an email without an "@".
Thanks,
James