comparison setup.py @ 18866:930d54b1fd29 stable

setup.py: properly discard trust warning. This modification was missing from the fa91ddfc3f36 changeset.
author Isaac Jurado <diptongo@gmail.com>
date Tue, 02 Apr 2013 16:03:10 +0200
parents d420ac09f866
children 02ee846b246a
comparison
equal deleted inserted replaced
18857:801d3db0473c 18866:930d54b1fd29
146 # another user (as in "sudo python setup.py install") we will get 146 # another user (as in "sudo python setup.py install") we will get
147 # trust warnings since the .hg/hgrc file is untrusted. That is 147 # trust warnings since the .hg/hgrc file is untrusted. That is
148 # fine, we don't want to load it anyway. Python may warn about 148 # fine, we don't want to load it anyway. Python may warn about
149 # a missing __init__.py in mercurial/locale, we also ignore that. 149 # a missing __init__.py in mercurial/locale, we also ignore that.
150 err = [e for e in err.splitlines() 150 err = [e for e in err.splitlines()
151 if not e.startswith(b('Not trusting file')) \ 151 if not e.startswith(b('not trusting file')) \
152 and not e.startswith(b('warning: Not importing')) \ 152 and not e.startswith(b('warning: Not importing')) \
153 and not e.startswith(b('obsolete feature not enabled'))] 153 and not e.startswith(b('obsolete feature not enabled'))]
154 if err: 154 if err:
155 print >> sys.stderr, "stderr from '%s':" % (' '.join(cmd)) 155 print >> sys.stderr, "stderr from '%s':" % (' '.join(cmd))
156 print >> sys.stderr, '\n'.join([' ' + e for e in err]) 156 print >> sys.stderr, '\n'.join([' ' + e for e in err])