This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients brian.curtin, ezio.melotti, georg.brandl, techtonik, terry.reedy
Date 2013-02-25.05:28:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1361770106.01.0.673110893306.issue8936@psf.upfronthosting.co.za>
In-reply-to
Content
The regression issue is red herring. An issue should propose new behavior (based on an understanding of the doc and actual current behavior). Then ask: "Is the proposed behavior better than the current behavior?", and "Is the current behavior a bug?". After reading the doc and the code, I am convinced that current behavior is close to the implied wanted behavior, and that it is not a bug.

The doc says
 webbrowser.open(url, new=0, autoraise=True)
    Display url using the default browser.

What does 'default browswer' mean? Near the top, the doc says "If the environment variable BROWSER exists, it is interpreted to override the platform default list of browsers,". So the 'default browser' is actually the 'default browser list'. What open() does is to try each in turn and stop when one says it succeeded. So the doc should say 'using the first default browser that claims to succeed.'

What does 'default browser list' mean? It depends on the platform *and* the software loaded on the particular machine when webbrowser is first imported in a particular instance of the interpreter. The 'platform' part is in the quote above, the rest is not. I will open a separate doc issue.

On Windows, the list starts with 'default Windows browser', which calls os.startfile(), which, I believe, does call the user default browser. Next is Internet Explorer -- if available at that time on the particular machine! If the user-default browser rejects the url, then IE is tried.

On my win7 machine today, I have Firefox the default and IE available. Firefox rejects 127.0.0.1:8080 with an 'Unable to connect' error box. IE 'accepts' it in the sense that it displays an information starting 'The webpage cannot be displayed'. For 'invalid.xxx', IE displays the page for a German domain registrar. I strongly suspect that the change Anatoly saw was a difference in IE, out of Python's control.

Georg, if you think I got it wrong, please correct.
History
Date User Action Args
2013-02-25 05:28:26terry.reedysetrecipients: + terry.reedy, georg.brandl, techtonik, ezio.melotti, brian.curtin
2013-02-25 05:28:26terry.reedysetmessageid: <1361770106.01.0.673110893306.issue8936@psf.upfronthosting.co.za>
2013-02-25 05:28:25terry.reedylinkissue8936 messages
2013-02-25 05:28:25terry.reedycreate